mbox series

[v1,0/5] media: imx-mipi-csis: Move to subdev active state

Message ID 20230126213437.20796-1-laurent.pinchart@ideasonboard.com
Headers show
Series media: imx-mipi-csis: Move to subdev active state | expand

Message

Laurent Pinchart Jan. 26, 2023, 9:34 p.m. UTC
Hello,

This small series moves the imx-mipi-csis driver to use the subdev
active state. Patches 1/5 to 3/5 are small preparatory cleanups, with
the main change in 4/5. Patch 5/5 is further cleanup that could have
been included in 4/5, but that should be easier to review as a separate
patch.

The series has been tested on the i.MX8MP with the ISI, and IMX296 and
IMX327 camera sensors.

Laurent Pinchart (5):
  media: imx-mipi-csis: Rename error labels with 'err_' prefix
  media: imx-mipi-csis: Don't take lock in runtime PM handlers
  media: imx-mipi-csis: Pass format explicitly to internal functions
  media: imx-mipi-csis: Use V4L2 subdev active state
  media: imx-mipi-csis: Implement .init_cfg() using .set_fmt()

 drivers/media/platform/nxp/imx-mipi-csis.c | 249 +++++++++------------
 1 file changed, 103 insertions(+), 146 deletions(-)

Comments

Adam Ford Jan. 27, 2023, 1:54 a.m. UTC | #1
On Thu, Jan 26, 2023 at 3:34 PM Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
>
> Hello,
>
> This small series moves the imx-mipi-csis driver to use the subdev
> active state. Patches 1/5 to 3/5 are small preparatory cleanups, with
> the main change in 4/5. Patch 5/5 is further cleanup that could have
> been included in 4/5, but that should be easier to review as a separate
> patch.
>
> The series has been tested on the i.MX8MP with the ISI, and IMX296 and
> IMX327 camera sensors.

I didn't notice any overall change in the CSIS capture on the imx8mn.
I can test the Mini if you want.

For the series:
Tested-by: Adam Ford <aford173@gmail.com> #imx8mn-beacon

adam
>
> Laurent Pinchart (5):
>   media: imx-mipi-csis: Rename error labels with 'err_' prefix
>   media: imx-mipi-csis: Don't take lock in runtime PM handlers
>   media: imx-mipi-csis: Pass format explicitly to internal functions
>   media: imx-mipi-csis: Use V4L2 subdev active state
>   media: imx-mipi-csis: Implement .init_cfg() using .set_fmt()
>
>  drivers/media/platform/nxp/imx-mipi-csis.c | 249 +++++++++------------
>  1 file changed, 103 insertions(+), 146 deletions(-)
>
> --
> Regards,
>
> Laurent Pinchart
>
Laurent Pinchart Jan. 27, 2023, 2:29 a.m. UTC | #2
Hi Adam,

On Thu, Jan 26, 2023 at 07:54:10PM -0600, Adam Ford wrote:
> On Thu, Jan 26, 2023 at 3:34 PM Laurent Pinchart wrote:
> >
> > Hello,
> >
> > This small series moves the imx-mipi-csis driver to use the subdev
> > active state. Patches 1/5 to 3/5 are small preparatory cleanups, with
> > the main change in 4/5. Patch 5/5 is further cleanup that could have
> > been included in 4/5, but that should be easier to review as a separate
> > patch.
> >
> > The series has been tested on the i.MX8MP with the ISI, and IMX296 and
> > IMX327 camera sensors.
> 
> I didn't notice any overall change in the CSIS capture on the imx8mn.
> I can test the Mini if you want.

That would be great. Would you be able to test it in conjunction with
the similar imx7-media-csi series I've just sent ([1]) ? I expect a
possible lockdep warning if this series is applied with the
corresponding change in imx7-media-csi, but together they should be
fine.

[1] https://lore.kernel.org/linux-media/20230127022715.27234-1-laurent.pinchart@ideasonboard.com

> For the series:
> Tested-by: Adam Ford <aford173@gmail.com> #imx8mn-beacon
> 
> > Laurent Pinchart (5):
> >   media: imx-mipi-csis: Rename error labels with 'err_' prefix
> >   media: imx-mipi-csis: Don't take lock in runtime PM handlers
> >   media: imx-mipi-csis: Pass format explicitly to internal functions
> >   media: imx-mipi-csis: Use V4L2 subdev active state
> >   media: imx-mipi-csis: Implement .init_cfg() using .set_fmt()
> >
> >  drivers/media/platform/nxp/imx-mipi-csis.c | 249 +++++++++------------
> >  1 file changed, 103 insertions(+), 146 deletions(-)
Adam Ford Jan. 27, 2023, 3:05 a.m. UTC | #3
On Thu, Jan 26, 2023 at 8:29 PM Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
>
> Hi Adam,
>
> On Thu, Jan 26, 2023 at 07:54:10PM -0600, Adam Ford wrote:
> > On Thu, Jan 26, 2023 at 3:34 PM Laurent Pinchart wrote:
> > >
> > > Hello,
> > >
> > > This small series moves the imx-mipi-csis driver to use the subdev
> > > active state. Patches 1/5 to 3/5 are small preparatory cleanups, with
> > > the main change in 4/5. Patch 5/5 is further cleanup that could have
> > > been included in 4/5, but that should be easier to review as a separate
> > > patch.
> > >
> > > The series has been tested on the i.MX8MP with the ISI, and IMX296 and
> > > IMX327 camera sensors.
> >
> > I didn't notice any overall change in the CSIS capture on the imx8mn.
> > I can test the Mini if you want.
>
> That would be great. Would you be able to test it in conjunction with
> the similar imx7-media-csi series I've just sent ([1]) ? I expect a
> possible lockdep warning if this series is applied with the
> corresponding change in imx7-media-csi, but together they should be
> fine.

I am working on figuring out why my mini doesn't boot, but I've
already taken the CSIS series and the imx7-media-csi series and
applied them to my working branch.  I'll report my findings as soon as
I can get it booting.

adam
>
> [1] https://lore.kernel.org/linux-media/20230127022715.27234-1-laurent.pinchart@ideasonboard.com
>
> > For the series:
> > Tested-by: Adam Ford <aford173@gmail.com> #imx8mn-beacon
> >
> > > Laurent Pinchart (5):
> > >   media: imx-mipi-csis: Rename error labels with 'err_' prefix
> > >   media: imx-mipi-csis: Don't take lock in runtime PM handlers
> > >   media: imx-mipi-csis: Pass format explicitly to internal functions
> > >   media: imx-mipi-csis: Use V4L2 subdev active state
> > >   media: imx-mipi-csis: Implement .init_cfg() using .set_fmt()
> > >
> > >  drivers/media/platform/nxp/imx-mipi-csis.c | 249 +++++++++------------
> > >  1 file changed, 103 insertions(+), 146 deletions(-)
>
> --
> Regards,
>
> Laurent Pinchart
Rui Miguel Silva Jan. 31, 2023, 9:28 a.m. UTC | #4
Hey Laurent,
Thanks for all the cleanups and updates.

Laurent Pinchart <laurent.pinchart@ideasonboard.com> writes:

> Hello,
>
> This small series moves the imx-mipi-csis driver to use the subdev
> active state. Patches 1/5 to 3/5 are small preparatory cleanups, with
> the main change in 4/5. Patch 5/5 is further cleanup that could have
> been included in 4/5, but that should be easier to review as a separate
> patch.
>
> The series has been tested on the i.MX8MP with the ISI, and IMX296 and
> IMX327 camera sensors.
>
> Laurent Pinchart (5):
>   media: imx-mipi-csis: Rename error labels with 'err_' prefix
>   media: imx-mipi-csis: Don't take lock in runtime PM handlers
>   media: imx-mipi-csis: Pass format explicitly to internal functions
>   media: imx-mipi-csis: Use V4L2 subdev active state
>   media: imx-mipi-csis: Implement .init_cfg() using .set_fmt()

LGTM, for the all series.

Acked-by: Rui Miguel Silva <rmfrfs@gmail.com>

Cheers,
    Rui

>
>  drivers/media/platform/nxp/imx-mipi-csis.c | 249 +++++++++------------
>  1 file changed, 103 insertions(+), 146 deletions(-)
>
> -- 
> Regards,
>
> Laurent Pinchart