mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Uwe Kleine-König (The Capable Hub)" <u.kleine-koenig@baylibre.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	 linux-kernel@vger.kernel.org, Rob Herring <robh@kernel.org>,
	 Saravana Kannan <saravanak@kernel.org>,
	Bjorn Helgaas <bhelgaas@google.com>,
	 "Rafael J. Wysocki" <rafael@kernel.org>,
	Len Brown <lenb@kernel.org>, Andi Shyti <andi.shyti@kernel.org>,
	 Mark Brown <broonie@kernel.org>
Subject: Re: [PATCH] mod_devicetable.h: Split into per subsystem headers
Date: Wed, 24 Jun 2026 08:31:51 +0200	[thread overview]
Message-ID: <ajt3blZNDW6Zi06x@monoceros> (raw)
In-Reply-To: <ajqutplLwHdECDfd@monoceros>

[-- Attachment #1: Type: text/plain, Size: 2155 bytes --]

Hello,

On Tue, Jun 23, 2026 at 06:13:29PM +0200, Uwe Kleine-König (The Capable Hub) wrote:
> 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@baylibre.com> 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.

Heads up: It's not as easy as anticipated. Two (similar) types of
difficulties I hit are:

 - drivers/platform/x86/msi-ec.c doesn't include
   <linux/mod_devicetable.h> but (e.g.) <linux/acpi.h>. The latter used
   to provide a definition for dmi_device_id. So when replacing
   <linux/mod_devicetable.h> in <linux/acpi.h> by
   <linux/mod_device_id/acpi.h>, drivers/platform/x86/msi-ec.c fails to
   compile due to missing dmi_device_id.

 - <linux/of_platform.h> makes use of resource_size_t. That was defined
   before via <linux/mod_devicetable.h> -> <linux/types.h>, but
   <linux/mod_device_id/of.h> doesn't include <linux/types.h>. Just
   adding that to be sure not to introduce build regessions is sad.

Best regards
Uwe

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2026-06-24  6:31 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-22 21:07 Uwe Kleine-König (The Capable Hub)
2026-06-22 21:49 ` Linus Torvalds
2026-06-23  5:24   ` Greg Kroah-Hartman
2026-06-23  6:40   ` for next: ukleinek/linux.git:device-id-rework [Was: Re: [PATCH] mod_devicetable.h: Split into per subsystem headers] Uwe Kleine-König (The Capable Hub)
2026-06-23 11:12     ` Mark Brown
2026-06-22 22:06 ` [PATCH] mod_devicetable.h: Split into per subsystem headers Linus Torvalds
2026-06-23 14:47   ` Uwe Kleine-König (The Capable Hub)
2026-06-23 14:54     ` Linus Torvalds
2026-06-23 16:13       ` Uwe Kleine-König (The Capable Hub)
2026-06-24  6:31         ` Uwe Kleine-König (The Capable Hub) [this message]
2026-06-24 16:42           ` Linus Torvalds

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ajt3blZNDW6Zi06x@monoceros \
    --to=u.kleine-koenig@baylibre.com \
    --cc=andi.shyti@kernel.org \
    --cc=bhelgaas@google.com \
    --cc=broonie@kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=lenb@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael@kernel.org \
    --cc=robh@kernel.org \
    --cc=saravanak@kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome