Re: [PATCH] mod_devicetable.h: Split into per subsystem headers

From: Uwe Kleine-König (The Capable Hub)

Date: Tue Jun 23 2026 - 12:13:43 EST


Hello Linus,

On Tue, Jun 23, 2026 at 07:54:12AM -0700, Linus Torvalds wrote:
> On Tue, 23 Jun 2026 at 07:47, Uwe Kleine-König (The Capable Hub)
> <u.kleine-koenig@xxxxxxxxxxxx> wrote:
> >
> > So in the end I expect a handful of driver patches plus switching the
> > the most important (or maybe all) <linux/$something.h>s from
> > <linux/mod_devicetable.h> to <linux/mod_device_id/$something>.
> >
> > I guess that is ok then, too?
>
> Sure, that sounds fine. I was expecting lots of files to include the
> mod_device_id/xyz.h files by hand, since that's what currently happens
> with that mod_devicetable.h file:
>
> $ git grep linux/mod_devicetable.h | wc -l
> 1621

These are mostly .c files. Currently I'm concentrating on the header
files only:

$ find -name \*.h | xargs grep linux/mod_devicetable.h | wc -l
91

For these the effort-impact ratio is much better. Agreed that for .c
files your script approach sounds right. Up to now I wasn't aware that
there are that many .c files including <linux/mod_devicetable.h>
directly.

Assuming I create such a script, what would be the approach to apply the
resulting patch? Do you want to run and commit after -rc1? The
alternative would be to submit a patch per subsystem.

> but if it turns out that 99% of those can be subsumed by just the
> normal device header includes, then that's all the better.
>
> Because what I _didn't_ want to see was some "manually fixed up 1600
> files, followed by a month of build failure reports for random
> configs".

Ack.

Best regards
Uwe

Attachment: signature.asc
Description: PGP signature