ALT Linux Bugzilla
– Attachment 311 Details for
Bug 3248
insmod from busybox cannot load some modules
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
busybox-0.60.5-alt-insmod-gplonly.patch
busybox-0.60.5-alt-insmod-gplonly.patch (text/plain), 1.26 KB, created by
Dmitry V. Levin
on 2003-11-09 23:32:57 MSK
(
hide
)
Description:
busybox-0.60.5-alt-insmod-gplonly.patch
Filename:
MIME Type:
Creator:
Dmitry V. Levin
Created:
2003-11-09 23:32:57 MSK
Size:
1.26 KB
patch
obsolete
>--- busybox/insmod.c.orig 2002-09-16 09:30:10 +0400 >+++ busybox/insmod.c 2003-11-09 23:29:40 +0300 >@@ -607,6 +607,8 @@ static enum obj_reloc arch_apply_relocat > > static void arch_create_got (struct obj_file *f); > >+static int obj_gpl_license(struct obj_file *f, const char **license); >+ > #ifdef BB_FEATURE_NEW_MODULE_INTERFACE > static int arch_init_module (struct obj_file *f, struct new_module *); > #endif >@@ -1709,6 +1711,7 @@ add_symbols_from( > struct new_module_symbol *s; > size_t i; > int used = 0; >+ int gpl = obj_gpl_license(f, NULL) == 0; > > for (i = 0, s = syms; i < nsyms; ++i, ++s) { > >@@ -1717,6 +1720,19 @@ add_symbols_from( > We will also create a false dependency on the module. */ > struct obj_symbol *sym; > >+ /* GPL licensed modules can use symbols exported with >+ * EXPORT_SYMBOL_GPL, so ignore any GPLONLY_ prefix on the >+ * exported names. Non-GPL modules never see any GPLONLY_ >+ * symbols so they cannot fudge it by adding the prefix on >+ * their references. >+ */ >+ if (strncmp((char *)s->name, "GPLONLY_", 8) == 0) { >+ if (gpl) >+ ((char *)s->name) += 8; >+ else >+ continue; >+ } >+ > sym = obj_find_symbol(f, (char *) s->name); > if (sym && !ELFW(ST_BIND) (sym->info) == STB_LOCAL) { > sym = obj_add_symbol(f, (char *) s->name, -1,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 3248
:
310
| 311