Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\io-wq.c Create Date:2022-07-28 20:22:38
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Check head of free list for an available worker. If one isn't available,* caller must wake up the wq manager to create one.

Proto:static bool io_wqe_activate_free_worker(struct io_wqe *wqe)__must_hold(RCU)

Type:bool

Parameter:

TypeParameterName
struct io_wqe *wqe
258  n = fetch RCU-protected pointer for dereferencing(hlist_nulls_first_rcu( & free_list))
259  If ptr_is_a_nulls - Test if a ptr is a nulls*@ptr: ptr to be tested Then Return false
262  worker = hlist_nulls_entry(n, structio_worker, nulls_node)
263  If io_worker_get(worker) Then
264  wake_up_process - Wake up a specific process*@p: The process to be woken up.* Attempt to wake up the nominated process and move it to the set of runnable* processes.* Return: 1 if the process was woken up, 0 if it was already running.
265  io_worker_release(worker)
266  Return true
269  Return false
Caller
NameDescribe
io_wqe_wake_workerWe need a worker. If we find a free one, we're good. If not, and we're* below the max number of workers, wake up the manager to create one.