Message ID | 20230418071439.197735-3-alexander.stein@ew.tq-group.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Fix imx7-media-csi format settings | expand |
Hi Alexander, Thank you for the patch. On Tue, Apr 18, 2023 at 09:14:38AM +0200, Alexander Stein wrote: > Interlaced mode is currently not supported, so disable fields in try_fmt. > > Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com> > --- > drivers/media/platform/nxp/imx7-media-csi.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/media/platform/nxp/imx7-media-csi.c b/drivers/media/platform/nxp/imx7-media-csi.c > index bd649fd9166fd..1508f6ba20e91 100644 > --- a/drivers/media/platform/nxp/imx7-media-csi.c > +++ b/drivers/media/platform/nxp/imx7-media-csi.c > @@ -1178,6 +1178,7 @@ __imx7_csi_video_try_fmt(struct v4l2_pix_format *pixfmt, You should also drop the following code in the same function: /* Allow IDMAC interweave but enforce field order from source. */ if (V4L2_FIELD_IS_INTERLACED(pixfmt->field)) { switch (pixfmt->field) { case V4L2_FIELD_SEQ_TB: pixfmt->field = V4L2_FIELD_INTERLACED_TB; break; case V4L2_FIELD_SEQ_BT: pixfmt->field = V4L2_FIELD_INTERLACED_BT; break; default: break; } } > stride = round_up((pixfmt->width * cc->bpp) / 8, 8); > pixfmt->bytesperline = stride; > pixfmt->sizeimage = stride * pixfmt->height; > + pixfmt->field = V4L2_FIELD_NONE; > > if (compose) { > compose->width = pixfmt->width;
diff --git a/drivers/media/platform/nxp/imx7-media-csi.c b/drivers/media/platform/nxp/imx7-media-csi.c index bd649fd9166fd..1508f6ba20e91 100644 --- a/drivers/media/platform/nxp/imx7-media-csi.c +++ b/drivers/media/platform/nxp/imx7-media-csi.c @@ -1178,6 +1178,7 @@ __imx7_csi_video_try_fmt(struct v4l2_pix_format *pixfmt, stride = round_up((pixfmt->width * cc->bpp) / 8, 8); pixfmt->bytesperline = stride; pixfmt->sizeimage = stride * pixfmt->height; + pixfmt->field = V4L2_FIELD_NONE; if (compose) { compose->width = pixfmt->width;
Interlaced mode is currently not supported, so disable fields in try_fmt. Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com> --- drivers/media/platform/nxp/imx7-media-csi.c | 1 + 1 file changed, 1 insertion(+)