• Alexey Kodanev's avatar
    vxlan: fix wrong usage of VXLAN_VID_MASK · 40fb70f3
    Alexey Kodanev authored
    commit dfd8645e wrongly assumes that VXLAN_VDI_MASK includes
    eight lower order reserved bits of VNI field that are using for remote
    checksum offload.
    
    Right now, when VNI number greater then 0xffff, vxlan_udp_encap_recv()
    will always return with 'bad_flag' error, reducing the usable vni range
    from 0..16777215 to 0..65535. Also, it doesn't really check whether RCO
    bits processed or not.
    
    Fix it by adding new VNI mask which has all 32 bits of VNI field:
    24 bits for id and 8 bits for other usage.
    Signed-off-by: default avatarAlexey Kodanev <alexey.kodanev@oracle.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    40fb70f3
vxlan.c 77.8 KB