linux/drivers/gpu/drm/mediatek
Javier Carrasco 576fe9345d drm/mediatek: Fix child node refcount handling in early exit
commit f708e8b4cf upstream.

Early exits (goto, break, return) from for_each_child_of_node() required
an explicit call to of_node_put(), which was not introduced with the
break if cnt == MAX_CRTC.

Add the missing of_node_put() before the break.

Cc: stable@vger.kernel.org
Fixes: d761b9450e ("drm/mediatek: Add cnt checking for coverity issue")

Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
Reviewed-by: CK Hu <ck.hu@mediatek.com>
Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://patchwork.kernel.org/project/dri-devel/patch/20241011-mtk_drm_drv_memleak-v1-1-2b40c74c8d75@gmail.com/
Signed-off-by: Chun-Kuang Hu <chunkuang.hu@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2024-12-09 10:41:13 +01:00
..
Kconfig drm/bridge-connector: move to DRM_DISPLAY_HELPER module 2024-09-03 10:18:31 +02:00
Makefile drm/mediatek: Rename files "mtk_drm_gem.c" to "mtk_gem.c" 2024-04-01 15:35:43 +00:00
mtk_cec.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_cec.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
mtk_crtc.c drm/mediatek: Fix potential NULL dereference in mtk_crtc_destroy() 2024-10-23 14:09:13 +00:00
mtk_crtc.h drm/mediatek: Rename files "mtk_drm_plane.h" to "mtk_plane.h" 2024-04-01 15:30:26 +00:00
mtk_ddp_comp.c drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_ddp_comp.h drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_disp_aal.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_disp_ccorr.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_disp_color.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_disp_drv.h drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_disp_gamma.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_disp_merge.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_disp_ovl.c drm/mediatek: Fix color format MACROs in OVL 2024-10-22 12:50:51 +00:00
mtk_disp_ovl_adaptor.c drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_disp_rdma.c drm/mediatek: Drop unnecessary check for property presence 2024-08-29 14:26:14 +00:00
mtk_dp.c drm/mediatek: Fix get efuse issue for MT8188 DPTX 2024-10-23 14:00:56 +00:00
mtk_dp_reg.h drm/mediatek: dp: Add support MT8188 dp/edp function 2023-09-24 14:00:23 +00:00
mtk_dpi.c drm/mediatek: dpi/dsi: Fix possible_crtcs calculation 2024-06-28 12:25:18 +00:00
mtk_dpi_regs.h drm/mediatek: dpi: Add dp_intf support 2022-07-06 22:51:44 +08:00
mtk_drm_drv.c drm/mediatek: Fix child node refcount handling in early exit 2024-12-09 10:41:13 +01:00
mtk_drm_drv.h drm/mediatek: Set DRM mode configs accordingly 2024-06-20 13:57:36 +00:00
mtk_dsi.c drm/mediatek: dsi: Add dsi per-frame lp code for mt8188 2024-08-29 14:27:09 +00:00
mtk_ethdr.c drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_ethdr.h drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_gem.c The usual shower of singleton fixes and minor series all over MM, 2024-05-19 09:21:03 -07:00
mtk_gem.h drm/mediatek: Rename files "mtk_drm_gem.h" to "mtk_gem.h" 2024-04-01 15:33:52 +00:00
mtk_hdmi.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_hdmi.h drm/mediatek: Separate mtk_hdmi_phy to an independent module 2020-09-06 07:02:54 +08:00
mtk_hdmi_ddc.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_hdmi_regs.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
mtk_mdp_rdma.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_mdp_rdma.h drm/mediatek: Add display MDP RDMA support for MT8195 2022-06-27 22:24:14 +08:00
mtk_padding.c drm/mediatek: Log errors in probe with dev_err_probe() 2024-06-27 14:03:49 +00:00
mtk_plane.c drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00
mtk_plane.h drm/mediatek: Add blend_modes to mtk_plane_init() for different SoCs 2024-10-22 12:47:47 +00:00