]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - include/linux/moduleparam.h
sysfs: fix build errors: uevent with CONFIG_SYSFS=n
[net-next-2.6.git] / include / linux / moduleparam.h
index 4a189dadb1607a0984cb41cac9f389d2a86afc65..b26b2e5fedc7146f3c21db9c8e5e382b3164f718 100644 (file)
@@ -169,10 +169,22 @@ extern int param_get_string(char *buffer, struct kernel_param *kp);
 
 struct module;
 
+#if defined(CONFIG_SYSFS) && defined(CONFIG_MODULES)
 extern int module_param_sysfs_setup(struct module *mod,
                                    struct kernel_param *kparam,
                                    unsigned int num_params);
 
 extern void module_param_sysfs_remove(struct module *mod);
+#else
+static inline int module_param_sysfs_setup(struct module *mod,
+                            struct kernel_param *kparam,
+                            unsigned int num_params)
+{
+       return 0;
+}
+
+static inline void module_param_sysfs_remove(struct module *mod)
+{ }
+#endif
 
 #endif /* _LINUX_MODULE_PARAMS_H */