be2net: avoid disabling sriov while VFs are assigned
authorSathya Perla <sathya.perla@emulex.com>
Tue, 8 May 2012 19:41:24 +0000 (19:41 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 11 May 2012 03:33:00 +0000 (23:33 -0400)
Calling pci_disable_sriov() while VFs are assigned to VMs causes
kernel panic. This patch uses PCI_DEV_FLAGS_ASSIGNED bit state of the
VF's pci_dev to avoid this. Also, the unconditional function reset cmd
issued on a PF probe can delete the VF configuration for the
previously enabled VFs. A scratchpad register is now used to issue a
function reset only when needed (i.e., in a crash dump scenario.)

Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

No differences found