Home
last modified time | relevance | path

Searched refs:cmd (Results 1 – 25 of 92) sorted by relevance

1234

/fs/
Dcompat_ioctl.c128 static int do_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in do_ioctl() argument
132 err = security_file_ioctl(file, cmd, arg); in do_ioctl()
136 return vfs_ioctl(file, cmd, arg); in do_ioctl()
140 unsigned int cmd, compat_ulong_t __user *argp) in w_long() argument
147 err = do_ioctl(file, cmd, (unsigned long)valp); in w_long()
165 unsigned int cmd, struct compat_video_event __user *up) in do_video_get_event() argument
174 err = do_ioctl(file, cmd, (unsigned long)kevent); in do_video_get_event()
195 unsigned int cmd, struct compat_video_still_picture __user *up) in do_video_stillpicture() argument
215 err = do_ioctl(file, cmd, (unsigned long) up_native); in do_video_stillpicture()
226 unsigned int cmd, struct compat_video_spu_palette __user *up) in do_video_set_spu_palette() argument
[all …]
Dfcntl.c248 static long do_fcntl(int fd, unsigned int cmd, unsigned long arg, in do_fcntl() argument
253 switch (cmd) { in do_fcntl()
278 err = fcntl_getlk(filp, cmd, (struct flock __user *) arg); in do_fcntl()
288 err = fcntl_setlk(fd, filp, cmd, (struct flock __user *) arg); in do_fcntl()
336 err = pipe_fcntl(filp, cmd, arg); in do_fcntl()
340 err = shmem_fcntl(filp, cmd, arg); in do_fcntl()
348 static int check_fcntl_cmd(unsigned cmd) in check_fcntl_cmd() argument
350 switch (cmd) { in check_fcntl_cmd()
361 SYSCALL_DEFINE3(fcntl, unsigned int, fd, unsigned int, cmd, unsigned long, arg) in SYSCALL_DEFINE3() argument
370 if (!check_fcntl_cmd(cmd)) in SYSCALL_DEFINE3()
[all …]
Dioctl.c36 long vfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in vfs_ioctl() argument
43 error = filp->f_op->unlocked_ioctl(filp, cmd, arg); in vfs_ioctl()
477 static int file_ioctl(struct file *filp, unsigned int cmd, in file_ioctl() argument
483 switch (cmd) { in file_ioctl()
493 return vfs_ioctl(filp, cmd, arg); in file_ioctl()
618 int do_vfs_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, in do_vfs_ioctl() argument
625 switch (cmd) { in do_vfs_ioctl()
677 error = file_ioctl(filp, cmd, arg); in do_vfs_ioctl()
679 error = vfs_ioctl(filp, cmd, arg); in do_vfs_ioctl()
685 SYSCALL_DEFINE3(ioctl, unsigned int, fd, unsigned int, cmd, unsigned long, arg) in SYSCALL_DEFINE3() argument
[all …]
Dlocks.c395 static inline int flock_translate_cmd(int cmd) { in flock_translate_cmd() argument
396 if (cmd & LOCK_MAND) in flock_translate_cmd()
397 return cmd & (LOCK_MAND | LOCK_RW); in flock_translate_cmd()
398 switch (cmd) { in flock_translate_cmd()
411 flock_make_lock(struct file *filp, unsigned int cmd) in flock_make_lock() argument
414 int type = flock_translate_cmd(cmd); in flock_make_lock()
1988 SYSCALL_DEFINE2(flock, unsigned int, fd, unsigned int, cmd) in SYSCALL_DEFINE2() argument
1999 can_sleep = !(cmd & LOCK_NB); in SYSCALL_DEFINE2()
2000 cmd &= ~LOCK_NB; in SYSCALL_DEFINE2()
2001 unlock = (cmd == LOCK_UN); in SYSCALL_DEFINE2()
[all …]
/fs/ext2/
Dioctl.c20 long ext2_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in ext2_ioctl() argument
28 ext2_debug ("cmd = %u, arg = %lu\n", cmd, arg); in ext2_ioctl()
30 switch (cmd) { in ext2_ioctl()
167 long ext2_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ext2_compat_ioctl() argument
170 switch (cmd) { in ext2_compat_ioctl()
172 cmd = EXT2_IOC_GETFLAGS; in ext2_compat_ioctl()
175 cmd = EXT2_IOC_SETFLAGS; in ext2_compat_ioctl()
178 cmd = EXT2_IOC_GETVERSION; in ext2_compat_ioctl()
181 cmd = EXT2_IOC_SETVERSION; in ext2_compat_ioctl()
186 return ext2_ioctl(file, cmd, (unsigned long) compat_ptr(arg)); in ext2_compat_ioctl()
/fs/reiserfs/
Dioctl.c23 long reiserfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in reiserfs_ioctl() argument
31 switch (cmd) { in reiserfs_ioctl()
133 long reiserfs_compat_ioctl(struct file *file, unsigned int cmd, in reiserfs_compat_ioctl() argument
140 switch (cmd) { in reiserfs_compat_ioctl()
142 cmd = REISERFS_IOC_UNPACK; in reiserfs_compat_ioctl()
145 cmd = REISERFS_IOC_GETFLAGS; in reiserfs_compat_ioctl()
148 cmd = REISERFS_IOC_SETFLAGS; in reiserfs_compat_ioctl()
151 cmd = REISERFS_IOC_GETVERSION; in reiserfs_compat_ioctl()
154 cmd = REISERFS_IOC_SETVERSION; in reiserfs_compat_ioctl()
160 return reiserfs_ioctl(file, cmd, (unsigned long) compat_ptr(arg)); in reiserfs_compat_ioctl()
/fs/ocfs2/
Dlocks.c39 int cmd, struct file_lock *fl) in ocfs2_do_flock() argument
47 if (!IS_SETLKW(cmd)) in ocfs2_do_flock()
97 static int ocfs2_do_funlock(struct file *file, int cmd, struct file_lock *fl) in ocfs2_do_funlock() argument
113 int ocfs2_flock(struct file *file, int cmd, struct file_lock *fl) in ocfs2_flock() argument
128 return ocfs2_do_funlock(file, cmd, fl); in ocfs2_flock()
130 return ocfs2_do_flock(file, inode, cmd, fl); in ocfs2_flock()
133 int ocfs2_lock(struct file *file, int cmd, struct file_lock *fl) in ocfs2_lock() argument
143 return ocfs2_plock(osb->cconn, OCFS2_I(inode)->ip_blkno, file, cmd, fl); in ocfs2_lock()
Dioctl.h13 long ocfs2_ioctl(struct file *filp, unsigned int cmd, unsigned long arg);
14 long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg);
Dlocks.h29 int ocfs2_flock(struct file *file, int cmd, struct file_lock *fl);
30 int ocfs2_lock(struct file *file, int cmd, struct file_lock *fl);
/fs/autofs4/
Ddev-ioctl.c71 static int check_dev_ioctl_version(int cmd, struct autofs_dev_ioctl *param) in check_dev_ioctl_version() argument
81 param->ver_major, param->ver_minor, cmd); in check_dev_ioctl_version()
126 static int validate_dev_ioctl(int cmd, struct autofs_dev_ioctl *param) in validate_dev_ioctl() argument
130 err = check_dev_ioctl_version(cmd, param); in validate_dev_ioctl()
133 "supplied for cmd(0x%08x)\n", cmd); in validate_dev_ioctl()
142 cmd); in validate_dev_ioctl()
149 cmd); in validate_dev_ioctl()
596 #define cmd_idx(cmd) (cmd - _IOC_NR(AUTOFS_DEV_IOCTL_IOC_FIRST)) argument
598 static ioctl_fn lookup_dev_ioctl(unsigned int cmd) in lookup_dev_ioctl() argument
616 unsigned int idx = cmd_idx(cmd); in lookup_dev_ioctl()
[all …]
Droot.c866 unsigned int cmd, unsigned long arg) in autofs4_root_ioctl_unlocked() argument
872 cmd, arg, sbi, task_pgrp_nr(current)); in autofs4_root_ioctl_unlocked()
874 if (_IOC_TYPE(cmd) != _IOC_TYPE(AUTOFS_IOC_FIRST) || in autofs4_root_ioctl_unlocked()
875 _IOC_NR(cmd) - _IOC_NR(AUTOFS_IOC_FIRST) >= AUTOFS_IOC_COUNT) in autofs4_root_ioctl_unlocked()
881 switch (cmd) { in autofs4_root_ioctl_unlocked()
918 unsigned int cmd, unsigned long arg) in autofs4_root_ioctl() argument
922 return autofs4_root_ioctl_unlocked(inode, filp, cmd, arg); in autofs4_root_ioctl()
927 unsigned int cmd, unsigned long arg) in autofs4_root_compat_ioctl() argument
932 if (cmd == AUTOFS_IOC_READY || cmd == AUTOFS_IOC_FAIL) in autofs4_root_compat_ioctl()
933 ret = autofs4_root_ioctl_unlocked(inode, filp, cmd, arg); in autofs4_root_compat_ioctl()
[all …]
/fs/9p/
Dvfs_file.c131 static int v9fs_file_lock(struct file *filp, int cmd, struct file_lock *fl) in v9fs_file_lock() argument
142 if ((IS_SETLK(cmd) || IS_SETLKW(cmd)) && fl->fl_type != F_UNLCK) { in v9fs_file_lock()
150 static int v9fs_file_do_lock(struct file *filp, int cmd, struct file_lock *fl) in v9fs_file_do_lock() argument
189 if (IS_SETLKW(cmd)) in v9fs_file_do_lock()
203 if (status == P9_LOCK_BLOCKED && !IS_SETLKW(cmd)) in v9fs_file_do_lock()
305 static int v9fs_file_lock_dotl(struct file *filp, int cmd, struct file_lock *fl) in v9fs_file_lock_dotl() argument
311 filp, cmd, fl, filp); in v9fs_file_lock_dotl()
317 if ((IS_SETLK(cmd) || IS_SETLKW(cmd)) && fl->fl_type != F_UNLCK) { in v9fs_file_lock_dotl()
322 if (IS_SETLK(cmd) || IS_SETLKW(cmd)) in v9fs_file_lock_dotl()
323 ret = v9fs_file_do_lock(filp, cmd, fl); in v9fs_file_lock_dotl()
[all …]
/fs/nilfs2/
Dioctl.c217 unsigned int cmd, void __user *argp) in nilfs_ioctl_change_cpmode() argument
272 unsigned int cmd, void __user *argp) in nilfs_ioctl_delete_checkpoint() argument
351 unsigned int cmd, void __user *argp) in nilfs_ioctl_get_cpstat() argument
418 unsigned int cmd, void __user *argp) in nilfs_ioctl_get_sustat() argument
527 unsigned int cmd, void __user *argp) in nilfs_ioctl_get_bdescs() argument
539 ret = nilfs_ioctl_wrap_copy(nilfs, &argv, _IOC_DIR(cmd), in nilfs_ioctl_get_bdescs()
874 unsigned int cmd, void __user *argp) in nilfs_ioctl_clean_segments() argument
1013 unsigned int cmd, void __user *argp) in nilfs_ioctl_sync() argument
1179 unsigned int cmd, void __user *argp, in nilfs_ioctl_get_info() argument
1196 ret = nilfs_ioctl_wrap_copy(nilfs, &argv, _IOC_DIR(cmd), dofunc); in nilfs_ioctl_get_info()
[all …]
/fs/xfs/
Dxfs_ioctl32.c40 #define _NATIVE_IOC(cmd, type) \ argument
41 _IOC(_IOC_DIR(cmd), _IOC_TYPE(cmd), _IOC_NR(cmd), sizeof(type))
244 unsigned int cmd, in xfs_compat_ioc_bulkstat() argument
283 if (cmd == XFS_IOC_FSINUMBERS_32) { in xfs_compat_ioc_bulkstat()
286 } else if (cmd == XFS_IOC_FSBULKSTAT_SINGLE_32) { in xfs_compat_ioc_bulkstat()
291 } else if (cmd == XFS_IOC_FSBULKSTAT_32) { in xfs_compat_ioc_bulkstat()
528 unsigned cmd, in xfs_file_compat_ioctl() argument
539 switch (cmd) { in xfs_file_compat_ioctl()
557 return xfs_file_ioctl(filp, cmd, p); in xfs_file_compat_ioctl()
572 return xfs_file_ioctl(filp, cmd, p); in xfs_file_compat_ioctl()
[all …]
Dxfs_ioctl.h24 unsigned int cmd,
33 unsigned int cmd,
77 unsigned int cmd,
83 unsigned int cmd,
/fs/jfs/
Dioctl.c59 long jfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in jfs_ioctl() argument
65 switch (cmd) { in jfs_ioctl()
170 long jfs_compat_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in jfs_compat_ioctl() argument
176 switch (cmd) { in jfs_compat_ioctl()
178 cmd = JFS_IOC_GETFLAGS; in jfs_compat_ioctl()
181 cmd = JFS_IOC_SETFLAGS; in jfs_compat_ioctl()
184 return jfs_ioctl(filp, cmd, arg); in jfs_compat_ioctl()
/fs/ubifs/
Dioctl.c147 long ubifs_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ubifs_ioctl() argument
152 switch (cmd) { in ubifs_ioctl()
191 long ubifs_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ubifs_compat_ioctl() argument
193 switch (cmd) { in ubifs_compat_ioctl()
195 cmd = FS_IOC_GETFLAGS; in ubifs_compat_ioctl()
198 cmd = FS_IOC_SETFLAGS; in ubifs_compat_ioctl()
203 return ubifs_ioctl(file, cmd, (unsigned long)compat_ptr(arg)); in ubifs_compat_ioctl()
/fs/quota/
Dcompat.c43 asmlinkage long sys32_quotactl(unsigned int cmd, const char __user *special, in sys32_quotactl() argument
55 cmds = cmd >> SUBCMDSHIFT; in sys32_quotactl()
61 ret = sys_quotactl(cmd, special, id, dqblk); in sys32_quotactl()
77 ret = sys_quotactl(cmd, special, id, dqblk); in sys32_quotactl()
82 ret = sys_quotactl(cmd, special, id, fsqstat); in sys32_quotactl()
115 ret = sys_quotactl(cmd, special, id, addr); in sys32_quotactl()
Dquota.c21 static int check_quotactl_permission(struct super_block *sb, int type, int cmd, in check_quotactl_permission() argument
24 switch (cmd) { in check_quotactl_permission()
45 return security_quotactl(cmd, type, id, sb); in check_quotactl_permission()
702 static int do_quotactl(struct super_block *sb, int type, int cmd, qid_t id, in do_quotactl() argument
707 if (type >= (XQM_COMMAND(cmd) ? XQM_MAXQUOTAS : MAXQUOTAS)) in do_quotactl()
718 ret = check_quotactl_permission(sb, type, cmd, id); in do_quotactl()
722 switch (cmd) { in do_quotactl()
772 static int quotactl_cmd_write(int cmd) in quotactl_cmd_write() argument
779 switch (cmd) { in quotactl_cmd_write()
799 static struct super_block *quotactl_block(const char __user *special, int cmd) in quotactl_block() argument
[all …]
/fs/nfs/
Dfile.c662 do_getlk(struct file *filp, int cmd, struct file_lock *fl, int is_local) in do_getlk() argument
682 status = NFS_PROTO(inode)->lock(filp, cmd, fl); in do_getlk()
691 do_unlk(struct file *filp, int cmd, struct file_lock *fl, int is_local) in do_unlk() argument
720 status = NFS_PROTO(inode)->lock(filp, cmd, fl); in do_unlk()
727 do_setlk(struct file *filp, int cmd, struct file_lock *fl, int is_local) in do_setlk() argument
745 status = NFS_PROTO(inode)->lock(filp, cmd, fl); in do_setlk()
768 int nfs_lock(struct file *filp, int cmd, struct file_lock *fl) in nfs_lock() argument
793 if (IS_GETLK(cmd)) in nfs_lock()
794 ret = do_getlk(filp, cmd, fl, is_local); in nfs_lock()
796 ret = do_unlk(filp, cmd, fl, is_local); in nfs_lock()
[all …]
/fs/ext4/
Dioctl.c435 long ext4_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) in ext4_ioctl() argument
442 ext4_debug("cmd = %u, arg = %lu\n", cmd, arg); in ext4_ioctl()
444 switch (cmd) { in ext4_ioctl()
746 int flags = cmd == FIDTRIM ? BLKDEV_DISCARD_SECURE : 0; in ext4_ioctl()
882 long ext4_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ext4_compat_ioctl() argument
885 switch (cmd) { in ext4_compat_ioctl()
887 cmd = EXT4_IOC_GETFLAGS; in ext4_compat_ioctl()
890 cmd = EXT4_IOC_SETFLAGS; in ext4_compat_ioctl()
893 cmd = EXT4_IOC_GETVERSION; in ext4_compat_ioctl()
896 cmd = EXT4_IOC_SETVERSION; in ext4_compat_ioctl()
[all …]
/fs/ncpfs/
Dioctl.c257 static long __ncp_ioctl(struct inode *inode, unsigned int cmd, unsigned long arg) in __ncp_ioctl() argument
265 switch (cmd) { in __ncp_ioctl()
271 if (cmd == NCP_IOC_NCPREQUEST_32) { in __ncp_ioctl()
525 switch (rqdata.cmd) { in __ncp_ioctl()
550 if (rqdata.cmd == NCP_LOCK_CLEAR) in __ncp_ioctl()
562 switch (rqdata.cmd) in __ncp_ioctl()
649 if (cmd == NCP_IOC_SETOBJECTNAME_32) { in __ncp_ioctl()
696 if (cmd == NCP_IOC_GETPRIVATEDATA_32) { in __ncp_ioctl()
722 if (cmd == NCP_IOC_GETPRIVATEDATA_32) { in __ncp_ioctl()
747 if (cmd == NCP_IOC_SETPRIVATEDATA_32) { in __ncp_ioctl()
[all …]
/fs/ceph/
Dlocks.c36 int cmd, u8 wait, struct file_lock *fl) in ceph_lock_message() argument
45 if (operation != CEPH_MDS_OP_SETFILELOCK || cmd == CEPH_LOCK_UNLOCK) in ceph_lock_message()
69 req->r_args.filelock_change.type = cmd; in ceph_lock_message()
157 int ceph_lock(struct file *file, int cmd, struct file_lock *fl) in ceph_lock() argument
173 if (IS_GETLK(cmd)) in ceph_lock()
175 else if (IS_SETLKW(cmd)) in ceph_lock()
204 int ceph_flock(struct file *file, int cmd, struct file_lock *fl) in ceph_flock() argument
218 if (IS_SETLKW(cmd)) in ceph_flock()
/fs/coda/
Dpioctl.c28 static long coda_pioctl(struct file *filp, unsigned int cmd,
48 static long coda_pioctl(struct file *filp, unsigned int cmd, in coda_pioctl() argument
85 error = venus_pioctl(inode->i_sb, &(cnp->c_fid), cmd, &data); in coda_pioctl()
/fs/ecryptfs/
Dfile.c350 ecryptfs_unlocked_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ecryptfs_unlocked_ioctl() argument
358 switch (cmd) { in ecryptfs_unlocked_ioctl()
364 rc = lower_file->f_op->unlocked_ioctl(lower_file, cmd, arg); in ecryptfs_unlocked_ioctl()
375 ecryptfs_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) in ecryptfs_compat_ioctl() argument
383 switch (cmd) { in ecryptfs_compat_ioctl()
388 rc = lower_file->f_op->compat_ioctl(lower_file, cmd, arg); in ecryptfs_compat_ioctl()

1234