函数逻辑报告 |
Source Code:fs\readdir.c |
Create Date:2022-07-29 10:36:34 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:filldir
函数原型:static int filldir(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 | |
int | namlen | |
loff_t | offset | |
u64 | ino | |
unsigned int | d_type |
225 | reclen等于@a is a power of 2 value (offsetof(structlinux_dirent, d_name) + namlen + 2, sizeof(long)) |
230 | 如果此条件成立可能性小(为编译器优化)(error)则返回:error |
240 | prev_reclen等于prev_reclen |
241 | 如果prev_reclen且signal_pending(当前进程)则返回:负EINTR |
243 | dirent等于current_dir |
244 | prev等于dirent减prev_reclen |
249 | unsafe_put_user(offset, & d_off, efault_end) |
250 | unsafe_put_user(d_ino, & d_ino, efault_end) |
251 | unsafe_put_user(reclen, & d_reclen, efault_end) |
252 | unsafe_put_user(d_type, (char__user * )dirent + reclen - 1, efault_end) |
253 | Note the "unsafe_put_user() semantics: we goto a* label for errors.(d_name, name, namlen, efault_end) |
254 | user_access_end() |
256 | current_dir等于dirent加reclen |
257 | prev_reclen等于reclen |
259 | 返回:0 |
260 | efault_end : |
261 | user_access_end() |
262 | efault : |
264 | 返回:负EFAULT |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |