mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sakari Ailus <sakari.ailus@linux.intel.com>
To: Kate Hsuan <hpa@redhat.com>
Cc: "Tarang Raval" <tarang.raval@siliconsignals.io>,
	"Hans de Goede" <hansg@kernel.org>,
	"Mauro Carvalho Chehab" <mchehab@kernel.org>,
	"Hans Verkuil" <hverkuil+cisco@kernel.org>,
	"Serin Yeh" <serin.yeh@intel.com>,
	"Damjan Georgievski" <gdamjan@gmail.com>,
	"Kieran Bingham" <kieran.bingham@ideasonboard.com>,
	computman <anis@talbi.fr>,
	"linux-media@vger.kernel.org" <linux-media@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Daniel Scally" <dan.scally@ideasonboard.com>,
	"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
	"platform-driver-x86@vger.kernel.org"
	<platform-driver-x86@vger.kernel.org>
Subject: Re: [PATCH v6 3/4] platform: int3472: discrete: con_id vana for Sony IMX471 as power enable
Date: Wed, 8 Jul 2026 12:14:37 +0300	[thread overview]
Message-ID: <ak4U_RTLdWxx07zM@kekkonen.localdomain> (raw)
In-Reply-To: <CAEth8oG_jDMz3Sspayfv18Ue4vO6103fM0J_f_i_NG6tZ7c4XA@mail.gmail.com>

Hi Kate,

On Mon, Jul 06, 2026 at 09:05:08PM +0800, Kate Hsuan wrote:
> Hi Hans, Sakari and Tarang,
> 
> Thank you for your comments.
> 
> On Mon, Jul 6, 2026 at 3:16 PM Tarang Raval
> <tarang.raval@siliconsignals.io> wrote:
> >
> > Hi Sakari,
> >
> > > On Thu, Jul 02, 2026 at 08:05:25PM +0200, Hans de Goede wrote:
> > > > > I went through the INT3472 driver and would like to propose a generic
> > > > > approach that satisfies both sides without per-HID quirks or sensor driver
> > > > > changes.
> > > > >
> > > > > The problem is:
> > > > >  - INT3472 standardizes on "avdd" internally
> > > > >  - Sony IMX sensor drivers use "vana" per datasheet, and all existing
> > > > >    Sony DT bindings (imx219, imx290, imx415) already use vana-supply
> > > > >  - Changing imx471 to "avdd" now will create inconsistency with those
> > > > >    bindings, or require a rename later
> > > >
> > > > Ack, as mentioned in my reply to Sakari from 1 minute ago I'm ok
> > > > with sticking with vana for the imx* case,
> > >
> > > At least some Sony sensors use "INT" PnP vendor prefix and so telling them
> > > apart from the rest doesn't work at least this way. There could also be
> > > other prefixes as well, they're not all "SONY". Right now there is one with
> > > INT prefix and three with SONY prefix.
> > >
> > > If we start having lots of devices with the same quirk, we could also
> > > introduce a pointer to an array of IDs to avoid repeating the same quirk
> > > over and over.
> > >
> > > Kate's patch adds two quirks so this could be already considered (and only
> > > one of these IDs is using SONY prefix).
> 
> The idea may look like
> 
> const char *sony_hids [] = {

I'd call this "power_enable_hids_vana" as other bindings than Sony are also
using vana regulator, e.g. ST and Toshiba.

> "SONY471A",
> "TBE20A0,
> NULL
> };
> 
>  { /* imx471 expects "vana" as con_id for power enable */
>      .hid = sony_hids,   <--- A ponter to sony_hids
>      .type_from = INT3472_GPIO_TYPE_POWER_ENABLE,
>      .type_to = INT3472_GPIO_TYPE_POWER_ENABLE,
>      .con_id = "vana",
>      .enable_time_us = GPIO_REGULATOR_ENABLE_TIME,
>  },
> 
> and
> and the following functions need to be changed.
> Do I understand it correctly?
> 
> Sakari, do you want to implement this approach or could Tarang and I do that?
> 
> >
> > The HID prefix is not actually a concern for the alias idea, because the
> > alias table triggers on supply_name not on HID. Since INT3472 always
> > assigns "avdd" to any POWER_ENABLE GPIO regardless of HID prefix, the
> > alias would work the same for SONY471A, TBE20A0 or any future INTXXXXX
> > prefix.
> >
> > However there is a different problem with the alias idea: it would register
> > both avdd and vana for every sensor that has a POWER_ENABLE GPIO, not just
> > Sony IMX sensors. So I agree this is not a good approach.
> >
> > The NULL-terminated HID array is the correct approach, the mapping is
> > explicit and only applied to hid we explicitly list.
> >
> > I can send a patch implementing this on top of Kate's patch.
> Sounds good.
> If Sakari agree with that, I can include your patch in my series.

Feel free to write a patch. Looks like this series is fine for merging so
I'll pick it later today.

> 
> Thank you :)

Thank you for the series!

-- 
Kind regards,

Sakari Ailus

  reply	other threads:[~2026-07-08  9:14 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-29  7:40 [PATCH v6 0/4] Add Sony IMX471 camera sensor driver Kate Hsuan
2026-06-29  7:40 ` [PATCH v6 1/4] media: ipu-bridge: Add DMI information of Lenovo X9 to the image upside-down list Kate Hsuan
2026-06-29  7:40 ` [PATCH v6 2/4] media: ipu-bridge: Add Sony IMX471 for Lenovo X1 Carbon G14 Kate Hsuan
2026-06-29  7:40 ` [PATCH v6 3/4] platform: int3472: discrete: con_id vana for Sony IMX471 as power enable Kate Hsuan
2026-06-30  7:32   ` Tarang Raval
2026-06-30 13:33     ` Hans de Goede
2026-07-01  6:19       ` Tarang Raval
2026-07-01 11:01         ` Hans de Goede
2026-07-01 11:12           ` Sakari Ailus
2026-07-01 12:33             ` Tarang Raval
2026-07-02 18:05               ` Hans de Goede
2026-07-04 19:16                 ` Sakari Ailus
2026-07-06  7:16                   ` Tarang Raval
2026-07-06 13:05                     ` Kate Hsuan
2026-07-08  9:14                       ` Sakari Ailus [this message]
2026-07-08 12:26                         ` Tarang Raval
2026-07-02 18:01             ` Hans de Goede
2026-06-29  7:40 ` [PATCH v6 4/4] media: i2c: imx471: Add Sony IMX471 image sensor driver 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=ak4U_RTLdWxx07zM@kekkonen.localdomain \
    --to=sakari.ailus@linux.intel.com \
    --cc=anis@talbi.fr \
    --cc=dan.scally@ideasonboard.com \
    --cc=gdamjan@gmail.com \
    --cc=hansg@kernel.org \
    --cc=hpa@redhat.com \
    --cc=hverkuil+cisco@kernel.org \
    --cc=ilpo.jarvinen@linux.intel.com \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=platform-driver-x86@vger.kernel.org \
    --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

all inboxes | Powered by JetHome®