函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\lib\insn-eval.c Create Date:2022-07-27 08:24:36
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:get_reg_offset_16() - Obtain offset of register indicated by instruction*@insn: Instruction containing ModRM byte*@regs: Register values as seen when entering kernel mode*@offs1: Offset of the first operand register*@offs2: Offset of the second opeand

函数原型:static int get_reg_offset_16(struct insn *insn, struct pt_regs *regs, int *offs1, int *offs2)

返回类型:int

参数:

类型参数名称
struct insn *insn
struct pt_regs *regs
int *offs1
int *offs2
510  static const int regoff1[] = {offsetof(structpt_regs, bx), offsetof(structpt_regs, bx), offsetof(structpt_regs, bp), offsetof(structpt_regs, bp), offsetof(structpt_regs, si), offsetof(structpt_regs, di), offsetof(structpt_regs, bp), offsetof(structpt_regs, bx), }
521  static const int regoff2[] = {offsetof(structpt_regs, si), offsetof(structpt_regs, di), offsetof(structpt_regs, si), offsetof(structpt_regs, di), - EDOM, - EDOM, - EDOM, - EDOM, }
532  如果非offs1或非offs2则返回:负EINVAL
536  如果X86_MODRM_MOD(value)恒等于3则
537  offs1等于sn_get_modrm_rm_off() - Obtain register in r/m part of the ModRM byte*@insn: Instruction containing the ModRM byte*@regs: Register values as seen when entering kernel mode* Returns:* The register indicated by the r/m part of the ModRM byte. The
538  offs2等于负EDOM
539  返回:0
542  offs1等于regoff1[X86_MODRM_RM(value)]
543  offs2等于regoff2[X86_MODRM_RM(value)]
552  如果X86_MODRM_MOD(value)恒等于0且X86_MODRM_RM(value)恒等于6则offs1等于负EDOM
556  返回:0
调用者
名称描述
get_eff_addr_modrm_16get_eff_addr_modrm_16() - Obtain referenced effective address via ModRM*@insn: Instruction