Lines Matching defs:int

39 int do_truncate(struct mnt_idmap *idmap, struct dentry *dentry,
40 loff_t length, unsigned int time_attrs, struct file *filp)
42 int ret;
124 unsigned int lookup_flags = LOOKUP_FOLLOW;
126 int error;
156 long do_ftruncate(struct file *file, loff_t length, int small)
160 int error;
188 long do_sys_ftruncate(unsigned int fd, loff_t length, int small)
191 int error;
205 SYSCALL_DEFINE2(ftruncate, unsigned int, fd, unsigned long, length)
211 COMPAT_SYSCALL_DEFINE2(ftruncate, unsigned int, fd, compat_ulong_t, length)
224 SYSCALL_DEFINE2(ftruncate64, unsigned int, fd, loff_t, length)
239 COMPAT_SYSCALL_DEFINE3(ftruncate64, unsigned int, fd,
246 int vfs_fallocate(struct file *file, int mode, loff_t offset, loff_t len)
347 int ksys_fallocate(int fd, int mode, loff_t offset, loff_t len)
350 int error = -EBADF;
359 SYSCALL_DEFINE4(fallocate, int, fd, int, mode, loff_t, offset, loff_t, len)
365 COMPAT_SYSCALL_DEFINE6(fallocate, int, fd, int, mode, compat_arg_u64_dual(offset),
381 static bool access_need_override_creds(int flags)
464 static long do_faccessat(int dfd, const char __user *filename, int mode, int flags)
468 int res;
469 unsigned int lookup_flags = LOOKUP_FOLLOW;
536 SYSCALL_DEFINE3(faccessat, int, dfd, const char __user *, filename, int, mode)
541 SYSCALL_DEFINE4(faccessat2, int, dfd, const char __user *, filename, int, mode,
542 int, flags)
547 SYSCALL_DEFINE2(access, const char __user *, filename, int, mode)
555 int error;
556 unsigned int lookup_flags = LOOKUP_FOLLOW | LOOKUP_DIRECTORY;
578 SYSCALL_DEFINE1(fchdir, unsigned int, fd)
581 int error;
603 int error;
604 unsigned int lookup_flags = LOOKUP_FOLLOW | LOOKUP_DIRECTORY;
633 int chmod_common(const struct path *path, umode_t mode)
638 int error;
663 int vfs_fchmod(struct file *file, umode_t mode)
669 SYSCALL_DEFINE2(fchmod, unsigned int, fd, umode_t, mode)
672 int err = -EBADF;
681 static int do_fchmodat(int dfd, const char __user *filename, umode_t mode,
682 unsigned int flags)
685 int error;
686 unsigned int lookup_flags;
708 SYSCALL_DEFINE4(fchmodat2, int, dfd, const char __user *, filename,
709 umode_t, mode, unsigned int, flags)
714 SYSCALL_DEFINE3(fchmodat, int, dfd, const char __user *, filename,
755 int chown_common(const struct path *path, uid_t user, gid_t group)
761 int error;
801 int do_fchownat(int dfd, const char __user *filename, uid_t user, gid_t group,
802 int flag)
805 int error = -EINVAL;
806 int lookup_flags;
833 SYSCALL_DEFINE5(fchownat, int, dfd, const char __user *, filename, uid_t, user,
834 gid_t, group, int, flag)
850 int vfs_fchown(struct file *file, uid_t user, gid_t group)
852 int error;
863 int ksys_fchown(unsigned int fd, uid_t user, gid_t group)
866 int error = -EBADF;
875 SYSCALL_DEFINE3(fchown, unsigned int, fd, uid_t, user, gid_t, group)
880 static inline int file_get_write_access(struct file *f)
882 int error;
904 static int do_dentry_open(struct file *f,
906 int (*open)(struct inode *, struct file *))
909 int error;
1044 int finish_open(struct file *file, struct dentry *dentry,
1045 int (*open)(struct inode *, struct file *))
1068 int finish_no_open(struct file *file, struct dentry *dentry)
1075 char *file_path(struct file *filp, char *buf, int buflen)
1086 int vfs_open(const struct path *path, struct file *file)
1092 struct file *dentry_open(const struct path *path, int flags,
1095 int error;
1130 struct file *dentry_create(const struct path *path, int flags, umode_t mode,
1134 int error;
1167 struct file *kernel_file_open(const struct path *path, int flags,
1171 int error;
1190 inline struct open_how build_open_how(int flags, umode_t mode)
1206 inline int build_open_flags(const struct open_how *how, struct open_flags *op)
1210 int lookup_flags = 0;
1211 int acc_mode = ACC_MODE(flags);
1344 struct file *file_open_name(struct filename *name, int flags, umode_t mode)
1348 int err = build_open_flags(&how, &op);
1365 struct file *filp_open(const char *filename, int flags, umode_t mode)
1379 const char *filename, int flags, umode_t mode)
1383 int err = build_open_flags(&how, &op);
1390 static long do_sys_openat2(int dfd, const char __user *filename,
1394 int fd = build_open_flags(how, &op);
1418 long do_sys_open(int dfd, const char __user *filename, int flags, umode_t mode)
1425 SYSCALL_DEFINE3(open, const char __user *, filename, int, flags, umode_t, mode)
1432 SYSCALL_DEFINE4(openat, int, dfd, const char __user *, filename, int, flags,
1440 SYSCALL_DEFINE4(openat2, int, dfd, const char __user *, filename,
1443 int err;
1470 COMPAT_SYSCALL_DEFINE3(open, const char __user *, filename, int, flags, umode_t, mode)
1479 COMPAT_SYSCALL_DEFINE4(openat, int, dfd, const char __user *, filename, int, flags, umode_t, mode)
1493 int flags = O_CREAT | O_WRONLY | O_TRUNC;
1505 static int filp_flush(struct file *filp, fl_owner_t id)
1507 int retval = 0;
1525 int filp_close(struct file *filp, fl_owner_t id)
1527 int retval;
1541 SYSCALL_DEFINE1(close, unsigned int, fd)
1543 int retval;
1579 SYSCALL_DEFINE3(close_range, unsigned int, fd, unsigned int, max_fd,
1580 unsigned int, flags)
1604 int generic_file_open(struct inode * inode, struct file * filp)
1616 * reason it returns an 'int' and not 'void' is so that it can be plugged
1619 int nonseekable_open(struct inode *inode, struct file *filp)
1634 * stream_open never fails and is marked to return int so that it could be
1637 int stream_open(struct inode *inode, struct file *filp)