[libc-commits] [libc] [libc] Make struct ifreq compatible with linux/if.h (PR #225793)

Pavel Labath via libc-commits libc-commits at lists.llvm.org
Tue Oct 6 04:01:23 PDT 2026


labath wrote:

That is what I'm doing where the relevant kernel headers are clean enough (a subjective assesment), but linux/if.h is particularly tricky as it calls back into the libc headers to get the definition of `struct sockaddr`:

https://github.com/torvalds/linux/blob/22430ae5d90ab288b0ee2ad99ae941f4a666b694/include/uapi/linux/if.h#L28-L30

While that could probably work (I haven't tried), it would make it impossible to control the API exported by our header. Do you think it's still worth it?

https://github.com/llvm/llvm-project/pull/225793


More information about the libc-commits mailing list