Idle notifier not registered if CONFIG_X86_32 is defined, those callbacks are empty for X86_32 platform.
ifdef CONFIG_X86_64 void enter_idle(void); void exit_idle(void); else static inline void enter_idle(void) { } static inline void exit_idle(void) { } static inline void __exit_idle(void) { } endif Make this work on X86_32 platforms by removing the restriction for X86_64 Signed-off-by: Dyut Kumar Sil <dyut.k....@intel.com> Signed-off-by: Ashish K <ashis...@intel.com> Signed-off-by: Illyas Mansoor <illyas.mans...@intel.com> Reviewed-by: Cuesta, Fernand <fernand.cue...@intel.com> Reviewed-by: Cuesta, Fernand <fernand.cue...@intel.com> Reviewed-by: Kumar P, Mahesh <mahesh.kuma...@intel.com> Tested-by: Cuesta, Fernand <fernand.cue...@intel.com> --- arch/x86/include/asm/idle.h | 6 ------ arch/x86/kernel/process.c | 4 ---- 2 files changed, 10 deletions(-) diff --git a/arch/x86/include/asm/idle.h b/arch/x86/include/asm/idle.h index c5d1785..489ac46 100644 --- a/arch/x86/include/asm/idle.h +++ b/arch/x86/include/asm/idle.h @@ -8,14 +8,8 @@ struct notifier_block; void idle_notifier_register(struct notifier_block *n); void idle_notifier_unregister(struct notifier_block *n); -#ifdef CONFIG_X86_64 void enter_idle(void); void exit_idle(void); -#else /* !CONFIG_X86_64 */ -static inline void enter_idle(void) { } -static inline void exit_idle(void) { } -static inline void __exit_idle(void) { } -#endif /* CONFIG_X86_64 */ void amd_e400_remove_cpu(int cpu); diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c index 14ae100..043e553 100644 --- a/arch/x86/kernel/process.c +++ b/arch/x86/kernel/process.c @@ -38,7 +38,6 @@ */ DEFINE_PER_CPU_SHARED_ALIGNED(struct tss_struct, init_tss) = INIT_TSS; -#ifdef CONFIG_X86_64 static DEFINE_PER_CPU(unsigned char, is_idle); static ATOMIC_NOTIFIER_HEAD(idle_notifier); @@ -53,7 +52,6 @@ void idle_notifier_unregister(struct notifier_block *n) atomic_notifier_chain_unregister(&idle_notifier, n); } EXPORT_SYMBOL_GPL(idle_notifier_unregister); -#endif struct kmem_cache *task_xstate_cachep; EXPORT_SYMBOL_GPL(task_xstate_cachep); @@ -277,7 +275,6 @@ static inline void play_dead(void) } #endif -#ifdef CONFIG_X86_64 void enter_idle(void) { this_cpu_write(is_idle, 1); @@ -299,7 +296,6 @@ void exit_idle(void) return; __exit_idle(); } -#endif /* * The idle thread. There's no useful work to be -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/