]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/hisilicon/hibmc: fix the hibmc loaded failed bug
authorBaihan Li <libaihan@huawei.com>
Wed, 13 Aug 2025 09:42:31 +0000 (17:42 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 28 Aug 2025 14:26:17 +0000 (16:26 +0200)
commitc950e1be3a24d021475b56efdb49daa7fbba63a9
treebd563f8c1ee2437d8b3ff2c816d4276a6665c8a4
parent3570eea2cf0e7e046cecb443a997d44534633a1b
drm/hisilicon/hibmc: fix the hibmc loaded failed bug

[ Upstream commit 93a08f856fcc5aaeeecad01f71bef3088588216a ]

When hibmc loaded failed, the driver use hibmc_unload to free the
resource, but the mutexes in mode.config are not init, which will
access an NULL pointer. Just change goto statement to return, because
hibnc_hw_init() doesn't need to free anything.

Fixes: b3df5e65cc03 ("drm/hibmc: Drop drm_vblank_cleanup")
Signed-off-by: Baihan Li <libaihan@huawei.com>
Signed-off-by: Yongbang Shi <shiyongbang@huawei.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250813094238.3722345-5-shiyongbang@huawei.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c