Commit 58bc4c34 authored by Jann Horn's avatar Jann Horn Committed by Greg Kroah-Hartman

mm/vmstat.c: skip NR_TLB_REMOTE_FLUSH* properly

5dd0b16c ("mm/vmstat: Make NR_TLB_REMOTE_FLUSH_RECEIVED available even
on UP") made the availability of the NR_TLB_REMOTE_FLUSH* counters inside
the kernel unconditional to reduce #ifdef soup, but (either to avoid
showing dummy zero counters to userspace, or because that code was missed)
didn't update the vmstat_array, meaning that all following counters would
be shown with incorrect values.

This only affects kernel builds with

Fixes: 5dd0b16c ("mm/vmstat: Make NR_TLB_REMOTE_FLUSH_RECEIVED available even on UP")
Signed-off-by: default avatarJann Horn <>
Reviewed-by: default avatarKees Cook <>
Reviewed-by: default avatarAndrew Morton <>
Acked-by: default avatarMichal Hocko <>
Acked-by: default avatarRoman Gushchin <>
Cc: Davidlohr Bueso <>
Cc: Oleg Nesterov <>
Cc: Christoph Lameter <>
Cc: Kemi Wang <>
Cc: Andy Lutomirski <>
Cc: Ingo Molnar <>
Cc: <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarGreg Kroah-Hartman <>
parent 28e2c4bb
......@@ -1275,6 +1275,9 @@ const char * const vmstat_text[] = {
"", /* nr_tlb_remote_flush */
"", /* nr_tlb_remote_flush_received */
#endif /* CONFIG_SMP */
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment