diff options
author | qiwu.chen <qiwuchen55@gmail.com> | 2024-09-24 16:50:04 +0800 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2024-09-26 14:01:44 -0700 |
commit | ff7f5ad7bce4fd14f8ed057f1f593ade2840e84d (patch) | |
tree | 9c5d5df74323baed25dcd838dde56676836d314b /mm | |
parent | 7bf1823e010e8db2fb649c790bd1b449a75f52d8 (diff) | |
download | linux-stable-ff7f5ad7bce4fd14f8ed057f1f593ade2840e84d.tar.gz linux-stable-ff7f5ad7bce4fd14f8ed057f1f593ade2840e84d.tar.bz2 linux-stable-ff7f5ad7bce4fd14f8ed057f1f593ade2840e84d.zip |
mm: kfence: fix elapsed time for allocated/freed track
Fix elapsed time for the allocated/freed track introduced by commit
62e73fd85d7bf.
Link: https://lkml.kernel.org/r/20240924085004.75401-1-qiwu.chen@transsion.com
Fixes: 62e73fd85d7b ("mm: kfence: print the elapsed time for allocated/freed track")
Signed-off-by: qiwu.chen <qiwu.chen@transsion.com>
Reviewed-by: Marco Elver <elver@google.com>
Cc: Alexander Potapenko <glider@google.com>
Cc: Dmitry Vyukov <dvyukov@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/kfence/report.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/kfence/report.c b/mm/kfence/report.c index 451991a3a8f2..6370c5207d1a 100644 --- a/mm/kfence/report.c +++ b/mm/kfence/report.c @@ -109,7 +109,7 @@ static void kfence_print_stack(struct seq_file *seq, const struct kfence_metadat const struct kfence_track *track = show_alloc ? &meta->alloc_track : &meta->free_track; u64 ts_sec = track->ts_nsec; unsigned long rem_nsec = do_div(ts_sec, NSEC_PER_SEC); - u64 interval_nsec = local_clock() - meta->alloc_track.ts_nsec; + u64 interval_nsec = local_clock() - track->ts_nsec; unsigned long rem_interval_nsec = do_div(interval_nsec, NSEC_PER_SEC); /* Timestamp matches printk timestamp format. */ |