On 4/7/20 4:28 AM, Oleg Nesterov wrote: > On 04/06, Jens Axboe wrote: >> >> +static inline bool task_work_pending(void) >> +{ >> + return current->task_works; >> +} >> + >> +static inline void task_work_run(void) >> +{ >> + if (task_work_pending()) >> + __task_work_run(); >> +} > > No, this is wrong. exit_task_work() must always call __task_work_run() > to install work_exited. > > This helper (and 3/4) probably makes sense but please change exit_task_work() > to use __task_work_run() then. Good catch, thanks. I'll make the change. -- Jens Axboe