diff options
Diffstat (limited to 'net/bridge/br_private.h')
-rw-r--r-- | net/bridge/br_private.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h index 7f439927a66d..a122684b6a41 100644 --- a/net/bridge/br_private.h +++ b/net/bridge/br_private.h @@ -284,6 +284,12 @@ static inline struct net_bridge_port *br_port_get_rtnl(const struct net_device * rtnl_dereference(dev->rx_handler_data) : NULL; } +static inline struct net_bridge_port *br_port_get_rtnl_rcu(const struct net_device *dev) +{ + return br_port_exists(dev) ? + rcu_dereference_rtnl(dev->rx_handler_data) : NULL; +} + struct net_bridge { spinlock_t lock; spinlock_t hash_lock; |