)]}'
{
  "commit": "e62da98527fa35fe5f532cded01a33edf9fbe7b2",
  "tree": "e7f32a15285972786c786d8f878cc352efbb7bc9",
  "parents": [
    "2957dc40a270cd41a3932f96f0f63ac9c1e3a9be"
  ],
  "author": {
    "name": "Stefan Hajnoczi",
    "email": "stefanha@redhat.com",
    "time": "Thu Mar 23 10:48:59 2023 -0400"
  },
  "committer": {
    "name": "Kevin Wolf",
    "email": "kwolf@redhat.com",
    "time": "Mon Mar 27 15:12:17 2023 +0200"
  },
  "message": "aio-posix: fix race between epoll upgrade and aio_set_fd_handler()\n\nIf another thread calls aio_set_fd_handler() while the IOThread event\nloop is upgrading from ppoll(2) to epoll(7) then we might miss new\nAioHandlers. The epollfd will not monitor the new AioHandler\u0027s fd,\nresulting in hangs.\n\nTake the AioHandler list lock while upgrading to epoll. This prevents\nAioHandlers from changing while epoll is being set up. If we cannot lock\nbecause we\u0027re in a nested event loop, then don\u0027t upgrade to epoll (it\nwill happen next time we\u0027re not in a nested call).\n\nThe downside to taking the lock is that the aio_set_fd_handler() thread\nhas to wait until the epoll upgrade is finished, which involves many\nepoll_ctl(2) system calls. However, this scenario is rare and I couldn\u0027t\nthink of another solution that is still simple.\n\nReported-by: Qing Wang \u003cqinwang@redhat.com\u003e\nBuglink: https://bugzilla.redhat.com/show_bug.cgi?id\u003d2090998\nCc: Paolo Bonzini \u003cpbonzini@redhat.com\u003e\nCc: Fam Zheng \u003cfam@euphon.net\u003e\nSigned-off-by: Stefan Hajnoczi \u003cstefanha@redhat.com\u003e\nMessage-Id: \u003c20230323144859.1338495-1-stefanha@redhat.com\u003e\nReviewed-by: Kevin Wolf \u003ckwolf@redhat.com\u003e\nSigned-off-by: Kevin Wolf \u003ckwolf@redhat.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "e11a8a022e9822e05c267901ca2a1f859803a9b4",
      "old_mode": 33188,
      "old_path": "util/fdmon-epoll.c",
      "new_id": "1683aa1105d3ab48941c970bcb4b12dcb82317c9",
      "new_mode": 33188,
      "new_path": "util/fdmon-epoll.c"
    }
  ]
}
