[all-commits] [llvm/llvm-project] 639c5a: [libc] Introduce the ioctl syscall wrapper and por...
Pavel Labath via All-commits
all-commits at lists.llvm.org
Tue Jun 23 00:08:31 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 639c5a014fad13c683b01c66a1474b7aa47ce7ee
https://github.com/llvm/llvm-project/commit/639c5a014fad13c683b01c66a1474b7aa47ce7ee
Author: Pavel Labath <pavel at labath.sk>
Date: 2026-06-23 (Tue, 23 Jun 2026)
Changed paths:
M libc/src/__support/OSUtil/linux/syscall_wrappers/CMakeLists.txt
A libc/src/__support/OSUtil/linux/syscall_wrappers/ioctl.h
M libc/src/sys/ioctl/linux/CMakeLists.txt
M libc/src/sys/ioctl/linux/ioctl.cpp
M libc/src/termios/linux/CMakeLists.txt
M libc/src/termios/linux/tcdrain.cpp
M libc/src/termios/linux/tcflow.cpp
M libc/src/termios/linux/tcflush.cpp
M libc/src/termios/linux/tcgetattr.cpp
M libc/src/termios/linux/tcgetsid.cpp
M libc/src/termios/linux/tcsendbreak.cpp
M libc/src/termios/linux/tcsetattr.cpp
M libc/src/unistd/linux/CMakeLists.txt
M libc/src/unistd/linux/isatty.cpp
Log Message:
-----------
[libc] Introduce the ioctl syscall wrapper and port all callers (#204640)
This patch adds an ioctl syscall wrapper in linux_syscalls namespace and
migrates all direct SYS_ioctl calls to use it.
To handle the polymorphic nature of ioctl arguments (where some commands
expect pointers, some expect scalar integers like queue_selector, and
some expect no argument at all), I use a helper struct IoctlArg with
implicit constructors. This avoids template bloat and overload
ambiguities (particularly around literal 0) while keeping call sites
clean.
Assisted by Gemini.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list