[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <43e118c9-0bc6-d85d-2f86-e74f833e1e8a@infradead.org>
Date: Sat, 3 Oct 2020 09:50:14 -0700
From: Randy Dunlap <rdunlap@...radead.org>
To: Alexandre Courbot <acourbot@...omium.org>,
Tiffany Lin <tiffany.lin@...iatek.com>,
Andrew-CT Chen <andrew-ct.chen@...iatek.com>,
Sakari Ailus <sakari.ailus@...ux.intel.com>,
Tomasz Figa <tfiga@...omium.org>
Cc: Hans Verkuil <hverkuil-cisco@...all.nl>,
linux-media@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-mediatek@...ts.infradead.org
Subject: Re: [PATCH] media: mtk-vcodec: fix builds when remoteproc is disabled
On 10/3/20 6:09 AM, Alexandre Courbot wrote:
> The addition of MT8183 support added a dependency on the SCP remoteproc
> module. However the initial patch used the "select" Kconfig directive,
> which may result in the SCP module to not be compiled if remoteproc was
> disabled. In such a case, mtk-vcodec would try to link against
> non-existent SCP symbols. "select" was clearly misused here as explained
> in kconfig-language.txt.
>
> Replace this by a "depends" directive on at least one of the VPU and
> SCP modules, to allow the driver to be compiled as long as one of these
> is enabled, and adapt the code to support this new scenario.
>
> Also adapt the Kconfig text to explain the extra requirements for MT8173
> and MT8183.
>
> Reported-by: Sakari Ailus <sakari.ailus@...ux.intel.com>
> Signed-off-by: Alexandre Courbot <acourbot@...omium.org>
I was seeing this also, so I checked this patch. WFM.
Acked-by: Randy Dunlap <rdunlap@...radead.org> # build-tested
See below.
> ---
> drivers/media/platform/Kconfig | 11 +--
> .../media/platform/mtk-vcodec/mtk_vcodec_fw.c | 72 ++++++++++++-------
> 2 files changed, 55 insertions(+), 28 deletions(-)
>
> diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig
> index a3cb104956d5..e559d9c529b6 100644
> --- a/drivers/media/platform/Kconfig
> +++ b/drivers/media/platform/Kconfig
> @@ -253,14 +253,17 @@ config VIDEO_MEDIATEK_VCODEC
> depends on MTK_IOMMU || COMPILE_TEST
> depends on VIDEO_DEV && VIDEO_V4L2
> depends on ARCH_MEDIATEK || COMPILE_TEST
> + depends on VIDEO_MEDIATEK_VPU || MTK_SCP
> select VIDEOBUF2_DMA_CONTIG
> select V4L2_MEM2MEM_DEV
> - select VIDEO_MEDIATEK_VPU
> - select MTK_SCP
> help
> Mediatek video codec driver provides HW capability to
> - encode and decode in a range of video formats
> - This driver rely on VPU driver to communicate with VPU.
> + encode and decode in a range of video formats on MT8173
> + and MT8183.
> +
> + Note that support for support for MT8173 requires
Drop one of "support for" above. (or "for support" ;)
> + VIDEO_MEDIATEK_VPU to also be selected. Support for
> + MT8183 depends on MTK_SCP.
>
> To compile this driver as modules, choose M here: the
> modules will be called mtk-vcodec-dec and mtk-vcodec-enc.
thanks.
--
~Randy
Powered by blists - more mailing lists