All of lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-wired-lan] [PATCH V2] ixgbe: Allow disabling VFs when they are pre-existing
@ 2017-04-01  0:26 Mark D Rustad
  2017-04-01 17:03 ` Duyck, Alexander H
  0 siblings, 1 reply; 3+ messages in thread
From: Mark D Rustad @ 2017-04-01  0:26 UTC (permalink / raw)
  To: intel-wired-lan

Right now if VFs existing when the driver is loaded, it is not
possible to destroy those VFs, even though messages from the driver
suggest doing that when trying to change the number. This change
permits the disabling of SR-IOV for the case when there are
pre-existing VFs.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
---
Changes in V2:
- Remove unwanted content in the changelog message - sorry about that
---
 src/CORE/ixgbe_sriov.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/CORE/ixgbe_sriov.c b/src/CORE/ixgbe_sriov.c
index 9b7d05110fe9..231acf274a70 100644
--- a/src/CORE/ixgbe_sriov.c
+++ b/src/CORE/ixgbe_sriov.c
@@ -603,7 +603,7 @@ static int ixgbe_pci_sriov_disable(struct pci_dev *dev)
 	u32 current_flags = adapter->flags;
 #endif
 
-	if (adapter->num_vfs == 0)
+	if (!adapter->num_vfs && !pci_num_vf(dev))
 		return -EINVAL;
 
 	err = ixgbe_disable_sriov(adapter);


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-04-03 16:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-01  0:26 [Intel-wired-lan] [PATCH V2] ixgbe: Allow disabling VFs when they are pre-existing Mark D Rustad
2017-04-01 17:03 ` Duyck, Alexander H
2017-04-03 16:48   ` Rustad, Mark D

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.