1. 18 Oct, 2018 37 commits
  2. 16 Oct, 2018 3 commits
    • Daniel Borkmann's avatar
      tcp, ulp: remove socket lock assertion on ULP cleanup · aadd4355
      Daniel Borkmann authored
      Eric reported that syzkaller triggered a splat in tcp_cleanup_ulp()
      where assertion sock_owned_by_me() failed. This happened through
      inet_csk_prepare_forced_close() first releasing the socket lock,
      then calling into tcp_done(newsk) which is called after the
      inet_csk_prepare_forced_close() and therefore without the socket
      lock held. The sock_owned_by_me() assertion can generally be
      removed as the only place where tcp_cleanup_ulp() is called from
      now is out of inet_csk_destroy_sock() -> sk->sk_prot->destroy()
      where socket is in dead state and unreachable. Therefore, add a
      comment why the check is not needed instead.
      
      Fixes: 8b9088f8 ("tcp, ulp: enforce sock_owned_by_me upon ulp init and cleanup")
      Reported-by: default avatarEric Dumazet <edumazet@google.com>
      Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      aadd4355
    • David S. Miller's avatar
      Merge branch 'hns3-Some-cleanup-and-bugfix-for-desc-filling' · 29ce85f3
      David S. Miller authored
      Yunsheng Lin says:
      
      ====================
      Some cleanup and bugfix for desc filling
      
      When retransmiting packets, skb_cow_head which is called in
      hns3_set_tso may clone a new header. And driver will clear the
      checksum of the header after doing DMA map, so HW will read the
      old header whose L3 checksum is not cleared and calculate a
      wrong L3 checksum.
      
      Also When sending a big fragment using multiple buffer descriptor,
      hns3 does one maping, but do multiple unmapping when tx is done,
      which may cause unmapping problem.
      
      This patchset does some cleanup before fixing the above problem.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      29ce85f3
    • Fuyun Liang's avatar
      net: hns3: fix for multiple unmapping DMA problem · bcdb12b7
      Fuyun Liang authored
      When sending a big fragment using multiple buffer descriptor,
      hns3 does one maping, but do multiple unmapping when tx is done,
      which may cause unmapping problem.
      
      To fix it, this patch makes sure the value of desc_cb.length of
      the non-first bd is zero. If desc_cb.length is zero, we do not
      unmap the buffer.
      
      Fixes: 76ad4f0e ("net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC")
      Signed-off-by: default avatarFuyun Liang <liangfuyun1@huawei.com>
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarYunsheng Lin <linyunsheng@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bcdb12b7