Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

Commit

Permalink
net: bridge: use netdev_lockdep_set_classes()
Browse files Browse the repository at this point in the history
br_set_lockdep_class() is missing many details.
Use generic netdev_lockdep_set_classes() to not worry anymore.

Signed-off-by: Eric Dumazet <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
  • Loading branch information
Eric Dumazet authored and kuba-moo committed Feb 14, 2024
1 parent 9a3c93a commit c74e103
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions net/bridge/br_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,6 @@ netdev_tx_t br_dev_xmit(struct sk_buff *skb, struct net_device *dev)
return NETDEV_TX_OK;
}

static struct lock_class_key bridge_netdev_addr_lock_key;

static void br_set_lockdep_class(struct net_device *dev)
{
lockdep_set_class(&dev->addr_list_lock, &bridge_netdev_addr_lock_key);
}

static int br_dev_init(struct net_device *dev)
{
struct net_bridge *br = netdev_priv(dev);
Expand Down Expand Up @@ -153,7 +146,7 @@ static int br_dev_init(struct net_device *dev)
br_fdb_hash_fini(br);
}

br_set_lockdep_class(dev);
netdev_lockdep_set_classes(dev);
return err;
}

Expand Down

0 comments on commit c74e103

Please sign in to comment.