mbox series

[v2,0/8] media: nxp: imx7-media-csi: Move to subdev active state

Message ID 20230129023429.22467-1-laurent.pinchart@ideasonboard.com
Headers show
Series media: nxp: imx7-media-csi: Move to subdev active state | expand

Message

Laurent Pinchart Jan. 29, 2023, 2:34 a.m. UTC
Hello,

This small series moves the imx7-mipi-csi driver to use the subdev
active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
the main change in 8/8.

Compared to v1, I've now successfully tested the series on an i.MX8MM.
The issues reported by Adam have been resolved by adding patch 7/8 and
fixing a problem in 8/8.

Laurent Pinchart (8):
  media: imx: imx7-media-csi: Drop imx7_csi.cc field
  media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
  media: imx: imx7-media-csi: Drop unneeded check when starting
    streaming
  media: imx: imx7-media-csi: Drop unneeded src_sd check
  media: imx: imx7-media-csi: Drop unneeded pad checks
  media: imx: imx7-media-csi: Cleanup errors in
    imx7_csi_async_register()
  media: imx: imx7-media-csi: Zero format struct before calling
    .get_fmt()
  media: imx: imx7-media-csi: Use V4L2 subdev active state

 drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++--------------
 1 file changed, 70 insertions(+), 165 deletions(-)

Comments

Adam Ford Jan. 30, 2023, 11:45 p.m. UTC | #1
On Sat, Jan 28, 2023 at 8:34 PM Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
>
> Hello,
>
> This small series moves the imx7-mipi-csi driver to use the subdev
> active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
> the main change in 8/8.
>
> Compared to v1, I've now successfully tested the series on an i.MX8MM.
> The issues reported by Adam have been resolved by adding patch 7/8 and
> fixing a problem in 8/8.
>
> Laurent Pinchart (8):
>   media: imx: imx7-media-csi: Drop imx7_csi.cc field
>   media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
>   media: imx: imx7-media-csi: Drop unneeded check when starting
>     streaming
>   media: imx: imx7-media-csi: Drop unneeded src_sd check
>   media: imx: imx7-media-csi: Drop unneeded pad checks
>   media: imx: imx7-media-csi: Cleanup errors in
>     imx7_csi_async_register()
>   media: imx: imx7-media-csi: Zero format struct before calling
>     .get_fmt()
>   media: imx: imx7-media-csi: Use V4L2 subdev active state
>

Thanks for the V2!  It works nicely along with the CSIS updates you
posted before.

For the series,

Tested-by: Adam Ford <aford173@gmail.com> #imx8mm-beacon-kit

>  drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++--------------
>  1 file changed, 70 insertions(+), 165 deletions(-)
>
> --
> Regards,
>
> Laurent Pinchart
>
Rui Miguel Silva Jan. 31, 2023, 9:30 a.m. UTC | #2
Hi Laurent,
Also thanks for the work on updating this one.

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

> Hello,
>
> This small series moves the imx7-mipi-csi driver to use the subdev
> active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
> the main change in 8/8.
>
> Compared to v1, I've now successfully tested the series on an i.MX8MM.
> The issues reported by Adam have been resolved by adding patch 7/8 and
> fixing a problem in 8/8.
>
> Laurent Pinchart (8):
>   media: imx: imx7-media-csi: Drop imx7_csi.cc field
>   media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
>   media: imx: imx7-media-csi: Drop unneeded check when starting
>     streaming
>   media: imx: imx7-media-csi: Drop unneeded src_sd check
>   media: imx: imx7-media-csi: Drop unneeded pad checks
>   media: imx: imx7-media-csi: Cleanup errors in
>     imx7_csi_async_register()
>   media: imx: imx7-media-csi: Zero format struct before calling
>     .get_fmt()
>   media: imx: imx7-media-csi: Use V4L2 subdev active state

LGTM, for the all series.

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

Cheers,
  Rui

>
>  drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++--------------
>  1 file changed, 70 insertions(+), 165 deletions(-)
>
> -- 
> Regards,
>
> Laurent Pinchart
Martin Kepplinger Jan. 31, 2023, 10:17 a.m. UTC | #3
Am Sonntag, dem 29.01.2023 um 04:34 +0200 schrieb Laurent Pinchart:
> Hello,
> 
> This small series moves the imx7-mipi-csi driver to use the subdev
> active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
> the main change in 8/8.
> 
> Compared to v1, I've now successfully tested the series on an
> i.MX8MM.
> The issues reported by Adam have been resolved by adding patch 7/8
> and
> fixing a problem in 8/8.
> 
> Laurent Pinchart (8):
>   media: imx: imx7-media-csi: Drop imx7_csi.cc field
>   media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
>   media: imx: imx7-media-csi: Drop unneeded check when starting
>     streaming
>   media: imx: imx7-media-csi: Drop unneeded src_sd check
>   media: imx: imx7-media-csi: Drop unneeded pad checks
>   media: imx: imx7-media-csi: Cleanup errors in
>     imx7_csi_async_register()
>   media: imx: imx7-media-csi: Zero format struct before calling
>     .get_fmt()
>   media: imx: imx7-media-csi: Use V4L2 subdev active state
> 
>  drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++------------
> --
>  1 file changed, 70 insertions(+), 165 deletions(-)
> 

hi Laurent, what tree did you base this on? onto v6.2-rc6 I have a
change missing: in imx7_csi_video_validate_fmt(), before calling
v4l2_subdev_call_state_active(), there's fmt_src.pad and fmt_src.which
assigned. I don't have that.

thanks
                            martin
Laurent Pinchart Jan. 31, 2023, 10:24 a.m. UTC | #4
Hi Martin,

On Tue, Jan 31, 2023 at 11:17:46AM +0100, Martin Kepplinger wrote:
> Am Sonntag, dem 29.01.2023 um 04:34 +0200 schrieb Laurent Pinchart:
> > Hello,
> > 
> > This small series moves the imx7-mipi-csi driver to use the subdev
> > active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
> > the main change in 8/8.
> > 
> > Compared to v1, I've now successfully tested the series on an
> > i.MX8MM.
> > The issues reported by Adam have been resolved by adding patch 7/8
> > and
> > fixing a problem in 8/8.
> > 
> > Laurent Pinchart (8):
> >   media: imx: imx7-media-csi: Drop imx7_csi.cc field
> >   media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
> >   media: imx: imx7-media-csi: Drop unneeded check when starting
> >     streaming
> >   media: imx: imx7-media-csi: Drop unneeded src_sd check
> >   media: imx: imx7-media-csi: Drop unneeded pad checks
> >   media: imx: imx7-media-csi: Cleanup errors in
> >     imx7_csi_async_register()
> >   media: imx: imx7-media-csi: Zero format struct before calling
> >     .get_fmt()
> >   media: imx: imx7-media-csi: Use V4L2 subdev active state
> > 
> >  drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++------------
> > --
> >  1 file changed, 70 insertions(+), 165 deletions(-)
> > 
> 
> hi Laurent, what tree did you base this on? onto v6.2-rc6 I have a
> change missing: in imx7_csi_video_validate_fmt(), before calling
> v4l2_subdev_call_state_active(), there's fmt_src.pad and fmt_src.which
> assigned. I don't have that.

The patches are based on top of the master branch fo
git://linuxtv.org/media_stage.git. I've pushed my branches to
git://git.kernel.org/pub/scm/linux/kernel/git/pinchartl/linux.git (named
next/media/imx-csis and next/media/imx-csi).
Martin Kepplinger Jan. 31, 2023, 11:18 a.m. UTC | #5
Am Sonntag, dem 29.01.2023 um 04:34 +0200 schrieb Laurent Pinchart:
> Hello,
> 
> This small series moves the imx7-mipi-csi driver to use the subdev
> active state. Patches 1/8 to 7/8 are small preparatory cleanups, with
> the main change in 8/8.
> 
> Compared to v1, I've now successfully tested the series on an
> i.MX8MM.
> The issues reported by Adam have been resolved by adding patch 7/8
> and
> fixing a problem in 8/8.
> 
> Laurent Pinchart (8):
>   media: imx: imx7-media-csi: Drop imx7_csi.cc field
>   media: imx: imx7-media-csi: Simplify imx7_csi_video_init_format()
>   media: imx: imx7-media-csi: Drop unneeded check when starting
>     streaming
>   media: imx: imx7-media-csi: Drop unneeded src_sd check
>   media: imx: imx7-media-csi: Drop unneeded pad checks
>   media: imx: imx7-media-csi: Cleanup errors in
>     imx7_csi_async_register()
>   media: imx: imx7-media-csi: Zero format struct before calling
>     .get_fmt()
>   media: imx: imx7-media-csi: Use V4L2 subdev active state
> 
>  drivers/media/platform/nxp/imx7-media-csi.c | 235 ++++++------------
> --
>  1 file changed, 70 insertions(+), 165 deletions(-)
> 

thanks Laurent,

Tested-by: Martin Kepplinger <martin.kepplinger@puri.sm>

                    martin