RCU: export rcu_idle_enter/_exit for loadable modules
PATCH 1/1 RCU: export rcu_idle_enter/_exit for loadable modules
drivers/acpi/processor.ko uses rcu_idle_enter()/_exit() but they are not exported. This causes build errors on IA64, so export those 2 functions.
ERROR: modpost: "rcu_idle_enter" [drivers/acpi/processor.ko] undefined!
ERROR: modpost: "rcu_idle_exit" [drivers/acpi/processor.ko] undefined!
---
Is there a problem with exporting these functions for use by loadable modules? If so, this driver should be modified not to use rcu_idle_enter/exit.
kernel/rcu/tree.c | 2 ++ 1 file changed, 2 insertions(+)
kernel/rcu/tree.c +2 -0
@@ -673,6 +673,7 @@ void rcu_idle_enter(void)lockdep_assert_irqs_disabled ();rcu_eqs_enter (false); } +EXPORT_SYMBOL_GPL (rcu_idle_enter);#ifdef CONFIG_NO_HZ_FULL /**
@@ -886,6 +887,7 @@ void rcu_idle_exit(void)rcu_eqs_exit (false);local_irq_restore (flags); } +EXPORT_SYMBOL_GPL (rcu_idle_exit);#ifdef CONFIG_NO_HZ_FULL /**
Paul E. McKenney
maintainerQuoted 18 lines · Randy Dunlap
drivers/acpi/processor.kouses rcu_idle_enter()/_exit() but they are not exported. This causes build errors on IA64, so export those 2 functions.ERROR: modpost: "
rcu_idle_enter" [drivers/acpi/processor.ko] undefined!
ERROR: modpost: "rcu_idle_exit" [drivers/acpi/processor.ko] undefined!Reported-by kernel test robot <[email protected]>Signed-off-by Randy Dunlap <[email protected]>Cc Rafael J. Wysocki <[email protected]>Cc Peter Zijlstra <[email protected]>Cc Tony Luck <[email protected]>Cc Fenghua Yu <[email protected]>Cc "Paul E. McKenney" <[email protected]>Cc Josh Triplett <[email protected]>
Quoted 4 lines
---
Is there a problem with exporting these functions for use by loadable modules? If so, this driver should be modified not to use rcu_idle_enter/exit.
Good catch, but Borislav Petkov beat you to it:
https://lore.kernel.org/lkml/[email protected]/
Rafael has applied Borislav's patch to his cpuidle tree for v5.9-rc7.
Thanx, Paul
Quoted 21 lines
kernel/rcu/tree.c | 2 ++ 1 file changed, 2 insertions(+)kernel/rcu/tree.c +2
-0@@ -673,6 +673,7 @@ void rcu_idle_enter(void)lockdep_assert_irqs_disabled ();rcu_eqs_enter (false); } +EXPORT_SYMBOL_GPL (rcu_idle_enter);#ifdef CONFIG_NO_HZ_FULL /** @@ -886,6 +887,7 @@ void rcu_idle_exit(void)rcu_eqs_exit (false);local_irq_restore (flags); } +EXPORT_SYMBOL_GPL (rcu_idle_exit);#ifdef CONFIG_NO_HZ_FULL /**