From: Magnus Damm fix vm_events_fold_cpu() build breakage 2.6.20-rc1 does not build properly if CONFIG_VM_EVENT_COUNTERS is set and CONFIG_HOTPLUG is unset: CC init/version.o LD init/built-in.o LD .tmp_vmlinux1 mm/built-in.o: In function `page_alloc_cpu_notify': page_alloc.c:(.text+0x56eb): undefined reference to `vm_events_fold_cpu' make: *** [.tmp_vmlinux1] Error 1 Signed-off-by: Magnus Damm Cc: Christoph Lameter Signed-off-by: Andrew Morton --- include/linux/vmstat.h | 4 ++++ 1 file changed, 4 insertions(+) diff -puN include/linux/vmstat.h~fix-vm_events_fold_cpu-build-breakage include/linux/vmstat.h --- a/include/linux/vmstat.h~fix-vm_events_fold_cpu-build-breakage +++ a/include/linux/vmstat.h @@ -81,7 +81,11 @@ static inline void count_vm_events(enum } extern void all_vm_events(unsigned long *); +#ifdef CONFIG_HOTPLUG extern void vm_events_fold_cpu(int cpu); +#else +#define vm_events_fold_cpu(x) do { } while (0) +#endif #else _