aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/net/net_namespace.h2
-rw-r--r--net/sysctl_net.c7
2 files changed, 9 insertions, 0 deletions
diff --git a/include/net/net_namespace.h b/include/net/net_namespace.h
index ee547c149810..446245e3adea 100644
--- a/include/net/net_namespace.h
+++ b/include/net/net_namespace.h
@@ -287,6 +287,8 @@ extern struct ctl_table_header *register_net_sysctl_table(struct net *net,
287 const struct ctl_path *path, struct ctl_table *table); 287 const struct ctl_path *path, struct ctl_table *table);
288extern struct ctl_table_header *register_net_sysctl_rotable( 288extern struct ctl_table_header *register_net_sysctl_rotable(
289 const struct ctl_path *path, struct ctl_table *table); 289 const struct ctl_path *path, struct ctl_table *table);
290extern struct ctl_table_header *register_net_sysctl(struct net *net,
291 const char *path, struct ctl_table *table);
290extern void unregister_net_sysctl_table(struct ctl_table_header *header); 292extern void unregister_net_sysctl_table(struct ctl_table_header *header);
291 293
292#endif /* __NET_NET_NAMESPACE_H */ 294#endif /* __NET_NET_NAMESPACE_H */
diff --git a/net/sysctl_net.c b/net/sysctl_net.c
index c3e65aebecc0..3865c4f76b82 100644
--- a/net/sysctl_net.c
+++ b/net/sysctl_net.c
@@ -117,6 +117,13 @@ struct ctl_table_header *register_net_sysctl_rotable(const
117} 117}
118EXPORT_SYMBOL_GPL(register_net_sysctl_rotable); 118EXPORT_SYMBOL_GPL(register_net_sysctl_rotable);
119 119
120struct ctl_table_header *register_net_sysctl(struct net *net,
121 const char *path, struct ctl_table *table)
122{
123 return __register_sysctl_table(&net->sysctls, path, table);
124}
125EXPORT_SYMBOL_GPL(register_net_sysctl);
126
120void unregister_net_sysctl_table(struct ctl_table_header *header) 127void unregister_net_sysctl_table(struct ctl_table_header *header)
121{ 128{
122 unregister_sysctl_table(header); 129 unregister_sysctl_table(header);