aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/ax25.h
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2012-04-19 09:34:18 -0400
committerDavid S. Miller <davem@davemloft.net>2012-04-20 21:22:28 -0400
commit0ca7a4c87d27dd2fde0783dec94a821d6d035696 (patch)
tree3f9d1cd9a8146ce751e43f8f103a255fc7ec199d /include/net/ax25.h
parent4e5ca78541c549ec8886ad2fc19306f35ee672e1 (diff)
net ax25: Simplify and cleanup the ax25 sysctl handling.
Don't register/unregister every ax25 table in a batch. Instead register and unregister per device ax25 sysctls as ax25 devices come and go. This moves ax25 to be a completely modern sysctl user. Registering the sysctls in just the initial network namespace, removing the use of .child entries that are no longer natively supported by the sysctl core and taking advantage of the fact that there are no longer any ordering constraints between registering and unregistering different sysctl tables. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Acked-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/ax25.h')
-rw-r--r--include/net/ax25.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/net/ax25.h b/include/net/ax25.h
index 94e09d361bb..8a7a1220e67 100644
--- a/include/net/ax25.h
+++ b/include/net/ax25.h
@@ -215,7 +215,7 @@ typedef struct ax25_dev {
215 struct ax25_dev *next; 215 struct ax25_dev *next;
216 struct net_device *dev; 216 struct net_device *dev;
217 struct net_device *forward; 217 struct net_device *forward;
218 struct ctl_table *systable; 218 struct ctl_table_header *sysheader;
219 int values[AX25_MAX_VALUES]; 219 int values[AX25_MAX_VALUES];
220#if defined(CONFIG_AX25_DAMA_SLAVE) || defined(CONFIG_AX25_DAMA_MASTER) 220#if defined(CONFIG_AX25_DAMA_SLAVE) || defined(CONFIG_AX25_DAMA_MASTER)
221 ax25_dama_info dama; 221 ax25_dama_info dama;
@@ -441,11 +441,11 @@ extern void ax25_uid_free(void);
441 441
442/* sysctl_net_ax25.c */ 442/* sysctl_net_ax25.c */
443#ifdef CONFIG_SYSCTL 443#ifdef CONFIG_SYSCTL
444extern void ax25_register_sysctl(void); 444extern int ax25_register_dev_sysctl(ax25_dev *ax25_dev);
445extern void ax25_unregister_sysctl(void); 445extern void ax25_unregister_dev_sysctl(ax25_dev *ax25_dev);
446#else 446#else
447static inline void ax25_register_sysctl(void) {}; 447static inline int ax25_register_dev_sysctl(ax25_dev *ax25_dev) { return 0 };
448static inline void ax25_unregister_sysctl(void) {}; 448static inline void ax25_unregister_dev_sysctl(ax25_dev *ax25_dev) {};
449#endif /* CONFIG_SYSCTL */ 449#endif /* CONFIG_SYSCTL */
450 450
451#endif 451#endif