Function report |
Source Code:kernel\kthread.c |
Create Date:2022-07-28 09:30:25 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:kthread_worker_fn - kthread function to process kthread_worker*@worker_ptr: pointer to initialized kthread_worker* This function implements the main cycle of kthread worker. It processes* work_list until it is stopped with kthread_stop()
Proto:int kthread_worker_fn(void *worker_ptr)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| void * | worker_ptr |
| 635 | worker = worker_ptr |
| 642 | WARN_ON(task && task != current process) |
| 643 | task = current process |
| 645 | If flags & KTW_FREEZABLE Then set_freezable() |
| 648 | repeat : |
| 653 | raw_spin_lock_irq( & lock) |
| 654 | task = NULL |
| 655 | raw_spin_unlock_irq( & lock) |
| 656 | Return 0 |
| 659 | work = NULL |
| 660 | raw_spin_lock_irq( & lock) |
| 666 | current_work = work |
| 667 | raw_spin_unlock_irq( & lock) |
| 669 | If work Then |
| 672 | Else if Not freezing(current process) Then schedule() |
| 675 | try_to_freeze() |
| 676 | cond_resched() |
| 677 | Go to repeat |
| Source code conversion tool public plug-in interface | X |
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |