diff options
| author | David S. Miller <davem@davemloft.net> | 2018-02-14 19:55:39 +0300 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2018-02-14 19:55:39 +0300 |
| commit | 1d631583ae5e40681dc9a41d7cfa845222c3c7ff (patch) | |
| tree | 1480abf507a78bdb5989340d061e8fb7b593f5d7 /include/linux | |
| parent | 77079683617b60387ad23e91cc5b82693b3075ab (diff) | |
| parent | e92bad5034922776bd5e64e3db739d7607eb7e29 (diff) | |
| download | linux-1d631583ae5e40681dc9a41d7cfa845222c3c7ff.tar.xz | |
Merge branch 'net-dev-Make-protocol-ptr-dependent-on-CONFIG'
David Ahern says:
====================
net: dev: Make protocol ptr dependent on CONFIG
Found these in a branch from 3-years ago. Still relevant today.
Make decnet, ax25, and atalk ptrs in net_device based on their
respective CONFIG.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/atalk.h | 2 | ||||
| -rw-r--r-- | include/linux/netdevice.h | 6 |
2 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/atalk.h b/include/linux/atalk.h index 4d356e168692..40373920ea58 100644 --- a/include/linux/atalk.h +++ b/include/linux/atalk.h @@ -113,10 +113,12 @@ extern void aarp_proto_init(void); /* Inter module exports */ /* Give a device find its atif control structure */ +#if IS_ENABLED(CONFIG_IRDA) || IS_ENABLED(CONFIG_ATALK) static inline struct atalk_iface *atalk_find_dev(struct net_device *dev) { return dev->atalk_ptr; } +#endif extern struct atalk_addr *atalk_find_dev_addr(struct net_device *dev); extern struct net_device *atrtr_get_dev(struct atalk_addr *sa); diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 5eef6c8e2741..dbe6344b727a 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -1798,11 +1798,17 @@ struct net_device { #if IS_ENABLED(CONFIG_TIPC) struct tipc_bearer __rcu *tipc_ptr; #endif +#if IS_ENABLED(CONFIG_IRDA) || IS_ENABLED(CONFIG_ATALK) void *atalk_ptr; +#endif struct in_device __rcu *ip_ptr; +#if IS_ENABLED(CONFIG_DECNET) struct dn_dev __rcu *dn_ptr; +#endif struct inet6_dev __rcu *ip6_ptr; +#if IS_ENABLED(CONFIG_AX25) void *ax25_ptr; +#endif struct wireless_dev *ieee80211_ptr; struct wpan_dev *ieee802154_ptr; #if IS_ENABLED(CONFIG_MPLS_ROUTING) |
