提交 eb393dbc 编写于 作者: F Fabio Estevam 提交者: Benjamin Gaignard

drm/stm: ltdc: Remove unnecessary platform_get_resource() error check

devm_ioremap_resource() already checks if the resource is NULL, so
remove the unnecessary platform_get_resource() error check.

Cc: Philippe Cornu <philippe.cornu@st.com>
Signed-off-by: NFabio Estevam <fabio.estevam@nxp.com>
Acked-by: NPhilippe Cornu <philippe.cornu@st.com>
Signed-off-by: NBenjamin Gaignard <benjamin.gaignard@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/1513602150-7542-6-git-send-email-festevam@gmail.com
上级 6cf7e40b
......@@ -901,12 +901,6 @@ int ltdc_load(struct drm_device *ddev)
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
if (!res) {
DRM_ERROR("Unable to get resource\n");
ret = -ENODEV;
goto err;
}
ldev->regs = devm_ioremap_resource(dev, res);
if (IS_ERR(ldev->regs)) {
DRM_ERROR("Unable to get ltdc registers\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册