Function report |
Source Code:kernel\workqueue.c |
Create Date:2022-07-28 09:26:57 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name: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.
Proto:void flush_workqueue(struct workqueue_struct *wq)
Type:void
Parameter:
Type | Parameter | Name |
---|---|---|
struct workqueue_struct * | wq |
2772 | If WARN_ON(!can kworkers be created yet? ) Then Return |
2775 | lock_map_acquire( & lockdep_map) |
2776 | lock_map_release( & lockdep_map) |
2778 | mutex_lock( & protects this wq ) |
2785 | If next_color != WQ: current flush color Then |
2793 | WQ: current work color = next_color |
2795 | If Not WQ: first flusher Then |
2799 | WQ: first flusher = this_flusher |
2808 | Else |
2814 | Else |
2825 | mutex_unlock( & protects this wq ) |
2827 | wait_for_completion( & lush completion ) |
2835 | If WQ: first flusher != this_flusher Then Return |
2838 | mutex_lock( & protects this wq ) |
2841 | If WQ: first flusher != this_flusher Then Go to out_unlock |
2844 | WQ: first flusher = NULL |
2849 | When (true) cycle |
2854 | If WQ: flush color waiting for != WQ: current flush color Then Break |
2857 | complete( & lush completion ) |
2860 | WARN_ON_ONCE(!list_empty - tests whether a list is empty*@head: the list to test. && WQ: current flush color != work_next_color(WQ: current work color )) |
2867 | If Not list_empty - tests whether a list is empty*@head: the list to test. Then |
2886 | Break |
2897 | WQ: first flusher = next |
2906 | WQ: first flusher = NULL |
2909 | out_unlock : |
2910 | mutex_unlock( & protects this wq ) |
Name | Describe |
---|---|
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 |
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 |