Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

profiling: remove stale percpu flip buffer variables

For some reason I didn't see this issue on my arm64 or x86-64 builds,
but Stephen Rothwell reports that commit 2accfdb7eff6 ("profiling:
attempt to remove per-cpu profile flip buffer") left these static
variables around, and the powerpc build is unhappy about them:

kernel/profile.c:52:28: warning: 'cpu_profile_flip' defined but not used [-Wunused-variable]
52 | static DEFINE_PER_CPU(int, cpu_profile_flip);
| ^~~~~~~~~~~~~~~~
..

So remove these stale left-over remnants too.

Fixes: 2accfdb7eff6 ("profiling: attempt to remove per-cpu profile flip buffer")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

-6
-6
kernel/profile.c
··· 47 47 int prof_on __read_mostly; 48 48 EXPORT_SYMBOL_GPL(prof_on); 49 49 50 - #if defined(CONFIG_SMP) && defined(CONFIG_PROC_FS) 51 - static DEFINE_PER_CPU(struct profile_hit *[2], cpu_profile_hits); 52 - static DEFINE_PER_CPU(int, cpu_profile_flip); 53 - static DEFINE_MUTEX(profile_flip_mutex); 54 - #endif /* CONFIG_SMP */ 55 - 56 50 int profile_setup(char *str) 57 51 { 58 52 static const char schedstr[] = "schedule";