函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:kmsg_dump_get_line_nolock - retrieve one kmsg log line (unlocked version)*@dumper: registered kmsg dumper*@syslog: include the "<4>" prefixes*@line: buffer to copy the line to*@size: maximum size of the buffer*@len: length of line placed into buffer*

函数原型:bool kmsg_dump_get_line_nolock(struct kmsg_dumper *dumper, bool syslog, char *line, size_t size, size_t *len)

返回类型:bool

参数:

类型参数名称
struct kmsg_dumper *dumper
boolsyslog
char *line
size_tsize
size_t *len
3167  l等于0
3168  bool ret = false
3170  如果非active则转到:out
3173  如果cur_seq小于dex and sequence number of the first record stored in the buffer
3175  cur_seq等于dex and sequence number of the first record stored in the buffer
3176  private state of the kmsg iterator 等于log_first_idx
3180  如果cur_seq大于等于dex and sequence number of the next record to store in the buffer 则转到:out
3183  msg等于get record by index; idx must point to valid msg
3184  l等于msg_print_text(msg, syslog, printk_time, line, size)
3186  private state of the kmsg iterator 等于get next record; idx must point to valid msg
3187  cur_seq自加
3188  ret = true
3189  out :
3190  如果lenlen等于l
3192  返回:ret
调用者
名称描述
kmsg_dump_get_linekmsg_dump_get_line - retrieve one kmsg log line*@dumper: registered kmsg dumper*@syslog: include the "<4>" prefixes*@line: buffer to copy the line to*@size: maximum size of the buffer*@len: length of line placed into buffer* Start at the beginning of the
kdb_dmesgkdb_dmesg - This function implements the 'dmesg' command to display* the contents of the syslog buffer.* dmesg [lines] [adjust]