函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:do_handle_open

函数原型:static long do_handle_open(int mountdirfd, struct file_handle __user *ufh, int open_flag)

返回类型:long

参数:

类型参数名称
intmountdirfd
struct file_handle __user *ufh
intopen_flag
218  retval等于0
223  retval等于handle_to_path(mountdirfd, ufh, & path)
224  如果retval则返回:retval
227  fd等于get_unused_fd_flags(open_flag)
228  如果fd小于0则
229  path_put - put a reference to a path*@path: path to put the reference to* Given a path decrement the reference count to the dentry and the vfsmount.
230  返回:fd
232  file等于file_open_root(dentry, mnt, "", open_flag, 0)
233  如果是错误
234  put_unused_fd(fd)
235  retval等于错误
236  否则
237  retval等于fd
238  snotify_open - file was opened
239  fd_install(fd, file)
241  path_put - put a reference to a path*@path: path to put the reference to* Given a path decrement the reference count to the dentry and the vfsmount.
242  返回:retval
调用者
名称描述
SYSCALL_DEFINE3sys_open_by_handle_at: Open the file handle*@mountdirfd: directory file descriptor*@handle: file handle to be opened*@flags: open flags.*@mountdirfd indicate the directory file descriptor* of the mount point. file handle is decoded relative
COMPAT_SYSCALL_DEFINE3Exactly like fs/open.c:sys_open_by_handle_at(), except that it* doesn't set the O_LARGEFILE flag.