Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\open.c Create Date:2022-07-28 20:00:59
Last Modify:2020-03-18 10:16:03 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:do_sys_open

Proto:long do_sys_open(int dfd, const char __user *filename, int flags, umode_t mode)

Type:long

Parameter:

TypeParameterName
intdfd
const char __user *filename
intflags
umode_tmode
1085  fd = build_open_flags(flags, mode, & op)
1088  If fd Then Return fd
1091  tmp = getname(filename)
1092  If IS_ERR(tmp) Then Return PTR_ERR(tmp)
1095  fd = get_unused_fd_flags(flags)
1096  If fd >= 0 Then
1097  f = do_filp_open(dfd, tmp, & op)
1098  If IS_ERR(f) Then
1099  put_unused_fd(fd)
1100  fd = PTR_ERR(f)
1101  Else
1103  fd_install(fd, f)
1106  putname(tmp)
1107  Return fd
Caller
NameDescribe
SYSCALL_DEFINE3
SYSCALL_DEFINE4
COMPAT_SYSCALL_DEFINE3Exactly like sys_open(), except that it doesn't set the* O_LARGEFILE flag.
COMPAT_SYSCALL_DEFINE4Exactly like sys_openat(), except that it doesn't set the* O_LARGEFILE flag.
ksys_open