Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 776e726b authored by stephen hemminger's avatar stephen hemminger Committed by David S. Miller
Browse files

netvsc: fix RCU warning in get_stats



The statistics functionis called with RTNL held during probe
but with RCU held during access from /proc and elsewhere.
This is safe so update the lockdep annotation.

Signed-off-by: default avatarStephen Hemminger <sthemmin@microsoft.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1dbba4cb
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -943,7 +943,7 @@ static void netvsc_get_stats64(struct net_device *net,
			       struct rtnl_link_stats64 *t)
{
	struct net_device_context *ndev_ctx = netdev_priv(net);
	struct netvsc_device *nvdev = rcu_dereference(ndev_ctx->nvdev);
	struct netvsc_device *nvdev = rcu_dereference_rtnl(ndev_ctx->nvdev);
	int i;

	if (!nvdev)