Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\tomoyo\realpath.c Create Date:2022-07-28 19:45:59
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:moyo_get_dentry_path - Get the path of a dentry.*@dentry: Pointer to "struct dentry".*@buffer: Pointer to buffer to return value in.*@buflen: Sizeof @buffer.* Returns the buffer on success, an error code otherwise.

Proto:static char *tomoyo_get_dentry_path(struct dentry *dentry, char *const buffer, const int buflen)

Type:char

Parameter:

TypeParameterName
struct dentry *dentry
char *constbuffer
const intbuflen
127  pos = ERR_PTR( - ENOMEM)
129  If buflen >= 256 Then
130  pos = dentry_path_raw(dentry, buffer, buflen - 1)
131  If Not IS_ERR(pos) && pos == '/' && pos[1] Then
134  If inode && S_ISDIR(i_mode) Then
135  buffer[buflen - 2] = '/'
136  buffer[buflen - 1] = '\0'
140  Return pos
Caller
NameDescribe
tomoyo_get_local_pathmoyo_get_local_path - Get the path of a dentry.*@dentry: Pointer to "struct dentry".*@buffer: Pointer to buffer to return value in.*@buflen: Sizeof @buffer.* Returns the buffer on success, an error code otherwise.