aboutsummaryrefslogtreecommitdiffstats
path: root/net/netrom
diff options
context:
space:
mode:
Diffstat (limited to 'net/netrom')
-rw-r--r--net/netrom/af_netrom.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c
index 74884f4a6255..819afc449e1e 100644
--- a/net/netrom/af_netrom.c
+++ b/net/netrom/af_netrom.c
@@ -74,6 +74,16 @@ static const struct proto_ops nr_proto_ops;
74 */ 74 */
75static struct lock_class_key nr_netdev_xmit_lock_key; 75static struct lock_class_key nr_netdev_xmit_lock_key;
76 76
77static void nr_set_lockdep_one(struct netdev_queue *txq)
78{
79 lockdep_set_class(&txq->_xmit_lock, &nr_netdev_xmit_lock_key);
80}
81
82static void nr_set_lockdep_key(struct net_device *dev)
83{
84 nr_set_lockdep_one(&dev->tx_queue);
85}
86
77/* 87/*
78 * Socket removal during an interrupt is now safe. 88 * Socket removal during an interrupt is now safe.
79 */ 89 */
@@ -1430,7 +1440,7 @@ static int __init nr_proto_init(void)
1430 free_netdev(dev); 1440 free_netdev(dev);
1431 goto fail; 1441 goto fail;
1432 } 1442 }
1433 lockdep_set_class(&dev->_xmit_lock, &nr_netdev_xmit_lock_key); 1443 nr_set_lockdep_key(dev);
1434 dev_nr[i] = dev; 1444 dev_nr[i] = dev;
1435 } 1445 }
1436 1446