bnx2x: Prevent VF race
authorDmitry Kravkov <[email protected]>
Wed, 27 Mar 2013 01:05:17 +0000 (01:05 +0000)
committerDavid S. Miller <[email protected]>
Wed, 27 Mar 2013 16:48:32 +0000 (12:48 -0400)
commit1d6f3cd8988822c7bdc3c685fac0a99315e83400
treea66c7d4931aa49336e07e97d3a44ee674a05f79c
parent21776537b15f72dc9d8c16b00439fbdaa8ce7a34
bnx2x: Prevent VF race

The mail box containing the Vf-Pf messages is susceptible
to a race - it's possible for 2 flows to try and write commands,
causing one to override the other's message.
Use a mutex to synchronize the access, preventing said race.

Signed-off-by: Dmitry Kravkov <[email protected]>
Signed-off-by: Yuval Mintz <[email protected]>
Signed-off-by: Ariel Elior <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
drivers/net/ethernet/broadcom/bnx2x/bnx2x.h
drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.h
drivers/net/ethernet/broadcom/bnx2x/bnx2x_vfpf.c