函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:log_make_free_space

函数原型:static int log_make_free_space(unsigned int msg_size)

返回类型:int

参数:

类型参数名称
unsigned intmsg_size
546 dex and sequence number of the first record stored in the buffer 小于dex and sequence number of the next record to store in the buffer 且非Check whether there is enough free space for the given message.* The same values of first_idx and next_idx mean that the buffer* is either empty or full.* If the buffer is empty, we must respect the position of the indexes.循环
549  log_first_idx等于get next record; idx must point to valid msg
550  dex and sequence number of the first record stored in the buffer 自加
553  如果he next printk record to read after the last 'clear' command 小于dex and sequence number of the first record stored in the buffer
554  he next printk record to read after the last 'clear' command 等于dex and sequence number of the first record stored in the buffer
555  clear_idx等于log_first_idx
559  如果Check whether there is enough free space for the given message.* The same values of first_idx and next_idx mean that the buffer* is either empty or full.* If the buffer is empty, we must respect the position of the indexes.则返回:0
562  返回:负ENOMEM
调用者
名称描述
log_storesert record into the buffer, discard old ones, update heads