Re: [PATCH] ufs: core: ufshcd: use CLOCK_BOOTTIME for debugging timestamps
From: Stanley Chu
Date: Sun Jul 31 2022 - 23:24:04 EST
Hi Daniil,
On Wed, Jul 20, 2022 at 6:49 PM Daniil Lunev <dlunev@xxxxxxxxxxxx> wrote:
>
> CLOCK_MONOTONIC is not advanced when the system is in suspend. This
> becomes problematic when debugging issues related to suspend-resume:
> the timestamps printed by ufshcd_print_trs can not be correlated with
> dmesg entries, which are timestamped with CLOCK_BOOTTIME.
>
> This CL changes the used clock to CLOCK_BOOTTIME for the informational
> timestamp variables and adds mirroring CLOCK_BOOTIME instances for
> variables used in subsequent derevations (to not change the semantics of
> those derevations).
>
> Signed-off-by: Daniil Lunev <dlunev@xxxxxxxxxxxx>
>
Regarding the suspend/resume issue breakdown with aligned timestamp
with the dmesg logs, perhaps we need to use "sched_clock()" since it
is the timestamp used by dmesg?
Thanks,
Stanley