2020-03-26 13:46:44

by Neil Armstrong

[permalink] [raw]
Subject: [PATCH v2 05/14] usb: dwc3: meson-g12a: check return of dwc3_meson_g12a_usb_init

The dwc3_meson_g12a_usb_init function can return an error, check it.

Fixes: e3e716e6b889 ("usb: dwc3: Add Amlogic A1 DWC3 glue")
Signed-off-by: Neil Armstrong <[email protected]>
---
drivers/usb/dwc3/dwc3-meson-g12a.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/usb/dwc3/dwc3-meson-g12a.c b/drivers/usb/dwc3/dwc3-meson-g12a.c
index 41bcbd31fe4e..69381c42a6d3 100644
--- a/drivers/usb/dwc3/dwc3-meson-g12a.c
+++ b/drivers/usb/dwc3/dwc3-meson-g12a.c
@@ -588,7 +588,9 @@ static int dwc3_meson_g12a_probe(struct platform_device *pdev)
/* Get dr_mode */
priv->otg_mode = usb_get_dr_mode(dev);

- dwc3_meson_g12a_usb_init(priv);
+ ret = dwc3_meson_g12a_usb_init(priv);
+ if (ret)
+ goto err_disable_clks;

/* Init PHYs */
for (i = 0 ; i < PHY_COUNT ; ++i) {
--
2.22.0


2020-03-26 22:58:39

by Martin Blumenstingl

[permalink] [raw]
Subject: Re: [PATCH v2 05/14] usb: dwc3: meson-g12a: check return of dwc3_meson_g12a_usb_init

On Thu, Mar 26, 2020 at 2:45 PM Neil Armstrong <[email protected]> wrote:
>
> The dwc3_meson_g12a_usb_init function can return an error, check it.
>
> Fixes: e3e716e6b889 ("usb: dwc3: Add Amlogic A1 DWC3 glue")
I think this should be:
Fixes: c99993376f72ca ("usb: dwc3: Add Amlogic G12A DWC3 glue")
(because I don't see where e3e716e6b889 modifies dwc3_meson_g12a_usb_init)

> Signed-off-by: Neil Armstrong <[email protected]>
and with that:
Reviewed-by: Martin Blumenstingl <[email protected]>


Martin