Skip to content

Commit 330c727

Browse files
dsaherndavem330
authored andcommitted
net: Make dn_ptr depend on CONFIG_DECNET
Signed-off-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 7707968 commit 330c727

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

‎include/linux/netdevice.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1800,7 +1800,9 @@ struct net_device {
18001800
#endif
18011801
void *atalk_ptr;
18021802
struct in_device __rcu *ip_ptr;
1803+
#if IS_ENABLED(CONFIG_DECNET)
18031804
struct dn_dev __rcu *dn_ptr;
1805+
#endif
18041806
struct inet6_dev __rcu *ip6_ptr;
18051807
void *ax25_ptr;
18061808
struct wireless_dev *ieee80211_ptr;

‎net/core/dev.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8134,8 +8134,9 @@ void netdev_run_todo(void)
81348134
BUG_ON(!list_empty(&dev->ptype_specific));
81358135
WARN_ON(rcu_access_pointer(dev->ip_ptr));
81368136
WARN_ON(rcu_access_pointer(dev->ip6_ptr));
8137+
#if IS_ENABLED(CONFIG_DECNET)
81378138
WARN_ON(dev->dn_ptr);
8138-
8139+
#endif
81398140
if (dev->priv_destructor)
81408141
dev->priv_destructor(dev);
81418142
if (dev->needs_free_netdev)

0 commit comments

Comments
 (0)