Commit 86e77a1f authored by Bo-Chen Chen's avatar Bo-Chen Chen Committed by Dmitry Osipenko

drm/mediatek: dp: Determine device of next_bridge

It's not necessary to have a next_bridge for DP device, so we add this
patch to judge this.
Signed-off-by: default avatarBo-Chen Chen <rex-bc.chen@mediatek.com>
Reviewed-by: default avatarCK Hu <ck.hu@mediatek.com>
Tested-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: default avatarDmitry Osipenko <dmitry.osipenko@collabora.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220901044149.16782-8-rex-bc.chen@mediatek.com
parent 16075ed1
......@@ -1886,7 +1886,10 @@ static int mtk_dp_probe(struct platform_device *pdev)
"failed to request dp irq resource\n");
mtk_dp->next_bridge = devm_drm_of_get_bridge(dev, dev->of_node, 1, 0);
if (IS_ERR(mtk_dp->next_bridge))
if (IS_ERR(mtk_dp->next_bridge) &&
PTR_ERR(mtk_dp->next_bridge) == -ENODEV)
mtk_dp->next_bridge = NULL;
else if (IS_ERR(mtk_dp->next_bridge))
return dev_err_probe(dev, PTR_ERR(mtk_dp->next_bridge),
"Failed to get bridge\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment