• Vlad Yasevich's avatar
    vlan: Keep NETIF_F_HW_CSUM similar to other software devices · 8403debe
    Vlad Yasevich authored
    Vlan devices, like all other software devices, enable
    NETIF_F_HW_CSUM feature.  However, unlike all the othe other
    software devices, vlans will switch to using IP|IPV6_CSUM
    features, if the underlying devices uses them.  In these situations,
    checksum offload features on the vlan device can't be controlled
    via ethtool.
    
    This patch makes vlans keep HW_CSUM feature if the underlying
    device supports checksum offloading.  This makes vlan devices
    behave like other software devices, and restores control to the
    user.
    
    A side-effect is that some offload settings (typically UFO)
    may be enabled on the vlan device while being disabled on the HW.
    However, the GSO code will correctly process the packets. This
    actually results in slightly better raw throughput.
    Signed-off-by: default avatarVladislav Yasevich <vyasevic@redhat.com>
    Acked-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    8403debe
vlan_dev.c 22.6 KB