函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:That function parses "suffix" crashkernel command lines like* crashkernel=size,[high|low]* It returns 0 on success and -EINVAL on failure.

函数原型:static int __init parse_crashkernel_suffix(char *cmdline, unsigned long long *crash_size, const char *suffix)

返回类型:int

参数:

类型参数名称
char *cmdline
unsigned long long *crash_size
const char *suffix
164  cur等于cmdline
166  crash_size等于memparse - parse a string with mem suffixes into a number*@ptr: Where parse begins*@retptr: (output) Optional pointer to next char after parse completes* Parses a string into a number. The number stored at @ptr is
167  如果cmdline恒等于cur
168  打印警告信息("crashkernel: memory value expected\n")
169  返回:负EINVAL
173  如果字符串指定长度比较
174  打印警告信息("crashkernel: unrecognized char: %c\n", * cur)
175  返回:负EINVAL
177  cur加等于strlen - Find the length of a string*@s: The string to be sized
178  如果cur不等于' '且cur不等于'\0'则
179  打印警告信息("crashkernel: unrecognized char: %c\n", * cur)
180  返回:负EINVAL
183  返回:0
调用者
名称描述
__parse_crashkernel