函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\sched\core.c Create Date:2022-07-27 10:36:15
Last Modify:2022-05-22 13:40:38 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Mark the task runnable and perform wakeup-preemption.

函数原型:static void ttwu_do_wakeup(struct rq *rq, struct task_struct *p, int wake_flags, struct rq_flags *rf)

返回类型:void

参数:

类型参数名称
struct rq *rq
struct task_struct *p
intwake_flags
struct rq_flags *rf
2221  check_preempt_curr(rq, p, wake_flags)
2222  任务状态等于就绪态
2223  Tracepoint called when the task is actually woken; p->state == TASK_RUNNNG.* It it not always called from the waking context.
调用者
名称描述
ttwu_do_activate
ttwu_remoteCalled in case the task @p isn't fully descheduled from its runqueue,* in this case we must do a remote wakeup. Its a 'light' wakeup though,* since all we need to do is flip p->state to TASK_RUNNING, since* the task is still ->on_rq.