Browse Source

net: add RTNL_ASSERT in __netdev_update_features()

Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
Michał Mirosław 14 năm trước cách đây
mục cha
commit
872674858f
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      net/core/dev.c

+ 2 - 0
net/core/dev.c

@@ -5247,6 +5247,8 @@ int __netdev_update_features(struct net_device *dev)
 	u32 features;
 	int err = 0;
 
+	ASSERT_RTNL();
+
 	features = netdev_get_wanted_features(dev);
 
 	if (dev->netdev_ops->ndo_fix_features)