diff options
Diffstat (limited to 'drivers/net/igb')
-rw-r--r-- | drivers/net/igb/igb_main.c | 33 |
1 files changed, 23 insertions, 10 deletions
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c index ea0560484dc7..24a119ec005d 100644 --- a/drivers/net/igb/igb_main.c +++ b/drivers/net/igb/igb_main.c | |||
@@ -1165,6 +1165,13 @@ int igb_up(struct igb_adapter *adapter) | |||
1165 | rd32(E1000_ICR); | 1165 | rd32(E1000_ICR); |
1166 | igb_irq_enable(adapter); | 1166 | igb_irq_enable(adapter); |
1167 | 1167 | ||
1168 | /* notify VFs that reset has been completed */ | ||
1169 | if (adapter->vfs_allocated_count) { | ||
1170 | u32 reg_data = rd32(E1000_CTRL_EXT); | ||
1171 | reg_data |= E1000_CTRL_EXT_PFRSTD; | ||
1172 | wr32(E1000_CTRL_EXT, reg_data); | ||
1173 | } | ||
1174 | |||
1168 | netif_tx_start_all_queues(adapter->netdev); | 1175 | netif_tx_start_all_queues(adapter->netdev); |
1169 | 1176 | ||
1170 | /* Fire a link change interrupt to start the watchdog. */ | 1177 | /* Fire a link change interrupt to start the watchdog. */ |
@@ -1948,6 +1955,13 @@ static int igb_open(struct net_device *netdev) | |||
1948 | 1955 | ||
1949 | igb_irq_enable(adapter); | 1956 | igb_irq_enable(adapter); |
1950 | 1957 | ||
1958 | /* notify VFs that reset has been completed */ | ||
1959 | if (adapter->vfs_allocated_count) { | ||
1960 | u32 reg_data = rd32(E1000_CTRL_EXT); | ||
1961 | reg_data |= E1000_CTRL_EXT_PFRSTD; | ||
1962 | wr32(E1000_CTRL_EXT, reg_data); | ||
1963 | } | ||
1964 | |||
1951 | netif_tx_start_all_queues(netdev); | 1965 | netif_tx_start_all_queues(netdev); |
1952 | 1966 | ||
1953 | /* Fire a link status change interrupt to start the watchdog. */ | 1967 | /* Fire a link status change interrupt to start the watchdog. */ |
@@ -5785,19 +5799,18 @@ static int igb_set_vf_mac(struct igb_adapter *adapter, | |||
5785 | static void igb_vmm_control(struct igb_adapter *adapter) | 5799 | static void igb_vmm_control(struct igb_adapter *adapter) |
5786 | { | 5800 | { |
5787 | struct e1000_hw *hw = &adapter->hw; | 5801 | struct e1000_hw *hw = &adapter->hw; |
5788 | u32 reg_data; | ||
5789 | 5802 | ||
5790 | if (!adapter->vfs_allocated_count) | 5803 | /* replication is not supported for 82575 */ |
5804 | if (hw->mac.type == e1000_82575) | ||
5791 | return; | 5805 | return; |
5792 | 5806 | ||
5793 | /* VF's need PF reset indication before they | 5807 | if (adapter->vfs_allocated_count) { |
5794 | * can send/receive mail */ | 5808 | igb_vmdq_set_loopback_pf(hw, true); |
5795 | reg_data = rd32(E1000_CTRL_EXT); | 5809 | igb_vmdq_set_replication_pf(hw, true); |
5796 | reg_data |= E1000_CTRL_EXT_PFRSTD; | 5810 | } else { |
5797 | wr32(E1000_CTRL_EXT, reg_data); | 5811 | igb_vmdq_set_loopback_pf(hw, false); |
5798 | 5812 | igb_vmdq_set_replication_pf(hw, false); | |
5799 | igb_vmdq_set_loopback_pf(hw, true); | 5813 | } |
5800 | igb_vmdq_set_replication_pf(hw, true); | ||
5801 | } | 5814 | } |
5802 | 5815 | ||
5803 | /* igb_main.c */ | 5816 | /* igb_main.c */ |