函数逻辑报告 | 
Source Code:kernel\workqueue.c | 
Create Date:2022-07-27 10:27:17 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| 首页 | 函数Tree | 
| 注解内核,赢得工具 | 下载SCCT | English | 
函数名称:lush_workqueue - ensure that any scheduled work has run to completion.*@wq: workqueue to flush* This function sleeps until all work items which were queued on entry* have finished execution, but it is not livelocked by new incoming ones.
函数原型:void flush_workqueue(struct workqueue_struct *wq)
返回类型:void
参数:
| 类型 | 参数 | 名称 | 
|---|---|---|
| struct workqueue_struct * | wq | 
| 2772 | 如果WARN_ON(!can kworkers be created yet? )则返回 | 
| 2775 | lock_map_acquire( & lockdep_map) | 
| 2776 | lock_map_release( & lockdep_map) | 
| 2778 | mutex_lock( & protects this wq ) | 
| 2785 | 如果next_color不等于WQ: current flush color 则 | 
| 2791 | WARN_ON_ONCE(!链表为空) | 
| 2793 | WQ: current work color 等于next_color | 
| 2795 | 如果非WQ: first flusher 则 | 
| 2799 | WQ: first flusher 等于this_flusher | 
| 2808 | 否则 | 
| 2811 | 添加链表项 | 
| 2814 | 否则 | 
| 2820 | 添加链表项 | 
| 2825 | mutex_unlock( & protects this wq ) | 
| 2827 | wait_for_completion( & lush completion ) | 
| 2835 | 如果WQ: first flusher 不等于this_flusher则返回 | 
| 2838 | mutex_lock( & protects this wq ) | 
| 2841 | 如果WQ: first flusher 不等于this_flusher则转到:out_unlock | 
| 2844 | WQ: first flusher = NULL | 
| 2846 | WARN_ON_ONCE(!链表为空) | 
| 2849 | 当(true)循环 | 
| 2854 | 如果WQ: flush color waiting for 不等于WQ: current flush color 则退出 | 
| 2856 | 删除链表项并重新初始化 | 
| 2857 | complete( & lush completion ) | 
| 2860 | WARN_ON_ONCE(!链表为空 && WQ: current flush color != work_next_color(WQ: current work color )) | 
| 2867 | 如果非链表为空则 | 
| 2879 | 加入二个链表项并重新初始化 | 
| 2884 | 如果链表为空则 | 
| 2886 | 退出 | 
| 2896 | 删除链表项并重新初始化 | 
| 2897 | WQ: first flusher 等于next | 
| 2906 | WQ: first flusher = NULL | 
| 2909 | out_unlock : | 
| 2910 | mutex_unlock( & protects this wq ) | 
| 名称 | 描述 | 
|---|---|
| drain_workqueue | drain_workqueue - drain a workqueue*@wq: workqueue to drain* Wait until the workqueue becomes empty. While draining is in progress,* only chain queueing is allowed. IOW, only currently pending or running | 
| __test_cycle | |
| stress | |
| cgroup1_pidlist_destroy_all | Used to destroy all pidlists lingering waiting for destroy timer. None* should be left afterwards. | 
| cpuset_post_attach | |
| cpuset_write_resmask | Common handling for a write to a "cpus" or "mems" file. | 
| flush_scheduled_work | lush_scheduled_work - ensure that any scheduled work has run to completion.* Forces execution of the kernel-global workqueue and blocks until its* completion.* Think twice before calling this function! It's very easy to get into | 
| blk_flush_integrity | 
| 源代码转换工具 开放的插件接口  | X | 
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码  |