Commit 120fc3d7 authored by Kay Sievers's avatar Kay Sievers Committed by Greg Kroah-Hartman

modules: do not try to add sysfs attributes if !CONFIG_SYSFS

Thanks to Alexey for the testing and the fix of the fix.

Cc: Alexey Dobriyan <>
Signed-off-by: default avatarKay Sievers <>
Signed-off-by: default avatarGreg Kroah-Hartman <>
parent 58dc3232
......@@ -987,12 +987,11 @@ static unsigned long resolve_symbol(Elf_Shdr *sechdrs,
return ret;
* /sys/module/foo/sections stuff
* J. Corbet <>
#if defined(CONFIG_KALLSYMS) && defined(CONFIG_SYSFS)
static ssize_t module_sect_show(struct module_attribute *mattr,
struct module *mod, char *buf)
......@@ -1188,7 +1187,7 @@ static inline void add_notes_attrs(struct module *mod, unsigned int nsect,
static inline void remove_notes_attrs(struct module *mod)
#endif /* CONFIG_KALLSYMS */
int module_add_modinfo_attrs(struct module *mod)
......@@ -1231,9 +1230,7 @@ void module_remove_modinfo_attrs(struct module *mod)
int mod_sysfs_init(struct module *mod)
int err;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment