[PATCH 05/12] tools/nolibc: remove now superfluous overflow check in llseek

From: Thomas Weißschuh

Date: Wed Oct 29 2025 - 12:04:52 EST


As off_t is now always 64-bit wide this overflow can not happen anymore,
remove the check.

Signed-off-by: Thomas Weißschuh <linux@xxxxxxxxxxxxxx>
---
tools/include/nolibc/sys.h | 2 --
1 file changed, 2 deletions(-)

diff --git a/tools/include/nolibc/sys.h b/tools/include/nolibc/sys.h
index 58cd2bb0f6ce..e91b7d947161 100644
--- a/tools/include/nolibc/sys.h
+++ b/tools/include/nolibc/sys.h
@@ -600,8 +600,6 @@ off_t sys_lseek(int fd, off_t offset, int whence)
ret = my_syscall5(__NR_llseek, fd, offset >> 32, (uint32_t)offset, &loff, whence);
if (ret < 0)
result = ret;
- else if (loff != (off_t)loff)
- result = -EOVERFLOW;
else
result = loff;


--
2.51.1.dirty