Skip to content

Commit

Permalink
mm/page_alloc: make pcpu_drain_mutex and pcpu_drain static
Browse files Browse the repository at this point in the history
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>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Link: http://lkml.kernel.org/r/20200407023925.46438-1-yanaijie@huawei.com
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Jason Yan authored and Linus Torvalds committed Apr 10, 2020
1 parent e6a0a7a commit 8b885f5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mm/page_alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 8b885f5

Please sign in to comment.