]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/tegra: dsi: Add missing check for of_find_device_by_node
authorChen Ni <nichen@iscas.ac.cn>
Tue, 24 Oct 2023 08:07:38 +0000 (08:07 +0000)
committerSasha Levin <sashal@kernel.org>
Tue, 26 Mar 2024 22:19:41 +0000 (18:19 -0400)
commit52aa507148c4aad41436e2005d742ffcafad9976
tree27650f2d9c569ffc0295c93201da2e90f6fee66b
parent15a3fc5c8774c17589dabfe1d642d40685c985af
drm/tegra: dsi: Add missing check for of_find_device_by_node

[ Upstream commit afe6fcb9775882230cd29b529203eabd5d2a638d ]

Add check for the return value of of_find_device_by_node() and return
the error if it fails in order to avoid NULL pointer dereference.

Fixes: e94236cde4d5 ("drm/tegra: dsi: Add ganged mode support")
Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231024080738.825553-1-nichen@iscas.ac.cn
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/tegra/dsi.c