[PATCH v2 00/18] media: mtk-vcodec: venc: support for MT8183 and v4l2-compliance fixes
From: Alexandre Courbot
Date: Fri Jun 26 2020 - 04:05:32 EST
This is the second revision of the series adding support for the MT8183 encoder
(patches 1-9). It also fixes 9 v4l2-compliance failures (patches 10-18). Of note
is patch 10 which reverts a previous patch that seems to have been merged by
mistake (see https://lore.kernel.org/linux-media/CAPBb6MWuhJGq_etJN4WX0NOBXK0cA7rxVCMx70xCg7Uzmj_cMw@xxxxxxxxxxxxxx/T/#me1b4a97adb119c25dc79826d49746216dd94bd26).
As mentioned in v1's discussion, this time v4l2-compliance has been run before
and after each patch to make sure no regressions are introduced. The latest
v4l2-compliance does find quite a few errors on the current mainline though, and
the second half of this series fixes several of them.
After this series the following v4l2-compliance failures remain:
* VIDIOC_(TRY_)ENCODER_CMD fails because there is no support for encoder
commands. I have a patch fixing this but it depends on some extra refactoring
introduced by the decoder series (that will follow this one), so it will be
submitted along with it.
* VIDIOC_(UN)SUBSCRIBE_EVENT/DQEVENT also fails because one cannot subscribe to
the EOS event. This depends on encoder commands to be properly sent, so the
fix will also follow.
Changes since v1:
* Checked that no regressions against v4l2-compliance were introduced,
* Fixed 9 failing v4l2-compliance tests,
* Removed 1 cleanup patch of contested utility,
* Carried Acked-bys and Reviewed-bys from mtk-vcodec maintainer.
Alexandre Courbot (14):
media: mtk-vcodec: venc: handle firmware version field
media: mtk-vcodec: venc: specify bitrate range per-chip
media: mtk-vcodec: venc: specify supported formats per-chip
media: dt-bindings: mtk-vcodec: specify SCP node
media: dt-bindings: mtk-vcodec: document mediatek,mt8183-vcodec-enc
Revert "media: mtk-vcodec: Remove extra area allocation in an input
buffer on encoding"
media: mtk-vcodec: venc support MIN_OUTPUT_BUFFERS control
media: mtk-vcodec: venc: set OUTPUT buffers field to V4L2_FIELD_NONE
media: mtk-vcodec: venc: use platform data for ENUM_FRAMESIZES
media: mtk-vcodec: venc: support ENUM_FRAMESIZES on OUTPUT formats
media: mtk-vcodec: venc: support G_PARM on CAPTURE queue
media: mtk-vcodec: venc: make S_PARM return -ENOTTY for CAPTURE queue
media: mtk-vcodec: venc: set default time per frame
media: mtk-vcodec: venc: fix invalid time per frame in S_PARM
Yunfei Dong (4):
media: mtk-vcodec: abstract firmware interface
media: mtk-vcodec: add SCP firmware ops
media: mtk-vcodec: venc: support SCP firmware
media: mtk-vcodec: add support for MT8183 encoder
.../bindings/media/mediatek-vcodec.txt | 9 +-
drivers/media/platform/Kconfig | 1 +
drivers/media/platform/mtk-vcodec/Makefile | 4 +-
.../platform/mtk-vcodec/mtk_vcodec_dec_drv.c | 53 ++--
.../platform/mtk-vcodec/mtk_vcodec_dec_pm.c | 1 -
.../platform/mtk-vcodec/mtk_vcodec_drv.h | 38 ++-
.../platform/mtk-vcodec/mtk_vcodec_enc.c | 217 ++++++++---------
.../platform/mtk-vcodec/mtk_vcodec_enc_drv.c | 149 ++++++++----
.../platform/mtk-vcodec/mtk_vcodec_enc_pm.c | 2 -
.../media/platform/mtk-vcodec/mtk_vcodec_fw.c | 228 ++++++++++++++++++
.../media/platform/mtk-vcodec/mtk_vcodec_fw.h | 38 +++
.../platform/mtk-vcodec/mtk_vcodec_util.c | 1 -
.../platform/mtk-vcodec/vdec/vdec_h264_if.c | 1 -
.../platform/mtk-vcodec/vdec/vdec_vp8_if.c | 1 -
.../platform/mtk-vcodec/vdec/vdec_vp9_if.c | 1 -
.../media/platform/mtk-vcodec/vdec_drv_base.h | 2 -
.../media/platform/mtk-vcodec/vdec_drv_if.c | 1 -
.../media/platform/mtk-vcodec/vdec_vpu_if.c | 12 +-
.../media/platform/mtk-vcodec/vdec_vpu_if.h | 11 +-
.../platform/mtk-vcodec/venc/venc_h264_if.c | 80 ++++--
.../platform/mtk-vcodec/venc/venc_vp8_if.c | 11 +-
.../media/platform/mtk-vcodec/venc_drv_if.c | 1 -
.../media/platform/mtk-vcodec/venc_drv_if.h | 6 +
.../media/platform/mtk-vcodec/venc_ipi_msg.h | 24 +-
.../media/platform/mtk-vcodec/venc_vpu_if.c | 141 ++++++++---
.../media/platform/mtk-vcodec/venc_vpu_if.h | 8 +-
26 files changed, 760 insertions(+), 281 deletions(-)
create mode 100644 drivers/media/platform/mtk-vcodec/mtk_vcodec_fw.c
create mode 100644 drivers/media/platform/mtk-vcodec/mtk_vcodec_fw.h
--
2.27.0.212.ge8ba1cc988-goog