summaryrefslogtreecommitdiff
path: root/scripts/mod/modpost.c
diff options
context:
space:
mode:
authorClark Williams <williams@redhat.com>2012-04-15 23:24:46 -0500
committerClark Williams <williams@redhat.com>2012-04-15 23:24:46 -0500
commit8e9c931b8e4150f3c5aaab7e4639cd507c30477c (patch)
tree4c77bef833db938a950c60095f628acc1ebff50a /scripts/mod/modpost.c
parent3524a83e5459ae4ba42f9bf098bb736b99b88695 (diff)
parente816b57a337ea3b755de72bec38c10c864f23015 (diff)
Merge commit 'v3.4-rc3' into rt-3.4-rc3-rt4v3.4-rc3-rt4
Diffstat (limited to 'scripts/mod/modpost.c')
-rw-r--r--scripts/mod/modpost.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
index 3f01fd908730..c4e7d1510f9d 100644
--- a/scripts/mod/modpost.c
+++ b/scripts/mod/modpost.c
@@ -132,8 +132,10 @@ static struct module *new_module(char *modname)
/* strip trailing .o */
s = strrchr(p, '.');
if (s != NULL)
- if (strcmp(s, ".o") == 0)
+ if (strcmp(s, ".o") == 0) {
*s = '\0';
+ mod->is_dot_o = 1;
+ }
/* add to list */
mod->name = p;
@@ -587,7 +589,8 @@ static void handle_modversions(struct module *mod, struct elf_info *info,
unsigned int crc;
enum export export;
- if (!is_vmlinux(mod->name) && strncmp(symname, "__ksymtab", 9) == 0)
+ if ((!is_vmlinux(mod->name) || mod->is_dot_o) &&
+ strncmp(symname, "__ksymtab", 9) == 0)
export = export_from_secname(info, get_secindex(info, sym));
else
export = export_from_sec(info, get_secindex(info, sym));