函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Create a new node and associated debugfs entry. Needs to be called with* node_lock held.

函数原型:static struct gcov_node *new_node(struct gcov_node *parent, struct gcov_info *info, const char *name)

返回类型:struct gcov_node

参数:

类型参数名称
struct gcov_node *parent
struct gcov_info *info
const char *name
434  node等于分配内存并置零
435  如果非node则转到:err_nomem
437  如果info
438  loaded_info等于分配数组内存并置零
440  如果非loaded_info则转到:err_nomem
443  Basic initialization of a new node.
445  如果info
446  dentry等于debugfs_create_file(For a filename .tmp_filename.ext return filename.ext. Needed to compensate* for filename skewing caused by the mod-versioning mechanism., 0600, dentry, node, & gcov_data_fops)
448  否则dentry等于debugfs_create_dir(name, dentry)
450  如果infoCreate links to additional files (usually .c and .gcno files) which the* gcov tool expects to find in the same directory as the gcov data file.
452  添加链表项
453  添加链表项
455  返回:node
457  err_nomem :
458  kfree(node)
459  打印警告信息("out of memory\n")
460  返回:NULL
调用者
名称描述
add_nodeCreate a node for a given profiling data set and add it to all lists and* debugfs. Needs to be called with node_lock held.