summaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
authorCamelia Groza <camelia.groza@nxp.com>2017-11-08 13:58:09 (GMT)
committerXie Xiaobo <xiaobo.xie@nxp.com>2017-12-12 07:32:32 (GMT)
commit41d433d801c436ec51fcdc8ab20ceb64b6559454 (patch)
tree9747fe01efd68b8804fa4597b25755d51f01fab9 /drivers/net
parentc533b864abd878475a65f27931a67888b3f439e3 (diff)
downloadlinux-41d433d801c436ec51fcdc8ab20ceb64b6559454.tar.xz
sdk_dpaa: ls1043a errata: stop advertising S/G and GSO support
The errata prevents us from transmitting S/G frames. Instead of linearizing them ourselves, stop advertising S/G support and have the stack do it for us. Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ethernet/freescale/sdk_dpaa/dpaa_eth.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/ethernet/freescale/sdk_dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/sdk_dpaa/dpaa_eth.c
index b2eec95..1f76aa3 100644
--- a/drivers/net/ethernet/freescale/sdk_dpaa/dpaa_eth.c
+++ b/drivers/net/ethernet/freescale/sdk_dpaa/dpaa_eth.c
@@ -775,6 +775,17 @@ static int dpa_private_netdev_init(struct net_device *net_dev)
/* Advertise NETIF_F_HW_ACCEL_MQ to avoid Tx timeout warnings */
net_dev->features |= NETIF_F_HW_ACCEL_MQ;
+#ifndef CONFIG_PPC
+ /* Due to the A010022 FMan errata, we can not use contig frames larger
+ * than 4K, nor S/G frames. We need to stop advertising S/G and GSO
+ * support.
+ */
+ if (unlikely(dpaa_errata_a010022)) {
+ net_dev->hw_features &= ~NETIF_F_SG;
+ net_dev->features &= ~NETIF_F_GSO;
+ }
+#endif
+
return dpa_netdev_init(net_dev, mac_addr, tx_timeout);
}