提交 8a440b09 编写于 作者: P Paul Kocialkowski 提交者: Hans de Goede

sunxi: musb: Return early on VBUS GPIO error instead of on a positive value

This allows printing the error message when VBUS is detected, as it would with
AXP VBUS detect.
Signed-off-by: NPaul Kocialkowski <contact@paulk.fr>
Acked-by: NHans de Goede <hdegoede@redhat.com>
Signed-off-by: NHans de Goede <hdegoede@redhat.com>
上级 21866c34
......@@ -261,7 +261,7 @@ static int sunxi_musb_init(struct musb *musb)
}
err = gpio_get_value(vbus_det);
if (err) {
if (err < 0) {
gpio_free(vbus_det);
return -EIO;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册