函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:msg_print_ext_body

函数原型:static ssize_t msg_print_ext_body(char *buf, size_t size, char *dict, size_t dict_len, char *text, size_t text_len)

返回类型:ssize_t

参数:

类型参数名称
char *buf
size_tsize
char *dict
size_tdict_len
char *text
size_ttext_len
739  p等于buf, e等于bufsize
743 i小于text_len循环
744  c等于text[i]
746  如果c小于' '或c大于等于127或c恒等于'\\'则p加等于格式化输出字符串
748  否则append_char( & p, e, c)
751  append_char( & p, e, '\n')
753  如果dict_len
754  bool line = true
756 i小于dict_len循环
757  c等于dict[i]
759  如果line
760  append_char( & p, e, ' ')
761  line = false
764  如果c恒等于'\0'则
765  append_char( & p, e, '\n')
766  line = true
767  继续下一循环
770  如果c小于' '或c大于等于127或c恒等于'\\'则
771  p加等于格式化输出字符串
772  继续下一循环
775  append_char( & p, e, c)
777  append_char( & p, e, '\n')
780  返回:pbuf
调用者
名称描述
devkmsg_read
console_unlocksole_unlock - unlock the console system* Releases the console_lock which the caller holds on the console system* and the console driver list.* While the console_lock was held, console output may have been buffered* by printk()