]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
mm-vmstat-fix-proc-sys-vm-stat_refresh-generating-false-warnings-fix
authorRoman Gushchin <guro@fb.com>
Thu, 31 Dec 2020 22:04:28 +0000 (22:04 +0000)
committerJohannes Weiner <hannes@cmpxchg.org>
Thu, 31 Dec 2020 22:04:28 +0000 (22:04 +0000)
fix warnings

Link: http://lkml.kernel.org/r/20200717174705.GA55916@carbon.DHCP.thefacebook.com
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/vmstat.c

index 69c3ae37c97d6c2e4808b0844d534bff0f7c888d..3c05d02b5baecfe307fc97eec79c11922647eb10 100644 (file)
@@ -168,9 +168,12 @@ EXPORT_SYMBOL(vm_numa_stat);
 EXPORT_SYMBOL(vm_node_stat);
 
 #ifdef CONFIG_SMP
-
 #define MAX_THRESHOLD 125
+#else
+#define MAX_THRESHOLD 0
+#endif
 
+#ifdef CONFIG_SMP
 int calculate_pressure_threshold(struct zone *zone)
 {
        int threshold;
@@ -611,8 +614,6 @@ void dec_node_page_state(struct page *page, enum node_stat_item item)
 EXPORT_SYMBOL(dec_node_page_state);
 #else
 
-#define MAX_THRESHOLD 0
-
 /*
  * Use interrupt disable to serialize counter updates
  */