• P
    io_uring: do grab_env() just before punting · cbdcb435
    Pavel Begunkov 提交于
    Currently io_steal_work() is disabled, and every linked request should
    go through task_work for initialisation. Do io_req_work_grab_env()
    just before io-wq punting and for the whole link, so any request
    reachable by io_steal_work() is prepared.
    
    This is also interesting for another reason -- it localises
    io_req_work_grab_env() into one place just before io-wq punting, helping
    to to better manage req->work lifetime and add some neat
    cleanup/optimisations later.
    Signed-off-by: NPavel Begunkov <asml.silence@gmail.com>
    Signed-off-by: NJens Axboe <axboe@kernel.dk>
    cbdcb435
io_uring.c 201.9 KB