projects/linux·commit 9b37ccfc

module: allow ndiswrapper to use GPL-only symbols

9b37ccfc · Pavel Roskin <[email protected]> · 2008-02-28 17:11:02 -05:00

A change after 2.6.24 broke ndiswrapper by accidentally removing its
access to GPL-only symbols.  Revert that change and add comments about
the reasons why ndiswrapper and driverloader are treated in a special
way.

Signed-off-by: Pavel Roskin <[email protected]>
Acked-by: Greg KH <[email protected]>
Acked-by: Ingo Molnar <[email protected]>
Cc: Rusty Russell <[email protected]>
Cc: Jon Masters <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Commit
9b37ccfc637be27d9a652fcedc35e6e782c3aa78
Parents
27d0483a

Changes

1 files changed · +8 −1

FileStatusAddDelContent
kernel/module.cmodified+8−1View file

kernel/module.c

View file
diff --git a/kernel/module.c b/kernel/module.c
index 901cd6a..be4807f 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -1933,8 +1933,15 @@ static struct module *load_module(void __user *umod,
/* Set up license info based on the info section */
set_license(mod, get_modinfo(sechdrs, infoindex, "license"));
+ /*
+ * ndiswrapper is under GPL by itself, but loads proprietary modules.
+ * Don't use add_taint_module(), as it would prevent ndiswrapper from
+ * using GPL-only symbols it needs.
+ */
if (strcmp(mod->name, "ndiswrapper") == 0)
- add_taint_module(mod, TAINT_PROPRIETARY_MODULE);
+ add_taint(TAINT_PROPRIETARY_MODULE);
+
+ /* driverloader was caught wrongly pretending to be under GPL */
if (strcmp(mod->name, "driverloader") == 0)
add_taint_module(mod, TAINT_PROPRIETARY_MODULE);