public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] srcu: Export srcu_check_nmi_safety() to modules
@ 2022-10-18  1:39 Zqiang
  2022-10-18  1:57 ` Joel Fernandes
  2022-10-18 10:45 ` Frederic Weisbecker
  0 siblings, 2 replies; 5+ messages in thread
From: Zqiang @ 2022-10-18  1:39 UTC (permalink / raw)
  To: paulmck, frederic, joel; +Cc: rcu, linux-kernel

When enable CONFIG_PROVE_RCU and built modules, the following
error appear:

ERROR: modpost: "srcu_check_nmi_safety" [kernel/rcu/rcutorture.ko] undefined!
ERROR: modpost: "srcu_check_nmi_safety" [kernel/rcu/rcuscale.ko] undefined!

This commit fix it by exporting the srcu_check_nmi_safety().

Signed-off-by: Zqiang <qiang1.zhang@intel.com>
---
 kernel/rcu/srcutree.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/kernel/rcu/srcutree.c b/kernel/rcu/srcutree.c
index 382236dd5e46..bcd629f5f902 100644
--- a/kernel/rcu/srcutree.c
+++ b/kernel/rcu/srcutree.c
@@ -651,6 +651,7 @@ void srcu_check_nmi_safety(struct srcu_struct *ssp, bool nmi_safe)
 	}
 	WARN_ONCE(old_nmi_safe_mask != nmi_safe_mask, "CPU %d old state %d new state %d\n", sdp->cpu, old_nmi_safe_mask, nmi_safe_mask);
 }
+EXPORT_SYMBOL_GPL(srcu_check_nmi_safety);
 #endif /* CONFIG_PROVE_RCU */
 
 /*
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-10-18 19:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-18  1:39 [PATCH] srcu: Export srcu_check_nmi_safety() to modules Zqiang
2022-10-18  1:57 ` Joel Fernandes
2022-10-18 10:45 ` Frederic Weisbecker
2022-10-18 17:50   ` Paul E. McKenney
2022-10-18 19:05     ` Joel Fernandes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox