linux-stable/drivers/net/hyperv
Haiyang Zhang f6f13c125e hv_netvsc: Fix unwanted wakeup in netvsc_attach()
When netvsc_attach() is called by operations like changing MTU, etc.,
an extra wakeup may happen while netvsc_attach() calling
rndis_filter_device_add() which sends rndis messages when queue is
stopped in netvsc_detach(). The completion message will wake up queue 0.

We can reproduce the issue by changing MTU etc., then the wake_queue
counter from "ethtool -S" will increase beyond stop_queue counter:
     stop_queue: 0
     wake_queue: 1
The issue causes queue wake up, and counter increment, no other ill
effects in current code. So we didn't see any network problem for now.

To fix this, initialize tx_disable to true, and set it to false when
the NIC is ready to be attached or registered.

Fixes: 7b2ee50c0c ("hv_netvsc: common detach logic")
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-02-23 16:32:37 -08:00
..
hyperv_net.h hv_netvsc: Add XDP support 2020-01-25 10:43:19 +01:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile hv_netvsc: Add XDP support 2020-01-25 10:43:19 +01:00
netvsc.c hv_netvsc: Fix unwanted wakeup in netvsc_attach() 2020-02-23 16:32:37 -08:00
netvsc_bpf.c hv_netvsc: Fix XDP refcnt for synthetic and VF NICs 2020-02-07 11:33:01 +01:00
netvsc_drv.c hv_netvsc: Fix unwanted wakeup in netvsc_attach() 2020-02-23 16:32:37 -08:00
netvsc_trace.c hv_netvsc: add trace points 2018-03-17 20:10:27 -04:00
netvsc_trace.h hv_netvsc: add trace points 2018-03-17 20:10:27 -04:00
rndis_filter.c hv_netvsc: Add XDP support 2020-01-25 10:43:19 +01:00