Re: [PATCH v2] soc: qcom: ubwc: Fix link error when QCOM_SMEM=n

Dmitry Baryshkov <[email protected]>
Newsgroups dev.linux.lists.imx,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-kernel
Message-ID <eptix3j7cqs6mhbk5ano3y6nhsl7r6fhrkfz5dpollvkpnu7wh@uy7y6txd27q5>
On Tue, Aug 11, 2026 at 06:19:05PM +0300, Daniel Baluta wrote:
> DRM_MSM unconditionally selects QCOM_UBWC_CONFIG, which calls SMEM APIs,
> causing a link error on non-Qcom platforms (e.g. SOC_IMX5):
> 
>   arm-linux-gnueabihf-ld: ubwc_config.c:(.text+0x2c): undefined
>       reference to 'qcom_smem_is_available'
>   arm-linux-gnueabihf-ld: ubwc_config.c:(.text+0x4c): undefined
>       reference to 'qcom_smem_dram_get_hbb'
> 
> Relax the selection of QCOM_UBWC_CONFIG to ARCH_QCOM only and make QCOM_UBWC_CONFIG
> depend on QCOM_SMEM make the requirement explicit.
> 
> Fixes: 1b445022d1d0 ("soc: qcom: ubwc: Get HBB from SMEM")
> Signed-off-by: Daniel Baluta <[email protected]>
> ---
> Changes since v1:
> - (addressed feedback from Dmitry) replace adding static inline stubs with preparing a better config
>   dependecies so that we use the qcom_smem symbols only on QCOM platforms.
> - Link to v1: https://lore.kernel.org/imx/sy2ulk536ryakhy6fdnqr4asvzvufqk3dlo2awdrfomulyf4n4@qtp4qoazqmhj/T/#t
> 
>  drivers/gpu/drm/msm/Kconfig | 2 +-
>  drivers/soc/qcom/Kconfig    | 1 +
>  2 files changed, 2 insertions(+), 1 deletion(-)
> 

Reviewed-by: Dmitry Baryshkov <[email protected]>


-- 
With best wishes
Dmitry
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.