Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:putreg

Proto:static int putreg(struct task_struct *child, unsigned long offset, unsigned long value)

Type:int

Parameter:

TypeParameterName
struct task_struct *child
unsigned longoffset
unsigned longvalue
368  Case offset == offsetof(structuser_regs_struct, cs)
369  Case offset == offsetof(structuser_regs_struct, These functions are used to reference data in other segments. )
370  Case offset == offsetof(structuser_regs_struct, es)
371  Case offset == offsetof(structuser_regs_struct, fs)
372  Case offset == offsetof(structuser_regs_struct, gs)
373  Case offset == offsetof(structuser_regs_struct, ss)
374  Return set_segment_reg(child, offset, value)
376  Case offset == offsetof(structuser_regs_struct, flags)
377  Return set_flags(child, value)
380  Case offset == offsetof(structuser_regs_struct, fs_base)
381  If value >= TASK_SIZE_MAX Then Return -EIO
391  If fsbase != value Then Return do_arch_prctl_64(child, ARCH_SET_FS, value)
393  Return 0
394  Case offset == offsetof(structuser_regs_struct, gs_base)
398  If value >= TASK_SIZE_MAX Then Return -EIO
400  If gsbase != value Then Return do_arch_prctl_64(child, ARCH_SET_GS, value)
402  Return 0
406  pt_regs_access(task_pt_regs(child), offset) = value
407  Return 0
Caller
NameDescribe
genregs_set
arch_ptrace