Explorar o código

ieee802154: 6lowpan: add RTNL assertion

This patch ensure that the rtnl lock is hold while newlink callback.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Alexander Aring %!s(int64=10) %!d(string=hai) anos
pai
achega
c37a8106de
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      net/ieee802154/6lowpan_rtnl.c

+ 2 - 0
net/ieee802154/6lowpan_rtnl.c

@@ -584,6 +584,8 @@ static int lowpan_newlink(struct net *src_net, struct net_device *dev,
 	struct lowpan_dev_record *entry;
 	int ret;
 
+	ASSERT_RTNL();
+
 	pr_debug("adding new link\n");
 
 	if (!tb[IFLA_LINK])