From: Thomas Weißschuh Date: Sat, 18 Apr 2026 10:20:01 +0000 (+0200) Subject: tools/nolibc: open files with O_LARGEFILE X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ce7677458e680d0742fb7f86c0e27272e4c56205;p=thirdparty%2Fkernel%2Flinux.git tools/nolibc: open files with O_LARGEFILE nolibc can natively handle large files. Tell this to the kernel by always using O_LARGEFILE when opening files. This is also how other libcs do it. Signed-off-by: Thomas Weißschuh Acked-by: Willy Tarreau Link: https://patch.msgid.link/20260418-nolibc-largefile-v1-6-b91f0775bac3@weissschuh.net --- diff --git a/tools/include/nolibc/fcntl.h b/tools/include/nolibc/fcntl.h index 56650a36f8569..014910a8e928d 100644 --- a/tools/include/nolibc/fcntl.h +++ b/tools/include/nolibc/fcntl.h @@ -29,6 +29,8 @@ int openat(int dirfd, const char *path, int flags, ...) { mode_t mode = 0; + flags |= O_LARGEFILE; + if (flags & O_CREAT) { va_list args; @@ -55,6 +57,8 @@ int open(const char *path, int flags, ...) { mode_t mode = 0; + flags |= O_LARGEFILE; + if (flags & O_CREAT) { va_list args;