aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/module.c
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2010-06-05 13:17:36 -0400
committerRusty Russell <rusty@rustcorp.com.au>2010-06-04 21:47:36 -0400
commit6407ebb271fc34440b306f305e1efb7685eece26 (patch)
treedd3fa7484bcaa4499138d2249dbed24f003fdf85 /kernel/module.c
parent80a3d1bb410e000e176931a076cdf19a1e89a955 (diff)
module: Make module sysfs functions private.
These were placed in the header in ef665c1a06 to get the various SYSFS/MODULE config combintations to compile. That may have been necessary then, but it's not now. These functions are all local to module.c. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Cc: Randy Dunlap <randy.dunlap@oracle.com>
Diffstat (limited to 'kernel/module.c')
-rw-r--r--kernel/module.c29
1 files changed, 25 insertions, 4 deletions
diff --git a/kernel/module.c b/kernel/module.c
index c690d9885797..808aa18dd661 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -1323,7 +1323,7 @@ static void del_usage_links(struct module *mod)
1323#endif 1323#endif
1324} 1324}
1325 1325
1326int module_add_modinfo_attrs(struct module *mod) 1326static int module_add_modinfo_attrs(struct module *mod)
1327{ 1327{
1328 struct module_attribute *attr; 1328 struct module_attribute *attr;
1329 struct module_attribute *temp_attr; 1329 struct module_attribute *temp_attr;
@@ -1349,7 +1349,7 @@ int module_add_modinfo_attrs(struct module *mod)
1349 return error; 1349 return error;
1350} 1350}
1351 1351
1352void module_remove_modinfo_attrs(struct module *mod) 1352static void module_remove_modinfo_attrs(struct module *mod)
1353{ 1353{
1354 struct module_attribute *attr; 1354 struct module_attribute *attr;
1355 int i; 1355 int i;
@@ -1365,7 +1365,7 @@ void module_remove_modinfo_attrs(struct module *mod)
1365 kfree(mod->modinfo_attrs); 1365 kfree(mod->modinfo_attrs);
1366} 1366}
1367 1367
1368int mod_sysfs_init(struct module *mod) 1368static int mod_sysfs_init(struct module *mod)
1369{ 1369{
1370 int err; 1370 int err;
1371 struct kobject *kobj; 1371 struct kobject *kobj;
@@ -1399,7 +1399,7 @@ out:
1399 return err; 1399 return err;
1400} 1400}
1401 1401
1402int mod_sysfs_setup(struct module *mod, 1402static int mod_sysfs_setup(struct module *mod,
1403 struct kernel_param *kparam, 1403 struct kernel_param *kparam,
1404 unsigned int num_params) 1404 unsigned int num_params)
1405{ 1405{
@@ -1445,6 +1445,27 @@ static void mod_sysfs_fini(struct module *mod)
1445 1445
1446#else /* CONFIG_SYSFS */ 1446#else /* CONFIG_SYSFS */
1447 1447
1448static inline int mod_sysfs_init(struct module *mod)
1449{
1450 return 0;
1451}
1452
1453static inline int mod_sysfs_setup(struct module *mod,
1454 struct kernel_param *kparam,
1455 unsigned int num_params)
1456{
1457 return 0;
1458}
1459
1460static inline int module_add_modinfo_attrs(struct module *mod)
1461{
1462 return 0;
1463}
1464
1465static inline void module_remove_modinfo_attrs(struct module *mod)
1466{
1467}
1468
1448static void mod_sysfs_fini(struct module *mod) 1469static void mod_sysfs_fini(struct module *mod)
1449{ 1470{
1450} 1471}