Skip to content
  1. Feb 19, 2016
    • Eric Dumazet's avatar
      tcp/dccp: fix another race at listener dismantle · 7716682c
      Eric Dumazet authored
      
      
      Ilya reported following lockdep splat:
      
      kernel: =========================
      kernel: [ BUG: held lock freed! ]
      kernel: 4.5.0-rc1-ceph-00026-g5e0a311 #1 Not tainted
      kernel: -------------------------
      kernel: swapper/5/0 is freeing memory
      ffff880035c9d200-ffff880035c9dbff, with a lock still held there!
      kernel: (&(&queue->rskq_lock)->rlock){+.-...}, at:
      [<ffffffff816f6a88>] inet_csk_reqsk_queue_add+0x28/0xa0
      kernel: 4 locks held by swapper/5/0:
      kernel: #0:  (rcu_read_lock){......}, at: [<ffffffff8169ef6b>]
      netif_receive_skb_internal+0x4b/0x1f0
      kernel: #1:  (rcu_read_lock){......}, at: [<ffffffff816e977f>]
      ip_local_deliver_finish+0x3f/0x380
      kernel: #2:  (slock-AF_INET){+.-...}, at: [<ffffffff81685ffb>]
      sk_clone_lock+0x19b/0x440
      kernel: #3:  (&(&queue->rskq_lock)->rlock){+.-...}, at:
      [<ffffffff816f6a88>] inet_csk_reqsk_queue_add+0x28/0xa0
      
      To properly fix this issue, inet_csk_reqsk_queue_add() needs
      to return to its callers if the child as been queued
      into accept queue.
      
      We also need to make sure listener is still there before
      calling sk->sk_data_ready(), by holding a reference on it,
      since the reference carried by the child can disappear as
      soon as the child is put on accept queue.
      
      Reported-by: default avatarIlya Dryomov <idryomov@gmail.com>
      Fixes: ebb516af
      
       ("tcp/dccp: fix race at listener dismantle phase")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7716682c
    • Xin Long's avatar
      route: check and remove route cache when we get route · deed49df
      Xin Long authored
      
      
      Since the gc of ipv4 route was removed, the route cached would has
      no chance to be removed, and even it has been timeout, it still could
      be used, cause no code to check it's expires.
      
      Fix this issue by checking  and removing route cache when we get route.
      
      Signed-off-by: default avatarXin Long <lucien.xin@gmail.com>
      Acked-by: default avatarHannes Frederic Sowa <hannes@stressinduktion.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      deed49df
    • Jamal Hadi Salim's avatar
      net_sched fix: reclassification needs to consider ether protocol changes · 619fe326
      Jamal Hadi Salim authored
      actions could change the etherproto in particular with ethernet
      tunnelled data. Typically such actions, after peeling the outer header,
      will ask for the packet to be  reclassified. We then need to restart
      the classification with the new proto header.
      
      Example setup used to catch this:
      sudo tc qdisc add dev $ETH ingress
      sudo $TC filter add dev $ETH parent ffff: pref 1 protocol 802.1Q \
      u32 match u32 0 0 flowid 1:1 \
      action  vlan pop reclassify
      
      Fixes: 3b3ae880
      
       ("net: sched: consolidate tc_classify{,_compat}")
      Signed-off-by: default avatarJamal Hadi Salim <jhs@mojatatu.com>
      Acked-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      619fe326
  2. Feb 18, 2016
  3. Feb 17, 2016