diff options
| author | Haiyang Zhang <[email protected]> | 2019-03-28 19:40:36 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2019-03-29 20:34:01 +0000 |
| commit | 1b704c4a1ba95574832e730f23817b651db2aa59 (patch) | |
| tree | 30f5fe2405cec13c5c291ee19dae6ec2005d3cef /drivers/net/hyperv/hyperv_net.h | |
| parent | bonding: show full hw address in sysfs for slave entries (diff) | |
| download | kernel-1b704c4a1ba95574832e730f23817b651db2aa59.tar.gz kernel-1b704c4a1ba95574832e730f23817b651db2aa59.zip | |
hv_netvsc: Fix unwanted wakeup after tx_disable
After queue stopped, the wakeup mechanism may wake it up again
when ring buffer usage is lower than a threshold. This may cause
send path panic on NULL pointer when we stopped all tx queues in
netvsc_detach and start removing the netvsc device.
This patch fix it by adding a tx_disable flag to prevent unwanted
queue wakeup.
Fixes: 7b2ee50c0cd5 ("hv_netvsc: common detach logic")
Reported-by: Mohammed Gamal <[email protected]>
Signed-off-by: Haiyang Zhang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'drivers/net/hyperv/hyperv_net.h')
| -rw-r--r-- | drivers/net/hyperv/hyperv_net.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h index e859ae2e42d5..49f41b64077b 100644 --- a/drivers/net/hyperv/hyperv_net.h +++ b/drivers/net/hyperv/hyperv_net.h @@ -987,6 +987,7 @@ struct netvsc_device { wait_queue_head_t wait_drain; bool destroy; + bool tx_disable; /* if true, do not wake up queue again */ /* Receive buffer allocated by us but manages by NetVSP */ void *recv_buf; |
