The hotplug code in the ring buffers is for use with CPU hotplug,
not generic hotplug.
Reported-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
struct ring_buffer_per_cpu **buffers;
struct ring_buffer_per_cpu **buffers;
+#ifdef CONFIG_HOTPLUG_CPU
struct notifier_block cpu_notify;
#endif
};
struct notifier_block cpu_notify;
#endif
};
*/
extern int ring_buffer_page_too_big(void);
*/
extern int ring_buffer_page_too_big(void);
+#ifdef CONFIG_HOTPLUG_CPU
static int __cpuinit rb_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu);
#endif
static int __cpuinit rb_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu);
#endif
goto fail_free_buffers;
}
goto fail_free_buffers;
}
+#ifdef CONFIG_HOTPLUG_CPU
buffer->cpu_notify.notifier_call = rb_cpu_notify;
buffer->cpu_notify.priority = 0;
register_cpu_notifier(&buffer->cpu_notify);
buffer->cpu_notify.notifier_call = rb_cpu_notify;
buffer->cpu_notify.priority = 0;
register_cpu_notifier(&buffer->cpu_notify);
+#ifdef CONFIG_HOTPLUG_CPU
unregister_cpu_notifier(&buffer->cpu_notify);
#endif
unregister_cpu_notifier(&buffer->cpu_notify);
#endif
fs_initcall(rb_init_debugfs);
fs_initcall(rb_init_debugfs);
+#ifdef CONFIG_HOTPLUG_CPU
static int __cpuinit rb_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu)
{
static int __cpuinit rb_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu)
{