• François Romieu's avatar
    [PATCH] r8169: endianness fixes · d35da12a
    François Romieu authored
    Endianness fixes
    
    - rtl8169_rx_csum() forgot to convert the descriptor to cpu order,
    - same thing for rtl8169_rx_vlan_skb() but this one is more tricky as
      the layout of the (u32) word in the 8169 descriptor calls for a
      second level of swap at the vlan tag level (u16). The old code only
      did the second part (in an endian-dependant way, how fun).
    - rtl8169_tx_vlan_tag(): this time the (u32 descriptor level) cpu_to_le32
      is issued in rtl8169_start_xmit but the (u16 vlan tag level) cpu_to_be16
      is not right any more.
    
    Summary: avoid even calls to cpu_to_{b/l}eXX on a given piece of data.
    
    The change has no effect on x86. Now sparc64 talks to x86.
    Pinpointed-by: default avatarJon Mason <jdmason@us.ibm.com>
    Signed-off-by: default avatarFrancois Romieu <romieu@fr.zoreil.com>
    Signed-off-by: default avatarJeff Garzik <jgarzik@pobox.com>
    d35da12a
r8169.c 60.8 KB