Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Switch the patched state of the task to the set of functions in the target* patch state.* NOTE: If task is not 'current', the caller must ensure the task is inactive.* Otherwise klp_ftrace_handler() might read the wrong 'patch_state' value.

Proto:void klp_update_patch_state(struct task_struct *task)

Type:void

Parameter:

TypeParameterName
struct task_struct *task
169  preempt_disable_notrace()
183  If test_and_clear_tsk_thread_flag(task, pending live patching update ) Then patch_state = READ_ONCE(klp_target_state)
186  preempt_enable_notrace()
Caller
NameDescribe
klp_force_transitionDrop TIF_PATCH_PENDING of all tasks on admin's request. This forces an* existing transition to finish.* NOTE: klp_update_patch_state(task) requires the task to be inactive or* 'current'. This is not the case here and the consistency model could be* broken