Re: [PATCH v4 3/3] media: i2c: imx471: Add Sony IMX471 image sensor driver

From: Sakari Ailus

Date: Wed Jun 10 2026 - 18:15:09 EST


Hi Tarang, Kate,

On Wed, Jun 10, 2026 at 07:11:39AM +0000, Tarang Raval wrote:
> > + /* V4L2 controls values will be applied only when power is already up */
> > + if (!pm_runtime_get_if_in_use(sensor->dev))
>
> Use pm_runtime_get_if_active() or update the comment. With pm_runtime_get_if_in_use(),
> the comment should say "applied only when the device is in use".

Using pm_runtime_get_if_active() would allow more sparing I²C writes, which
I understand the driver always does in enable_streams(). It's not a bug
though.

> > +static const struct acpi_device_id imx471_acpi_ids[] __maybe_unused = {
> > + { "SONY471A" },
> > + { "TBE20A0" },
> > + { /* sentinel */ }
> > +};
> > +MODULE_DEVICE_TABLE(acpi, imx471_acpi_ids);
> > +
> > +static struct i2c_driver imx471_i2c_driver = {
> > + .driver = {
> > + .name = "imx471",
> > + .acpi_match_table = ACPI_PTR(imx471_acpi_ids),
>
> Could you please add .of_match_table as well? The driver can also be used
> on DT-based systems.

I'd leave this up to someone who needs this to work on DT. It'd require
bindings, too, and the support wouldn't be testable at this time anyway.

--
Regards,

Sakari Ailus