cpu-hotplug: Add the function 'cpu_hotplug_inprogress'
Allows a caller to detect whether a cpu hotplug operation
is in progress. This is useful for optimizing code paths
based on this condition.
Signed-off-by: Maya Spivak <mspivak@codeaurora.org>
diff --git a/include/linux/cpu.h b/include/linux/cpu.h
index 97f1ca7..8d0ca45 100644
--- a/include/linux/cpu.h
+++ b/include/linux/cpu.h
@@ -134,6 +134,7 @@
extern void get_online_cpus(void);
extern void put_online_cpus(void);
+extern bool cpu_hotplug_inprogress(void);
#define hotcpu_notifier(fn, pri) cpu_notifier(fn, pri)
#define register_hotcpu_notifier(nb) register_cpu_notifier(nb)
#define unregister_hotcpu_notifier(nb) unregister_cpu_notifier(nb)