Commit e6cf7e98 authored by Wei Yongjun's avatar Wei Yongjun Committed by Daniel Vetter

drm: mxsfb: fix error return code in mxsfb_load()

Fix to return a negative error code from the error handling
case instead of 0, as done elsewhere in this function.
Signed-off-by: default avatarWei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20170205160036.7364-1-weiyj.lk@gmail.com
parent 612fb5d9
...@@ -221,6 +221,7 @@ static int mxsfb_load(struct drm_device *drm, unsigned long flags) ...@@ -221,6 +221,7 @@ static int mxsfb_load(struct drm_device *drm, unsigned long flags)
mxsfb->fbdev = drm_fbdev_cma_init(drm, 32, mxsfb->fbdev = drm_fbdev_cma_init(drm, 32,
drm->mode_config.num_connector); drm->mode_config.num_connector);
if (IS_ERR(mxsfb->fbdev)) { if (IS_ERR(mxsfb->fbdev)) {
ret = PTR_ERR(mxsfb->fbdev);
mxsfb->fbdev = NULL; mxsfb->fbdev = NULL;
dev_err(drm->dev, "Failed to init FB CMA area\n"); dev_err(drm->dev, "Failed to init FB CMA area\n");
goto err_cma; goto err_cma;
......
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