###Summary
The struct worker is the really scheudle unit in workqueue.
Each struct worker has a corresponding thread(task) by worker->task.
A struct worker is linked to struct worker_pool->idle_list when work is idle.
and moved to struct worker_pool->busy_hash.
worker_thread
- move
workerfrompool->idle_listand clearworker‘sWORKER_IDLEflag. - check the
pooland manage the workers(create/destory)
and run them in sequence withIterate all the `struct work_struct *work` in the `struct worker_pool->worklist`,process_one_work(worker, work);.- move
workerinto idle list again. - schedule();
1 | 2270 /** |
process_one_work
1 | 2114 /** |