From: Marcelo Ricardo Leitner Date: Thu, 2 Jun 2016 18:05:38 +0000 (-0300) Subject: loopback: make use of NETIF_F_GSO_SOFTWARE X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f6c382fc553b49bc2dfaf705e34fde32171b5db4;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git loopback: make use of NETIF_F_GSO_SOFTWARE NETIF_F_GSO_SOFTWARE was defined to list all GSO software types, so lets make use of it in loopback code. Note that veth/vxlan/others already uses it. Within this patch series, this patch causes lo to pick up SCTP GSO feature automatically (as it's added to NETIF_F_GSO_SOFTWARE) and thus avoiding segmentation if possible. Signed-off-by: Marcelo Ricardo Leitner Tested-by: Xin Long Signed-off-by: David S. Miller --- diff --git a/drivers/net/loopback.c b/drivers/net/loopback.c index a400288cb37b..6255973e3dda 100644 --- a/drivers/net/loopback.c +++ b/drivers/net/loopback.c @@ -169,10 +169,9 @@ static void loopback_setup(struct net_device *dev) dev->flags = IFF_LOOPBACK; dev->priv_flags |= IFF_LIVE_ADDR_CHANGE | IFF_NO_QUEUE; netif_keep_dst(dev); - dev->hw_features = NETIF_F_ALL_TSO | NETIF_F_UFO; + dev->hw_features = NETIF_F_GSO_SOFTWARE; dev->features = NETIF_F_SG | NETIF_F_FRAGLIST - | NETIF_F_ALL_TSO - | NETIF_F_UFO + | NETIF_F_GSO_SOFTWARE | NETIF_F_HW_CSUM | NETIF_F_RXCSUM | NETIF_F_SCTP_CRC