diff options
| author | Yuichiro Tsuji <yuichtsu@amazon.com> | 2025-01-21 16:08:23 +0900 |
|---|---|---|
| committer | Christian Brauner <brauner@kernel.org> | 2025-02-21 10:25:32 +0100 |
| commit | f326565c44419380d18290edee5f78921418f7a5 (patch) | |
| tree | 08d63fe18574fb95ff4420feb4a74c3ae3de382f /fs/ioctl.c | |
| parent | 29d80d506b18384f64a54b01fae78184e2d327f3 (diff) | |
| download | tip-f326565c44419380d18290edee5f78921418f7a5.tar.gz | |
ioctl: Fix return type of several functions from long to int
Fix the return type of several functions from long to int to match its actu
al behavior. These functions only return int values. This change improves
type consistency across the filesystem code and aligns the function signatu
re with its existing implementation and usage.
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Yuichiro Tsuji <yuichtsu@amazon.com>
Link: https://lore.kernel.org/r/20250121070844.4413-3-yuichtsu@amazon.com
Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'fs/ioctl.c')
| -rw-r--r-- | fs/ioctl.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/ioctl.c b/fs/ioctl.c index 638a36be31c14a..c91fd2b46a77f6 100644 --- a/fs/ioctl.c +++ b/fs/ioctl.c @@ -41,7 +41,7 @@ * * Returns 0 on success, -errno on error. */ -long vfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) +int vfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) { int error = -ENOTTY; @@ -228,8 +228,8 @@ static int ioctl_fiemap(struct file *filp, struct fiemap __user *ufiemap) return error; } -static long ioctl_file_clone(struct file *dst_file, unsigned long srcfd, - u64 off, u64 olen, u64 destoff) +static int ioctl_file_clone(struct file *dst_file, unsigned long srcfd, + u64 off, u64 olen, u64 destoff) { CLASS(fd, src_file)(srcfd); loff_t cloned; @@ -248,8 +248,8 @@ static long ioctl_file_clone(struct file *dst_file, unsigned long srcfd, return ret; } -static long ioctl_file_clone_range(struct file *file, - struct file_clone_range __user *argp) +static int ioctl_file_clone_range(struct file *file, + struct file_clone_range __user *argp) { struct file_clone_range args; |
