More thoughts about ioctl and kernel ABIs in general

H. Peter Anvin hpa@zytor.com
Fri Jul 11 22:19:47 GMT 2025


On 2025-07-11 10:26, H. Peter Anvin wrote:
> 
> After I spent a good chuck of yesterday hacking on this, I think there is a *lot* to be said for the snapshot model, for the simple reason that it allows for more powerful preprocessing tools – notably Coccinelle, which in turns depends on Ocaml – to be used than one can realistically expect to require as build dependencies, and of course it allows inspection of the resulting output, minimizing the risk of external breakage.
> 
> If there is a perception it would be too much churn then it is also, of course, possible to make glibc-kheaders a separate package with more frequent distribution.
> 
> I have already written up a set of scripts to automate the creation of a panarchitectural set of kernel uapi headers produced by running headers_install for each architecture and merging identical files into a common directory hierarchy. The cocci and Perl scripts I posted this morning feel like a very reasonable starting point for the requisite header mangling, too, even though I ran into some annoying limitations in Coccinelle which at least based on my limited knowledge of cocci's
> SpML language required me to add some redundant rules, but it is not a huge problem either.
> 
> I will set up an experimental git tree for these scripts later today.
> 

A set of scripts are now up. They are *very* much not complete, but I 
thought I'd post them to give a flavor of what can be done.

https://git.zytor.com/linux/uapi/

	-hpa



More information about the Libc-alpha mailing list