Re: fix architecture-specific compat_ftruncate64 implementations
From: Christian Brauner <brauner@kernel.org>
Date: 2026-03-23 11:44:36
Also in:
linux-arm-kernel, linux-fsdevel, linux-mips, linuxppc-dev, sparclinux
On Mon, 23 Mar 2026 08:01:43 +0100, Christoph Hellwig wrote:
this series fixes a really old bug found by code inspection, where the architecture-specific 32-bit compat ftruncate64 implementations enforce the non-LFS file size limit unless opened with O_LARGEFILE. Diffstat: arch/arm64/kernel/sys32.c | 2 +- arch/mips/kernel/linux32.c | 2 +- arch/parisc/kernel/sys_parisc.c | 4 ++-- arch/powerpc/kernel/sys_ppc32.c | 2 +- arch/sparc/kernel/sys_sparc32.c | 2 +- arch/x86/kernel/sys_ia32.c | 3 ++- fs/internal.h | 3 +-- fs/open.c | 40 +++++++++++++++++++--------------------- include/linux/syscalls.h | 16 +++------------- io_uring/truncate.c | 2 +- 10 files changed, 32 insertions(+), 44 deletions(-) [...]
VFS CI: https://github.com/linux-fsdevel/vfs/actions/runs/23425735066 x86_64 (gcc, debian, ovl-fstests) pass x86_64 (gcc, debian, selftests) pass x86_64 (gcc, debian, xfstests) pass x86_64 (gcc, fedora, ovl-fstests) pass x86_64 (gcc, fedora, selftests) pass x86_64 (gcc, fedora, xfstests) pass --- Applied to the vfs-7.1.misc branch of the vfs/vfs.git tree. Patches in the vfs-7.1.misc branch should appear in linux-next soon. Please report any outstanding bugs that were missed during review in a new review to the original patch series allowing us to drop it. It's encouraged to provide Acked-bys and Reviewed-bys even though the patch has now been applied. If possible patch trailers will be updated. Note that commit hashes shown below are subject to change due to rebase, trailer updates or similar. If in doubt, please check the listed branch. tree: https://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs.git branch: vfs-7.1.misc [1/3] fs: fix archiecture-specific compat_ftruncate64 https://git.kernel.org/vfs/vfs/c/e43dce8a0bc0 [2/3] fs: pass on FTRUNCATE_* flags to do_truncate https://git.kernel.org/vfs/vfs/c/0924f6b80d4a [3/3] fs: remove do_sys_truncate https://git.kernel.org/vfs/vfs/c/e8767a3134ca