Thread (29 messages) 29 messages, 5 authors, 2023-12-18

Re: [PATCH 03/15] kexec: Add Kexec HandOver (KHO) generation helpers

From: Alexander Graf <graf@amazon.com>
Date: 2023-12-13 23:37:06
Also in: kexec, linux-arm-kernel, linux-devicetree, linux-doc, linux-mm, lkml

On 13.12.23 19:36, Stanislav Kinsburskii wrote:
On Wed, Dec 13, 2023 at 12:04:40AM +0000, Alexander Graf wrote:
quoted
+int register_kho_notifier(struct notifier_block *nb)
+{
+     return blocking_notifier_chain_register(&kho.chain_head, nb);
+}
+EXPORT_SYMBOL_GPL(register_kho_notifier);
+
+int unregister_kho_notifier(struct notifier_block *nb)
+{
+     return blocking_notifier_chain_unregister(&kho.chain_head, nb);
+}
+EXPORT_SYMBOL_GPL(unregister_kho_notifier);
+
+bool kho_is_active(void)
+{
+     return kho.active;
+}
+EXPORT_SYMBOL_GPL(kho_is_active);
+
Why should these helpers be restricted to GPL code?

That's a simple one: Everything should be EXPORT_SYMBOL_GPL by default. 
You need to have really good reasons to export anything for non-GPL 
modules. I don't have a good reason for them, so it's GPL only :)


Alex





Amazon Development Center Germany GmbH
Krausenstr. 38
10117 Berlin
Geschaeftsfuehrung: Christian Schlaeger, Jonathan Weiss
Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B
Sitz: Berlin
Ust-ID: DE 289 237 879

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help