mirror of
https://github.com/FEX-Emu/linux.git
synced 2025-02-03 17:44:54 +00:00
ixgbe: Fix compile for kernel without CONFIG_PCI_IOV defined
Fix compiler errors and warnings with CONFIG_PCI_IOV defined and not defined. Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
1a6422f67f
commit
012641082b
@ -442,12 +442,14 @@ static int ixgbe_set_vf_macvlan(struct ixgbe_adapter *adapter,
|
|||||||
|
|
||||||
int ixgbe_check_vf_assignment(struct ixgbe_adapter *adapter)
|
int ixgbe_check_vf_assignment(struct ixgbe_adapter *adapter)
|
||||||
{
|
{
|
||||||
|
#ifdef CONFIG_PCI_IOV
|
||||||
int i;
|
int i;
|
||||||
for (i = 0; i < adapter->num_vfs; i++) {
|
for (i = 0; i < adapter->num_vfs; i++) {
|
||||||
if (adapter->vfinfo[i].vfdev->dev_flags &
|
if (adapter->vfinfo[i].vfdev->dev_flags &
|
||||||
PCI_DEV_FLAGS_ASSIGNED)
|
PCI_DEV_FLAGS_ASSIGNED)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -42,11 +42,11 @@ int ixgbe_ndo_set_vf_spoofchk(struct net_device *netdev, int vf, bool setting);
|
|||||||
int ixgbe_ndo_get_vf_config(struct net_device *netdev,
|
int ixgbe_ndo_get_vf_config(struct net_device *netdev,
|
||||||
int vf, struct ifla_vf_info *ivi);
|
int vf, struct ifla_vf_info *ivi);
|
||||||
void ixgbe_check_vf_rate_limit(struct ixgbe_adapter *adapter);
|
void ixgbe_check_vf_rate_limit(struct ixgbe_adapter *adapter);
|
||||||
#ifdef CONFIG_PCI_IOV
|
|
||||||
void ixgbe_disable_sriov(struct ixgbe_adapter *adapter);
|
void ixgbe_disable_sriov(struct ixgbe_adapter *adapter);
|
||||||
|
int ixgbe_check_vf_assignment(struct ixgbe_adapter *adapter);
|
||||||
|
#ifdef CONFIG_PCI_IOV
|
||||||
void ixgbe_enable_sriov(struct ixgbe_adapter *adapter,
|
void ixgbe_enable_sriov(struct ixgbe_adapter *adapter,
|
||||||
const struct ixgbe_info *ii);
|
const struct ixgbe_info *ii);
|
||||||
int ixgbe_check_vf_assignment(struct ixgbe_adapter *adapter);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user