Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\task_work.c Create Date:2022-07-28 09:28:54
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:ask_work_cancel - cancel a pending work added by task_work_add()*@task: the task which should execute the work*@func: identifies the work to remove* Find the last queued pending work with ->func == @func and remove* it from queue.* RETURNS:

Proto:struct callback_head *task_work_cancel(struct task_struct *task, task_work_func_t func)

Type:struct callback_head

Parameter:

TypeParameterName
struct task_struct *task
task_work_func_tfunc
58  pprev = task_works
62  If Value is more likely to compile time(!task_works) Then Return NULL
70  raw_spin_lock_irqsave( & Protection of the PI data structures: , flags)
71  When work = READ_ONCE( * pprev) cycle
72  If func != func Then pprev = next
74  Else if cmpxchg(pprev, work, next) == work Then Break
77  raw_spin_unlock_irqrestore( & Protection of the PI data structures: , flags)
79  Return work
Caller
NameDescribe
irq_threadInterrupt handler thread