linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm/page_alloc: make pcpu_drain_mutex and pcpu_drain static
@ 2020-04-07  2:39 Jason Yan
  0 siblings, 0 replies; only message in thread
From: Jason Yan @ 2020-04-07  2:39 UTC (permalink / raw)
  To: akpm, linux-mm; +Cc: Jason Yan

Fix the following sparse warning:

mm/page_alloc.c:106:1: warning: symbol 'pcpu_drain_mutex' was not
declared. Should it be static?
mm/page_alloc.c:107:1: warning: symbol '__pcpu_scope_pcpu_drain' was not
declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 mm/page_alloc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 84c04eb0ca68..0733f6f30590 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -103,8 +103,8 @@ struct pcpu_drain {
 	struct zone *zone;
 	struct work_struct work;
 };
-DEFINE_MUTEX(pcpu_drain_mutex);
-DEFINE_PER_CPU(struct pcpu_drain, pcpu_drain);
+static DEFINE_MUTEX(pcpu_drain_mutex);
+static DEFINE_PER_CPU(struct pcpu_drain, pcpu_drain);
 
 #ifdef CONFIG_GCC_PLUGIN_LATENT_ENTROPY
 volatile unsigned long latent_entropy __latent_entropy;
-- 
2.17.2



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-04-07  2:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-07  2:39 [PATCH] mm/page_alloc: make pcpu_drain_mutex and pcpu_drain static Jason Yan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox