be2net: Patch to determine if function is VF while running in guest OS.
When driver is loaded in guest OS, the pci variables is_virtfn and is_physfn are both set to 0. This change uses registers in controller to determine the same. Signed-off-by: Sarveshwar Bandi <sarveshwarb@serverengines.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
1ebed71ae2
commit
344dbf1073
@@ -1631,6 +1631,7 @@ static void be_sriov_enable(struct be_adapter *adapter)
|
||||
{
|
||||
#ifdef CONFIG_PCI_IOV
|
||||
int status;
|
||||
be_check_sriov_fn_type(adapter);
|
||||
if (be_physfn(adapter) && num_vfs) {
|
||||
status = pci_enable_sriov(adapter->pdev, num_vfs);
|
||||
adapter->sriov_enabled = status ? false : true;
|
||||
|
Reference in New Issue
Block a user