lkml.org 
[lkml]   [2020]   [Mar]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/1] io_uring: fix lockup with timeouts
From
Date
On 3/6/20 3:15 PM, Pavel Begunkov wrote:
> There is a recipe to deadlock the kernel: submit a timeout sqe with a
> linked_timeout (e.g. test_single_link_timeout_ception() from liburing),
> and SIGKILL the process.
>
> Then, io_kill_timeouts() takes @ctx->completion_lock, but the timeout
> isn't flagged with REQ_F_COMP_LOCKED, and will try to double grab it
> during io_put_free() to cancel the linked timeout. Probably, the same
> can happen with another io_kill_timeout() call site, that is
> io_commit_cqring().

Thanks, looks good, applied.

--
Jens Axboe

\
 
 \ /
  Last update: 2020-03-07 16:37    [W:0.035 / U:0.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site