Commit 2743becb authored by Dan Carpenter's avatar Dan Carpenter Committed by Mark Yao

drm/rockchip: inno_hdmi: fix an error code

We were accidentally returning PTR_ERR(NULL) which means success when we
wanted to return a negative error code.

Fixes: 412d4ae6 ('drm/rockchip: hdmi: add Innosilicon HDMI support')
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: default avatarYakir Yang <ykk@rock-chips.com>
parent 69b00796
......@@ -855,8 +855,9 @@ static int inno_hdmi_bind(struct device *dev, struct device *master,
hdmi->ddc = inno_hdmi_i2c_adapter(hdmi);
if (IS_ERR(hdmi->ddc)) {
ret = PTR_ERR(hdmi->ddc);
hdmi->ddc = NULL;
return PTR_ERR(hdmi->ddc);
return ret;
}
/*
......
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