Commit 2ea80b03 authored by MengEn Sun's avatar MengEn Sun Committed by Andrew Morton
Browse files

vmstat: call fold_vm_zone_numa_events() before show per zone NUMA event

Since 5.14-rc1, NUMA events will only be folded from per-CPU statistics to
per zone and global statistics when the user actually needs it.

Currently, the kernel has performs the fold operation when reading
/proc/vmstat, but does not perform the fold operation in /proc/zoneinfo. 
This can lead to inaccuracies in the following statistics in zoneinfo:
- numa_hit
- numa_miss
- numa_foreign
- numa_interleave
- numa_local
- numa_other

Therefore, before printing per-zone vm_numa_event when reading
/proc/zoneinfo, we should also perform the fold operation.

Link: https://lkml.kernel.org/r/1730433998-10461-1-git-send-email-mengensun@tencent.com


Fixes: f19298b9 ("mm/vmstat: convert NUMA statistics to basic NUMA counters")
Signed-off-by: default avatarMengEn Sun <mengensun@tencent.com>
Reviewed-by: default avatarJinLiang Zheng <alexjlzheng@tencent.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 9b5c87d4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment