drm/mediatek: component type MTK_DISP_OVL_2L is not correctly handled
Subsystems (3)
PATCH 1/1 drm/mediatek: component type MTK_DISP_OVL_2L is not correctly handled
The larb device remains NULL if the type is MTK_DISP_OVL_2L. A kernel panic is raised when a crtc uses mtk_smi_larb_get or mtk_smi_larb_put.
--- drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c +1 -0
@@ -471,6 +471,7 @@ int mtk_ddp_comp_init(struct device *dev, struct device_node *node,/* Only DMA capable components need the LARB property */ comp->larb_dev =NULL ;if (type !=MTK_DISP_OVL && + type !=MTK_DISP_OVL_2L && type !=MTK_DISP_RDMA && type !=MTK_DISP_WDMA )return 0 ;
Signature · 1 line
2.17.1
Hi, Phong:
Quoted 4 lines · Phong LE
The larb device remains NULL if the type is
MTK_DISP_OVL_2L. A kernel panic is raised when a crtc usesmtk_smi_larb_getormtk_smi_larb_put.
Quoted 10 lines
Signed-off-by Phong LE <[email protected]>--- drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 1 + 1 file changed, 1 insertion(+)drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c +0
-0
drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c int mtk_ddp_comp_init(struct device *dev, struct device_node *node, · line 477
Quoted 7 lines
drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c +1
-0@@ -471,6 +471,7 @@ int mtk_ddp_comp_init(struct device *dev, struct device_node *node,/* Only DMA capable components need the LARB property */ comp->larb_dev =NULL ;if (type !=MTK_DISP_OVL && + type !=MTK_DISP_OVL_2L && type !=MTK_DISP_RDMA && type !=MTK_DISP_WDMA )return 0 ;
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
CK Hu
AppliedHi, Phong:
Quoted 10 lines · CK Hu
Hi, Phong:
Quoted 4 lines · Phong LE
The larb device remains NULL if the type is
MTK_DISP_OVL_2L. A kernel panic is raised when a crtc usesmtk_smi_larb_getormtk_smi_larb_put.Reviewed-by CK Hu <[email protected]>
Applied to mediatek-drm-fixes-5.6 [1], thanks.
[1]
https://github.com/ckhu-mediatek/linux.git-tags/commits/mediatek-drm-fixes-5.6
Regards,
CK
Quoted 18 lines
Quoted 17 lines
Signed-off-by Phong LE <[email protected]>--- drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 1 + 1 file changed, 1 insertion(+)drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c +1
-0@@ -471,6 +471,7 @@ int mtk_ddp_comp_init(struct device *dev, struct device_node *node,/* Only DMA capable components need the LARB property */ comp->larb_dev =NULL ;if (type !=MTK_DISP_OVL && + type !=MTK_DISP_OVL_2L && type !=MTK_DISP_RDMA && type !=MTK_DISP_WDMA )return 0 ;