Re: [PATCH v2 0/3] tools/accounting: refactor delay fields and share format_timespec()
From: Andrew Morton
Date: Wed Jul 15 2026 - 15:59:35 EST
On Wed, 15 Jul 2026 12:47:40 +0800 (CST) <wang.yaxin@xxxxxxxxxx> wrote:
> From: Wang Yaxin <wang.yaxin@xxxxxxxxxx>
>
> - Convert per-field delay members in struct task_info to an array indexed
> by enum delay_type, eliminating offsetof() pointer arithmetic.
>
> - Factor out a common format_timespec() implementation shared by getdelays
> and delaytop, using strftime for cleaner timestamp formatting.
>
> - Replace the complex sizeof/ULL/shift Y2038 guard with a direct narrowing
> truncation check ((long long)time_sec != ts->tv_sec).
>
> Change Log
> ==========
> v1->v2:
> Only update patch 2/3 according to the suggestion:
> https://sashiko.dev/#/patchset/20260711173112482SCQEM08VED2PT1pxUYOXk@xxxxxxxxxx
Thanks. Sashiko asked a new question:
https://sashiko.dev/#/patchset/20260715124740929HC7tDDb2SK3kRxbuPruHd@xxxxxxxxxx