OSDN Git Service

hv_netvsc: Fix race between VF offering and VF association message from host
authorGaurav Kohli <gauravkohli@linux.microsoft.com>
Thu, 6 Oct 2022 05:52:59 +0000 (22:52 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 7 Oct 2022 07:43:58 +0000 (08:43 +0100)
commit365e1ececb2905f94cc10a5817c5b644a32a3ae2
tree7b397b41e30b0e5d4a9c6323acbb192552caf08c
parent30393181fdbc1608cc683b4ee99dcce05ffcc8c7
hv_netvsc: Fix race between VF offering and VF association message from host

During vm boot, there might be possibility that vf registration
call comes before the vf association from host to vm.

And this might break netvsc vf path, To prevent the same block
vf registration until vf bind message comes from host.

Cc: stable@vger.kernel.org
Fixes: 00d7ddba11436 ("hv_netvsc: pair VF based on serial number")
Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Gaurav Kohli <gauravkohli@linux.microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/hyperv/hyperv_net.h
drivers/net/hyperv/netvsc.c
drivers/net/hyperv/netvsc_drv.c