)]}'
{
  "commit": "ed2e923945892a8372ab70d2f61d364b0b6d9054",
  "tree": "6df57f5b44b0003ac00ff559b781b691f91c4d13",
  "parents": [
    "4c5d283acc997a1bd7bc37cddcf7d284521cffff"
  ],
  "author": {
    "name": "Eric Dumazet",
    "email": "edumazet@google.com",
    "time": "Sat Sep 19 09:08:34 2015 -0700"
  },
  "committer": {
    "name": "David S. Miller",
    "email": "davem@davemloft.net",
    "time": "Mon Sep 21 16:32:29 2015 -0700"
  },
  "message": "tcp/dccp: fix timewait races in timer handling\n\nWhen creating a timewait socket, we need to arm the timer before\nallowing other cpus to find it. The signal allowing cpus to find\nthe socket is setting tw_refcnt to non zero value.\n\nAs we set tw_refcnt in __inet_twsk_hashdance(), we therefore need to\ncall inet_twsk_schedule() first.\n\nThis also means we need to remove tw_refcnt changes from\ninet_twsk_schedule() and let the caller handle it.\n\nNote that because we use mod_timer_pinned(), we have the guarantee\nthe timer wont expire before we set tw_refcnt as we run in BH context.\n\nTo make things more readable I introduced inet_twsk_reschedule() helper.\n\nWhen rearming the timer, we can use mod_timer_pending() to make sure\nwe do not rearm a canceled timer.\n\nNote: This bug can possibly trigger if packets of a flow can hit\nmultiple cpus. This does not normally happen, unless flow steering\nis broken somehow. This explains this bug was spotted ~5 months after\nits introduction.\n\nA similar fix is needed for SYN_RECV sockets in reqsk_queue_hash_req(),\nbut will be provided in a separate patch for proper tracking.\n\nFixes: 789f558cfb36 (\"tcp/dccp: get rid of central timewait timer\")\nSigned-off-by: Eric Dumazet \u003cedumazet@google.com\u003e\nReported-by: Ying Cai \u003cycai@google.com\u003e\nSigned-off-by: David S. Miller \u003cdavem@davemloft.net\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "879d6e5a973b4ae1af54d6b0c6103c02ee774991",
      "old_mode": 33188,
      "old_path": "include/net/inet_timewait_sock.h",
      "new_id": "186f3a1e1b1f6ddd898d0f5871cb46222ae6b80d",
      "new_mode": 33188,
      "new_path": "include/net/inet_timewait_sock.h"
    },
    {
      "type": "modify",
      "old_id": "30addee2dd037f9686c5585243e503632dcdd21a",
      "old_mode": 33188,
      "old_path": "net/dccp/minisocks.c",
      "new_id": "838f524cf11a177b473ca83e3d7f597ee2904d21",
      "new_mode": 33188,
      "new_path": "net/dccp/minisocks.c"
    },
    {
      "type": "modify",
      "old_id": "ae22cc24fbe89b32be1f2142450c198e78026851",
      "old_mode": 33188,
      "old_path": "net/ipv4/inet_timewait_sock.c",
      "new_id": "c67f9bd7699c5a1d210f214fd54aeea6944ccecb",
      "new_mode": 33188,
      "new_path": "net/ipv4/inet_timewait_sock.c"
    },
    {
      "type": "modify",
      "old_id": "6d8795b066aca708df47de3c9211f36bee5eb1d4",
      "old_mode": 33188,
      "old_path": "net/ipv4/tcp_minisocks.c",
      "new_id": "def765911ff85dfefd2c73c41b6585b33c77bcea",
      "new_mode": 33188,
      "new_path": "net/ipv4/tcp_minisocks.c"
    }
  ]
}
