On 22/03/2021 13:45, Jens Axboe wrote: > On 3/21/21 7:58 PM, Pavel Begunkov wrote: >> io_run_task_work() does some extra work for safety, that isn't actually >> needed in many cases, particularly when it's known that current is not >> exiting and in the TASK_RUNNING state, like in the beginning of a >> syscall. > > Is this really worth it? Not alone, but ifs tend to pile up, and I may argue that PF_EXITING in the beginning of a syscall may be confusing. Are you afraid it will get out of sync with time? -- Pavel Begunkov