Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Freeze or unfreeze the task by setting or clearing the JOBCTL_TRAP_FREEZE* jobctl bit.

Proto:static void cgroup_freeze_task(struct task_struct *task, bool freeze)

Type:void

Parameter:

TypeParameterName
struct task_struct *task
boolfreeze
160  If Not lock_task_sighand(task, & flags) Then Return
163  If freeze Then
164  siglock protected |= JOBCTL_TRAP_FREEZE
165  signal_wake_up(task, false)
166  Else
167  siglock protected &= ~JOBCTL_TRAP_FREEZE
168  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.
171  unlock_task_sighand(task, & flags)
Caller
NameDescribe
cgroup_do_freezeFreeze or unfreeze all tasks in the given cgroup.
cgroup_freezer_migrate_taskAdjust the task state (freeze or unfreeze) and revisit the state of* source and destination cgroups.