Re: [PATCHv2 05/12] media: mtk-vcodec: flag OUTPUT formats with V4L2_FMT_FLAG_DYN_RESOLUTION

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Mon 12 Aug 19, 13:05, Hans Verkuil wrote:
> From: Maxime Jourdan <mjourdan@xxxxxxxxxxxx>
> 
> Tag all the coded formats where the mtk-vcodec decoder supports dynamic
> resolution switching.

Looks good to me despite lack of knowledge about the hardware.

Reviewed-by: Paul Kocialkowski <paul.kocialkowski@xxxxxxxxxxx>

Cheers,

Paul

> Signed-off-by: Maxime Jourdan <mjourdan@xxxxxxxxxxxx>
> Signed-off-by: Hans Verkuil <hverkuil-cisco@xxxxxxxxx>
> ---
>  drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c | 4 ++++
>  drivers/media/platform/mtk-vcodec/mtk_vcodec_drv.h | 1 +
>  2 files changed, 5 insertions(+)
> 
> diff --git a/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c b/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c
> index 90d1a67db7e5..26a55c3e807e 100644
> --- a/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c
> +++ b/drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c
> @@ -29,16 +29,19 @@ static const struct mtk_video_fmt mtk_video_formats[] = {
>  		.fourcc = V4L2_PIX_FMT_H264,
>  		.type = MTK_FMT_DEC,
>  		.num_planes = 1,
> +		.flags = V4L2_FMT_FLAG_DYN_RESOLUTION,
>  	},
>  	{
>  		.fourcc = V4L2_PIX_FMT_VP8,
>  		.type = MTK_FMT_DEC,
>  		.num_planes = 1,
> +		.flags = V4L2_FMT_FLAG_DYN_RESOLUTION,
>  	},
>  	{
>  		.fourcc = V4L2_PIX_FMT_VP9,
>  		.type = MTK_FMT_DEC,
>  		.num_planes = 1,
> +		.flags = V4L2_FMT_FLAG_DYN_RESOLUTION,
>  	},
>  	{
>  		.fourcc = V4L2_PIX_FMT_MT21C,
> @@ -948,6 +951,7 @@ static int vidioc_enum_fmt(struct v4l2_fmtdesc *f, bool output_queue)
>  
>  	fmt = &mtk_video_formats[i];
>  	f->pixelformat = fmt->fourcc;
> +	f->flags = fmt->flags;
>  
>  	return 0;
>  }
> diff --git a/drivers/media/platform/mtk-vcodec/mtk_vcodec_drv.h b/drivers/media/platform/mtk-vcodec/mtk_vcodec_drv.h
> index c95de5d08dda..9fd56dee7fd1 100644
> --- a/drivers/media/platform/mtk-vcodec/mtk_vcodec_drv.h
> +++ b/drivers/media/platform/mtk-vcodec/mtk_vcodec_drv.h
> @@ -99,6 +99,7 @@ struct mtk_video_fmt {
>  	u32	fourcc;
>  	enum mtk_fmt_type	type;
>  	u32	num_planes;
> +	u32	flags;
>  };
>  
>  /**
> -- 
> 2.20.1
> 

-- 
Paul Kocialkowski, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux