[PATCH] hotplug CPU: clean up hotcpu_notifier() use
There was lots of #ifdef noise in the kernel due to hotcpu_notifier(fn, prio) not correctly marking 'fn' as used in the !HOTPLUG_CPU case, and thus generating compiler warnings of unused symbols, hence forcing people to add #ifdefs. the compiler can skip truly unused functions just fine: text data bss dec hex filename 1624412 728710 3674856 6027978 5bfaca vmlinux.before 1624412 728710 3674856 6027978 5bfaca vmlinux.after [akpm@osdl.org: topology.c fix] Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
a38a44c1a9
commit
0231606785
@ -701,7 +701,6 @@ void drain_node_pages(int nodeid)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_PM) || defined(CONFIG_HOTPLUG_CPU)
|
||||
static void __drain_pages(unsigned int cpu)
|
||||
{
|
||||
unsigned long flags;
|
||||
@ -723,7 +722,6 @@ static void __drain_pages(unsigned int cpu)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif /* CONFIG_PM || CONFIG_HOTPLUG_CPU */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
|
||||
@ -2907,7 +2905,6 @@ void __init free_area_init(unsigned long *zones_size)
|
||||
__pa(PAGE_OFFSET) >> PAGE_SHIFT, NULL);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
static int page_alloc_cpu_notify(struct notifier_block *self,
|
||||
unsigned long action, void *hcpu)
|
||||
{
|
||||
@ -2922,7 +2919,6 @@ static int page_alloc_cpu_notify(struct notifier_block *self,
|
||||
}
|
||||
return NOTIFY_OK;
|
||||
}
|
||||
#endif /* CONFIG_HOTPLUG_CPU */
|
||||
|
||||
void __init page_alloc_init(void)
|
||||
{
|
||||
|
Reference in New Issue
Block a user