函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\debug\kdb\kdb_main.c Create Date:2022-07-27 12:45:03
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:kdbgetaddrarg - This function is responsible for parsing an* address-expression and returning the value of the expression,* symbol name, and offset to the caller

函数原型:int kdbgetaddrarg(int argc, const char **argv, int *nextarg, unsigned long *value, long *offset, char **name)

返回类型:int

参数:

类型参数名称
intargc count of arguments in argv
const char **argv argument vector
int *nextarg
unsigned long *value
long *offset
char **name
499  off等于0
502  found等于0
504  symbol等于'\0'
513  如果非Check whether the flags of the current command and the permissions* of the kdb console has allow a command to be run.则返回:KDB_NOPERM
525  如果nextarg大于 count of arguments in argv则返回:KDB_ARGCOUNT
528  symname等于 argument vector[ * nextarg]
536  cp等于strpbrk - Find the first occurrence of a set of characters*@cs: The string to be searched*@ct: The characters to search for
537  如果(cp != NULL)则
538  symbol等于cp
539  cp自加等于'\0'
542  如果symname[0]恒等于'$'则
543  diag等于kdbgetulenv - This function will return the value of an unsigned* long-valued environment variable.* Parameters:* match A character string representing a numeric value* Outputs:* *value the unsigned long represntation of the env variable 'match'* Returns:
544  如果diag则返回:diag
546  否则如果symname[0]恒等于'%'则
547  diag等于kdb_check_regs()
548  如果diag则返回:diag
553  返回:KDB_NOTIMP
554  否则
555  found等于kdbgetsymval - Return the address of the given symbol
556  如果found
557  addr等于sym_start
558  否则
560  如果diag则返回:diag
565  如果非foundfound等于kdbnearsym - Return the name of the symbol with the nearest address* less than 'addr'
568  nextarg自加
570  如果namename等于symname
572  如果valuevalue等于addr
574  如果offsetnamenameoffset等于addrsym_start
577  如果nextarg大于 count of arguments in argvsymbol恒等于'\0'则返回:0
585  如果symbol恒等于'\0'则
586  如果 argument vector[ * nextarg][0]不等于'+'且 argument vector[ * nextarg][0]不等于'-'则
591  返回:0
592  否则
593  positive等于 argument vector[ * nextarg][0]恒等于'+'
594  nextarg自加
596  否则positive等于symbol恒等于'+'
602  如果nextarg大于 count of arguments in argvsymbol恒等于'\0'则
604  返回:KDB_INVADDRFMT
607  如果非symbol
608  cp等于 argument vector[ * nextarg]
609  nextarg自加
612  diag等于kdbgetularg - This function will convert a numeric string into an* unsigned long value.* Parameters:* arg A character string representing a numeric value* Outputs:* *value the unsigned long represntation of arg.* Returns:
613  如果diag则返回:diag
616  如果非positiveoff等于负off
619  如果offsetoffset加等于off
622  如果valuevalue加等于off
625  返回:0
调用者
名称描述
kdb_parse
kdb_md
kdb_mmkdb_mm - This function implements the 'mm' command.* mm address-expression new-value* Remarks:* mm works on machine words, mmW works on bytes.
kdb_gokdb_go - This function implements the 'go' command.* go [address-expression]
kdb_efkdb_ef - This function implements the 'regs' (display exception* frame) command. This command takes an address and expects to* find an exception frame at that address, formats and prints* it.* regs address-expression* Remarks:* Not done yet.
kdb_per_cpukdb_per_cpu - This function implements the 'per_cpu' command.
kdb_bt
kdb_bpkdb_bp* Handle the bp commands