On 2/18/20 6:13 AM, Peter Zijlstra wrote: > Jens, I think you want something like this on top of what you have, > mostly it is adding sched_work_run() to exit_task_work(). It also makes it a bit cleaner, I don't like the implied task == current we have in a bunch of spots. Folded this in (thanks!) with minor edit: > @@ -157,10 +157,10 @@ static void __task_work_run(struct task_struct *task, > */ > void task_work_run(void) > { > - __task_work_run(current, ¤t->task_works); > + __task_work_run(¤t->task_works); > } > > -void sched_work_run(struct task_struct *task) > +void sched_work_run() > { > - __task_work_run(task, &task->sched_work); > + __task_work_run(&task->sched_work); > } s/task/current for this last one. -- Jens Axboe