OSDN Git Service

media: mediatek: vcodec: Add mt8188 encoder driver
authorIrui Wang <irui.wang@mediatek.com>
Wed, 20 Jul 2022 08:57:28 +0000 (10:57 +0200)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Tue, 30 Aug 2022 12:31:06 +0000 (14:31 +0200)
Add mt8188's compatible "mediatek,mt8188-vcodec-enc".
Add mt8188's device private data "mt8188_pdata".

Signed-off-by: Irui Wang <irui.wang@mediatek.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc_drv.c

index 95e8c29..ea667b8 100644 (file)
@@ -406,6 +406,18 @@ static const struct mtk_vcodec_enc_pdata mt8183_pdata = {
        .core_id = VENC_SYS,
 };
 
+static const struct mtk_vcodec_enc_pdata mt8188_pdata = {
+       .uses_ext = true,
+       .capture_formats = mtk_video_formats_capture_h264,
+       .num_capture_formats = ARRAY_SIZE(mtk_video_formats_capture_h264),
+       .output_formats = mtk_video_formats_output,
+       .num_output_formats = ARRAY_SIZE(mtk_video_formats_output),
+       .min_bitrate = 64,
+       .max_bitrate = 50000000,
+       .core_id = VENC_SYS,
+       .uses_34bit = true,
+};
+
 static const struct mtk_vcodec_enc_pdata mt8192_pdata = {
        .uses_ext = true,
        .capture_formats = mtk_video_formats_capture_h264,
@@ -434,6 +446,7 @@ static const struct of_device_id mtk_vcodec_enc_match[] = {
        {.compatible = "mediatek,mt8173-vcodec-enc-vp8",
                        .data = &mt8173_vp8_pdata},
        {.compatible = "mediatek,mt8183-vcodec-enc", .data = &mt8183_pdata},
+       {.compatible = "mediatek,mt8188-vcodec-enc", .data = &mt8188_pdata},
        {.compatible = "mediatek,mt8192-vcodec-enc", .data = &mt8192_pdata},
        {.compatible = "mediatek,mt8195-vcodec-enc", .data = &mt8195_pdata},
        {},