[PATCH] Linux: Define struct termios2 and its ioctls on all architectures
Florian Weimer
fweimer@redhat.com
Wed Jul 9 12:30:07 GMT 2025
* Andreas Schwab:
> I think installed glibc headers should not define any termios2 ioctl
> numbers anywhere. Most users should be using the POSIX termios
> interfaces, and code that needs to bypass glibc to interface with the
> ioctl syscall directly (strace, seccomp, etc.) must use the definitions
> from the kernel headers anyway.
I assume this also applies to the termios ioctls?
The current tree adds macros for those to an installed header.
I can clean this up so that no termios ioctls are in the glibc headers,
and internal definitions are used.
I don't want to add a definition of a __kernel_ type to an installed
glibc header. I also don't think we should use the ioctl macros (_IOR
etc.) to define the internal types, but use the expected numbers
directly. This way, we can verify them more easily against the kernel
headers using the existing constant comparison tool.
I definitely want to see this fixed in this release, but I don't know if
I'll have time to work on this before the 21st.
Thanks,
Florian
More information about the Libc-alpha
mailing list