summaryrefslogtreecommitdiff
path: root/include/linux/module.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2016-03-05 18:10:51 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2016-03-05 18:10:51 -0500
commit05ef1c50e7c2f796460737a7a7c2d315dd166544 (patch)
tree2d6423856824019b445478ecab0fbc59d70a6ed5 /include/linux/module.h
parent97c31606075b30d0c5d70e477f54bb3f222e048d (diff)
parenta528aca7f359f4b0b1d72ae406097e491a5ba9ea (diff)
Merge branch 'for-linus' into work.lookups
for the sake of namei.c fixes
Diffstat (limited to 'include/linux/module.h')
-rw-r--r--include/linux/module.h19
1 files changed, 10 insertions, 9 deletions
diff --git a/include/linux/module.h b/include/linux/module.h
index 4560d8f1545d..2bb0c3085706 100644
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -324,6 +324,12 @@ struct module_layout {
#define __module_layout_align
#endif
+struct mod_kallsyms {
+ Elf_Sym *symtab;
+ unsigned int num_symtab;
+ char *strtab;
+};
+
struct module {
enum module_state state;
@@ -405,15 +411,10 @@ struct module {
#endif
#ifdef CONFIG_KALLSYMS
- /*
- * We keep the symbol and string tables for kallsyms.
- * The core_* fields below are temporary, loader-only (they
- * could really be discarded after module init).
- */
- Elf_Sym *symtab, *core_symtab;
- unsigned int num_symtab, core_num_syms;
- char *strtab, *core_strtab;
-
+ /* Protected by RCU and/or module_mutex: use rcu_dereference() */
+ struct mod_kallsyms *kallsyms;
+ struct mod_kallsyms core_kallsyms;
+
/* Section attributes */
struct module_sect_attrs *sect_attrs;