Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ae923785 authored by David S. Miller's avatar David S. Miller
Browse files


Jeff Kirsher says:

====================
Intel Wired LAN Driver Updates 2018-08-24

This series contains fixes to e1000, igb, ixgb, ixgbe and i40e.

YueHaibing from Huawei provides a change to use dma_zalloc_coherent()
instead of calls to allocator followed by a memset for ixgb.

Bo Chen provides a couple of fixes for e1000, first by adding a check to
prevent a NULL pointer dereference.  The second change is to clean up a
possible resource leak on old transmit and receive rings when the device
is not up.

Jesus fixes an issue in the usage of an advanced transmit context
descriptor for retrieving the timestamp of a packet for AF_PACKET if the
IGB_TX_FLAGS_VLAN is not set in igb.

Jia-Ju Bai provides several patches which replace GFP_ATOMIC with
GFP_KERNEL, when using kzalloc() and kcalloc() which is not necessary.
Also found an instance of mdelay() call which could be replaced with
msleep().

Tony fixes ixgbe to allow MTU changes with XDP, by adding checks to
ensure only supported values and return -EINVAL for when it is not
supported.

Sebastian fixed an issue that was not clearing VF mailbox memory and
ensure queues are re-enabled correctly.

Martyna fixes a transmit timeout when DCB is configured when bringing up
an interface.

Jake fixes a previous commit which accidentally reversed the check of
the data pointer, so we can accurately count the size of the stats.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents ff0fadff 07f37013
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -624,14 +624,14 @@ static int e1000_set_ringparam(struct net_device *netdev,
		adapter->tx_ring = tx_old;
		e1000_free_all_rx_resources(adapter);
		e1000_free_all_tx_resources(adapter);
		kfree(tx_old);
		kfree(rx_old);
		adapter->rx_ring = rxdr;
		adapter->tx_ring = txdr;
		err = e1000_up(adapter);
		if (err)
			goto err_setup;
	}
	kfree(tx_old);
	kfree(rx_old);

	clear_bit(__E1000_RESETTING, &adapter->flags);
	return 0;
@@ -644,6 +644,7 @@ static int e1000_set_ringparam(struct net_device *netdev,
err_alloc_rx:
	kfree(txdr);
err_alloc_tx:
	if (netif_running(adapter->netdev))
		e1000_up(adapter);
err_setup:
	clear_bit(__E1000_RESETTING, &adapter->flags);
+1 −1
Original line number Diff line number Diff line
@@ -2013,7 +2013,7 @@ static void i40e_get_stat_strings(struct net_device *netdev, u8 *data)
	for (i = 0; i < I40E_MAX_USER_PRIORITY; i++)
		i40e_add_stat_strings(&data, i40e_gstrings_pfc_stats, i);

	WARN_ONCE(p - data != i40e_get_stats_count(netdev) * ETH_GSTRING_LEN,
	WARN_ONCE(data - p != i40e_get_stats_count(netdev) * ETH_GSTRING_LEN,
		  "stat strings count mismatch!");
}

+8 −7
Original line number Diff line number Diff line
@@ -5122,15 +5122,17 @@ static int i40e_vsi_configure_bw_alloc(struct i40e_vsi *vsi, u8 enabled_tc,
				       u8 *bw_share)
{
	struct i40e_aqc_configure_vsi_tc_bw_data bw_data;
	struct i40e_pf *pf = vsi->back;
	i40e_status ret;
	int i;

	if (vsi->back->flags & I40E_FLAG_TC_MQPRIO)
	/* There is no need to reset BW when mqprio mode is on.  */
	if (pf->flags & I40E_FLAG_TC_MQPRIO)
		return 0;
	if (!vsi->mqprio_qopt.qopt.hw) {
	if (!vsi->mqprio_qopt.qopt.hw && !(pf->flags & I40E_FLAG_DCB_ENABLED)) {
		ret = i40e_set_bw_limit(vsi, vsi->seid, 0);
		if (ret)
			dev_info(&vsi->back->pdev->dev,
			dev_info(&pf->pdev->dev,
				 "Failed to reset tx rate for vsi->seid %u\n",
				 vsi->seid);
		return ret;
@@ -5139,12 +5141,11 @@ static int i40e_vsi_configure_bw_alloc(struct i40e_vsi *vsi, u8 enabled_tc,
	for (i = 0; i < I40E_MAX_TRAFFIC_CLASS; i++)
		bw_data.tc_bw_credits[i] = bw_share[i];

	ret = i40e_aq_config_vsi_tc_bw(&vsi->back->hw, vsi->seid, &bw_data,
				       NULL);
	ret = i40e_aq_config_vsi_tc_bw(&pf->hw, vsi->seid, &bw_data, NULL);
	if (ret) {
		dev_info(&vsi->back->pdev->dev,
		dev_info(&pf->pdev->dev,
			 "AQ command Config VSI BW allocation per TC failed = %d\n",
			 vsi->back->hw.aq.asq_last_status);
			 pf->hw.aq.asq_last_status);
		return -EINVAL;
	}

+1 −1
Original line number Diff line number Diff line
@@ -1649,7 +1649,7 @@ static int igb_integrated_phy_loopback(struct igb_adapter *adapter)
	if (hw->phy.type == e1000_phy_m88)
		igb_phy_disable_receiver(adapter);

	mdelay(500);
	msleep(500);
	return 0;
}

+4 −3
Original line number Diff line number Diff line
@@ -3873,7 +3873,7 @@ static int igb_sw_init(struct igb_adapter *adapter)

	adapter->mac_table = kcalloc(hw->mac.rar_entry_count,
				     sizeof(struct igb_mac_addr),
				     GFP_ATOMIC);
				     GFP_KERNEL);
	if (!adapter->mac_table)
		return -ENOMEM;

@@ -3883,7 +3883,7 @@ static int igb_sw_init(struct igb_adapter *adapter)

	/* Setup and initialize a copy of the hw vlan table array */
	adapter->shadow_vfta = kcalloc(E1000_VLAN_FILTER_TBL_SIZE, sizeof(u32),
				       GFP_ATOMIC);
				       GFP_KERNEL);
	if (!adapter->shadow_vfta)
		return -ENOMEM;

@@ -5816,7 +5816,8 @@ static void igb_tx_csum(struct igb_ring *tx_ring, struct igb_tx_buffer *first)

	if (skb->ip_summed != CHECKSUM_PARTIAL) {
csum_failed:
		if (!(first->tx_flags & IGB_TX_FLAGS_VLAN))
		if (!(first->tx_flags & IGB_TX_FLAGS_VLAN) &&
		    !tx_ring->launchtime_enable)
			return;
		goto no_csum;
	}
Loading