From e8767a3134ca69a307b37f7f58ca088dbee6eb82 Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Mon, 23 Mar 2026 08:01:46 +0100 Subject: fs: remove do_sys_truncate do_sys_truncate ist only used to implement ksys_truncate and the native truncate syscalls. Merge do_sys_truncate into ksys_truncate and return int from it as it only returns 0 or negative errnos. Signed-off-by: Christoph Hellwig Link: https://patch.msgid.link/20260323070205.2939118-4-hch@lst.de Reviewed-by: Jan Kara Signed-off-by: Christian Brauner --- include/linux/syscalls.h | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'include') diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h index 8787b3511c86..f5639d5ac331 100644 --- a/include/linux/syscalls.h +++ b/include/linux/syscalls.h @@ -1285,13 +1285,7 @@ static inline long ksys_lchown(const char __user *filename, uid_t user, #define FTRUNCATE_LFS (1u << 0) /* allow truncating > 32-bit */ int ksys_ftruncate(unsigned int fd, loff_t length, unsigned int flags); - -int do_sys_truncate(const char __user *pathname, loff_t length); - -static inline long ksys_truncate(const char __user *pathname, loff_t length) -{ - return do_sys_truncate(pathname, length); -} +int ksys_truncate(const char __user *pathname, loff_t length); static inline unsigned int ksys_personality(unsigned int personality) { -- cgit v1.2.3