From: "Mark Pearson" <mpearson@squebb.ca>
To: "Sakari Ailus" <sakari.ailus@linux.intel.com>,
"Damjan Georgievski" <gdamjan@gmail.com>
Cc: "Kate Hsuan" <hpa@redhat.com>,
"Mauro Carvalho Chehab" <mchehab@kernel.org>,
"Hans de Goede" <johannes.goede@oss.qualcomm.com>,
"Hans Verkuil" <hverkuil+cisco@kernel.org>,
"Serin Yeh" <serin.yeh@intel.com>,
"Tarang Raval" <tarang.raval@siliconsignals.io>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 1/3] media: ipu-bridge: Add DMI information of Lenovo X9 to the image upside-down list
Date: Thu, 11 Jun 2026 10:54:45 -0400 [thread overview]
Message-ID: <9aaa21ad-6332-4dd4-9b78-6520af6a8619@app.fastmail.com> (raw)
In-Reply-To: <aiqtsFbFR9SZSDeL@kekkonen.localdomain>
On Thu, Jun 11, 2026, at 8:44 AM, Sakari Ailus wrote:
> Hi Damjan,
>
> On Thu, Jun 11, 2026 at 11:41:19AM +0200, Damjan Georgievski wrote:
>> On Thu, 11 Jun 2026 at 10:24, Sakari Ailus <sakari.ailus@linux.intel.com> wrote:
>> >
>> > Hi Kate,
>> >
>> > On Thu, Jun 11, 2026 at 03:25:46PM +0800, Kate Hsuan wrote:
>> > > Hi Sakari and Mark,
>> > >
>> > > On Thu, Jun 11, 2026 at 5:59 AM Sakari Ailus
>> > > <sakari.ailus@linux.intel.com> wrote:
>> > > >
>> > > > Hi Kate,
>> > > >
>> > > > I know several people have given you different advices but...
>> > > >
>> > > > On Tue, Jun 09, 2026 at 08:49:24PM +0800, Kate Hsuan wrote:
>> > > > > The Lenovo X9 has an upside-down-mounted Sony IMX471 sensor so the image
>> > > > > was displayed upside-down. Add the DMI information of Lenovo X9 to
>> > > > > resolve the issue.
>> > > > >
>> > > > > Signed-off-by: Kate Hsuan <hpa@redhat.com>
>> > > > > ---
>> > > > > drivers/media/pci/intel/ipu-bridge.c | 32 ++++++++++++++++++++++++++++
>> > > > > 1 file changed, 32 insertions(+)
>> > > > >
>> > > > > diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c
>> > > > > index fc6608e33de4..9e24aaceecdf 100644
>> > > > > --- a/drivers/media/pci/intel/ipu-bridge.c
>> > > > > +++ b/drivers/media/pci/intel/ipu-bridge.c
>> > > > > @@ -134,6 +134,38 @@ static const struct dmi_system_id upside_down_sensor_dmi_ids[] = {
>> > > > > },
>> > > > > .driver_data = "OVTI02C1",
>> > > > > },
>> > > > > + {
>> > > > > + /* Lenovo X9-14 */
>> > > > > + .matches = {
>> > > > > + DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
>> > > > > + DMI_MATCH(DMI_BOARD_NAME, "21QA"),
>> > > > > + },
>> > > > > + .driver_data = "SONY471A",
>> > > > > + },
>> > > > > + {
>> > > > > + /* Lenovo X9-14 */
>> > > >
>> > > > How are the two X9-14's different? It'd be good to have some comment here
>> > > > which model this actually is: the board name is only available (typically
>> > > > at least) in DMI.
>> > >
>> > > According to the datasheet of X9-14 and 15. Lenovo offers 2 screen
>> > > sizes (14-inch and 15-inch) and 2 CPU types (Core Ultra 5 and 7).
>> >
>> > Is the CPU SKU the difference here? If so, can you add that to the comment?
>> >
>> > > They may ship customised firmware for a specific purpose with a random
>> > > DMI_PRODUCT_VERSION.
>> > > So, using the DMI_BOARD_NAME prefix to identify the laptop SKU is
>> > > safer and easier.
>> > >
>> > > I think DMI_MATCH(DMI_BOARD_NAME, "21Q") covers all X9 but I don't
>> > > know the side effect :(
>> > > They may propose a new model with a different MIPI camera or HID.
>> >
>> > Indeed. Is the BOARD_NAME guaranteed to be unique by Lenovo? I think I'd
>> > use DMI_EXACT_MATCH(), too.
>>
>> The full board_name is 21QA0048RM (on mine), so 21QA is just the prefix.
>> The lenovo support site only requires this prefix to get you to the
>> support page for the laptops and they refer to it as "Type 21QA".
>>
>> Is there DMI_MATCH_PREFIX, for these (if not all) Thinkpads it might
>> make the most sense ?
>
> DMI_MATCH() only matches for prefix whereas DMI_EXACT_MATCH() requires an
> exact match.
>
There are two BOARD_NAME's for every Thinkpad (which one your system has depends on the channel thru which the platform is sold).
The first 4 chars are the important bit - they are defined and won't change (they are used internally here). The rest of the BOARD_NAME is based on the config and can vary.
I'm not so sure on the PRODUCT_VERSION I'm afraid which is why I'm hesitant to use it, even though doing the match on two IDs is annoying. I'm trying to confirm if it's a good idea or not.
A useful trick, for released platforms, is to go to https://psref.lenovo.com and type your platform in the search bar and it will come up with the match and also list the two board codes.
So if you put in X9-14 you should see 21QA and 21QB - these are the two DMI matches you would need to do (X9-15 uses 21Q6 & 21Q7)
Don't do a match on 21Q - that will definitely match up with other platforms that won't want this change.
Hope that helps
Mark
next prev parent reply other threads:[~2026-06-11 14:55 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-09 12:49 [PATCH v4 0/3] Add Sony IMX471 camera sensor driver Kate Hsuan
2026-06-09 12:49 ` [PATCH v4 1/3] media: ipu-bridge: Add DMI information of Lenovo X9 to the image upside-down list Kate Hsuan
2026-06-10 21:59 ` Sakari Ailus
2026-06-11 7:25 ` Kate Hsuan
2026-06-11 8:24 ` Sakari Ailus
2026-06-11 9:41 ` Damjan Georgievski
2026-06-11 12:44 ` Sakari Ailus
2026-06-11 14:54 ` Mark Pearson [this message]
2026-06-12 6:58 ` Kate Hsuan
2026-06-11 9:42 ` Kate Hsuan
2026-06-11 12:42 ` Sakari Ailus
2026-06-09 12:49 ` [PATCH v4 2/3] media: ipu-bridge: Add Sony IMX471 for Lenovo X1 Carbon G14 Kate Hsuan
2026-06-09 12:49 ` [PATCH v4 3/3] media: i2c: imx471: Add Sony IMX471 image sensor driver Kate Hsuan
2026-06-10 7:11 ` Tarang Raval
2026-06-10 22:14 ` Sakari Ailus
2026-06-11 5:35 ` Tarang Raval
2026-06-11 6:38 ` Sakari Ailus
2026-06-11 6:46 ` Kate Hsuan
2026-06-11 7:29 ` Tarang Raval
2026-06-10 22:11 ` Sakari Ailus
2026-06-11 6:56 ` Kate Hsuan
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=9aaa21ad-6332-4dd4-9b78-6520af6a8619@app.fastmail.com \
--to=mpearson@squebb.ca \
--cc=gdamjan@gmail.com \
--cc=hpa@redhat.com \
--cc=hverkuil+cisco@kernel.org \
--cc=johannes.goede@oss.qualcomm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=serin.yeh@intel.com \
--cc=tarang.raval@siliconsignals.io \
/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