1. 01 11月, 2016 2 次提交
    • X
      ipv6: add mtu lock check in __ip6_rt_update_pmtu · 19bda36c
      Xin Long 提交于
      Prior to this patch, ipv6 didn't do mtu lock check in ip6_update_pmtu.
      It leaded to that mtu lock doesn't really work when receiving the pkt
      of ICMPV6_PKT_TOOBIG.
      
      This patch is to add mtu lock check in __ip6_rt_update_pmtu just as ipv4
      did in __ip_rt_update_pmtu.
      Acked-by: NHannes Frederic Sowa <hannes@stressinduktion.org>
      Signed-off-by: NXin Long <lucien.xin@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      19bda36c
    • J
      ipv6: Don't use ufo handling on later transformed packets · f89c56ce
      Jakub Sitnicki 提交于
      Similar to commit c146066a ("ipv4: Don't use ufo handling on later
      transformed packets"), don't perform UFO on packets that will be IPsec
      transformed. To detect it we rely on the fact that headerlen in
      dst_entry is non-zero only for transformation bundles (xfrm_dst
      objects).
      
      Unwanted segmentation can be observed with a NETIF_F_UFO capable device,
      such as a dummy device:
      
        DEV=dum0 LEN=1493
      
        ip li add $DEV type dummy
        ip addr add fc00::1/64 dev $DEV nodad
        ip link set $DEV up
        ip xfrm policy add dir out src fc00::1 dst fc00::2 \
           tmpl src fc00::1 dst fc00::2 proto esp spi 1
        ip xfrm state add src fc00::1 dst fc00::2 \
           proto esp spi 1 enc 'aes' 0x0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b
      
        tcpdump -n -nn -i $DEV -t &
        socat /dev/zero,readbytes=$LEN udp6:[fc00::2]:$LEN
      
      tcpdump output before:
      
        IP6 fc00::1 > fc00::2: frag (0|1448) ESP(spi=0x00000001,seq=0x1), length 1448
        IP6 fc00::1 > fc00::2: frag (1448|48)
        IP6 fc00::1 > fc00::2: ESP(spi=0x00000001,seq=0x2), length 88
      
      ... and after:
      
        IP6 fc00::1 > fc00::2: frag (0|1448) ESP(spi=0x00000001,seq=0x1), length 1448
        IP6 fc00::1 > fc00::2: frag (1448|80)
      
      Fixes: e89e9cf5 ("[IPv4/IPv6]: UFO Scatter-gather approach")
      Signed-off-by: NJakub Sitnicki <jkbs@redhat.com>
      Acked-by: NHannes Frederic Sowa <hannes@stressinduktion.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f89c56ce
  2. 31 10月, 2016 1 次提交
    • M
      r8152: Fix broken RX checksums. · b9a321b4
      Mark Lord 提交于
      The r8152 driver has been broken since (approx) 3.16.xx
      when support was added for hardware RX checksums
      on newer chip versions.  Symptoms include random
      segfaults and silent data corruption over NFS.
      
      The hardware checksum logig does not work on the VER_02
      dongles I have here when used with a slow embedded system CPU.
      Google reveals others reporting similar issues on Raspberry Pi.
      
      So, disable hardware RX checksum support for VER_02, and fix
      an obvious coding error for IPV6 checksums in the same function.
      
      Because this bug results in silent data corruption,
      it is a good candidate for back-porting to -stable >= 3.16.xx.
      Signed-off-by: NMark Lord <mlord@pobox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b9a321b4
  3. 30 10月, 2016 37 次提交