stmmac_set_queue_tx_tail_ptr(priv, tx_q, queue, tx_q->cur_tx);
}
-static void stmmac_set_gso_types(struct stmmac_priv *priv, bool tso)
-{
- if (!tso) {
- priv->gso_enabled_types = 0;
- } else {
- /* Manage oversized TCP frames for GMAC4 device */
- priv->gso_enabled_types = SKB_GSO_TCPV4 | SKB_GSO_TCPV6;
- if (priv->plat->core_type == DWMAC_CORE_GMAC4)
- priv->gso_enabled_types |= SKB_GSO_UDP_L4;
- }
-}
-
static void stmmac_set_gso_features(struct net_device *ndev)
{
struct stmmac_priv *priv = netdev_priv(ndev);
if (priv->plat->core_type == DWMAC_CORE_GMAC4)
ndev->hw_features |= NETIF_F_GSO_UDP_L4;
- stmmac_set_gso_types(priv, true);
-
dev_info(priv->device, "TSO feature enabled\n");
}
if (priv->tx_path_in_lpi_mode && priv->eee_sw_timer_en)
stmmac_stop_sw_lpi(priv);
- if (skb_is_gso(skb) &&
- skb_shinfo(skb)->gso_type & priv->gso_enabled_types)
+ if (skb_is_gso(skb))
return stmmac_tso_xmit(skb, dev);
if (priv->est && priv->est->enable &&
stmmac_enable_sph(priv, priv->ioaddr, sph_en, chan);
}
- stmmac_set_gso_types(priv, features & NETIF_F_TSO);
-
if (features & NETIF_F_HW_VLAN_CTAG_RX)
priv->hw->hw_vlan_en = true;
else