函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:fillonedir

函数原型:static int fillonedir(struct dir_context *ctx, const char *name, int namlen, loff_t offset, u64 ino, unsigned int d_type)

返回类型:int

参数:

类型参数名称
struct dir_context *ctx
const char *name
intnamlen
loff_toffset
u64ino
unsigned intd_type
146  buf等于container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.(ctx, structreaddir_callback, ctx)
148  __userdirent
151  如果result则返回:负EINVAL
153  d_ino等于ino
154  如果d_ino的长度小于ino的长度且d_ino不等于ino
155  result等于负EOVERFLOW
156  返回:负EOVERFLOW
158  result自加
159  dirent等于dirent
160  如果非access_ok - Checks if a user space pointer is valid*@addr: User space pointer to start of block to check*@size: Size of block to check* Context: User context only. This function may sleep if pagefaults are* enabled.(dirent, (unsignedlong)(d_name + namlen + 1) - (unsignedlong)dirent)则转到:efault
164  如果__put_user - Write a simple value into user space, with less checking(d_ino, & d_ino)或__put_user - Write a simple value into user space, with less checking(offset, & d_offset)或__put_user - Write a simple value into user space, with less checking(namlen, & d_namlen)或__copy_to_user(d_name, name, namlen)或__put_user - Write a simple value into user space, with less checking(0, d_name + namlen)则转到:efault
170  返回:0
171  efault :
172  result等于负EFAULT
173  返回:负EFAULT