函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:prepend_name - prepend a pathname in front of current buffer pointer*@buffer: buffer pointer*@buflen: allocated length of the buffer*@name: name string and length qstr structure* With RCU path tracing, it may race with d_move()

函数原型:static int prepend_name(char **buffer, int *buflen, const struct qstr *name)

返回类型:int

参数:

类型参数名称
char **buffer
int *buflen
const struct qstr *name
40  dname等于smp_load_acquire( & name)
41  dlen等于READ_ONCE(len)
44  buflen减等于dlen加1
45  如果buflen小于0则返回:负ENAMETOOLONG
47  p等于buffer减等于dlen加1
48  p自加等于'/'
49 dlen自减循环
50  c等于dname自加
51  如果非c退出
53  p自加等于c
55  返回:0
调用者
名称描述
prepend_pathprepend_path - Prepend path string to a buffer*@path: the dentry/vfsmount to report*@root: root vfsmnt/dentry*@buffer: pointer to the end of the buffer*@buflen: pointer to buffer length* The function will first try to write out the pathname without taking
__dentry_pathWrite full pathname from the root of the filesystem into the buffer.