usb: gadget: dwc2_udc_otg: return zero when reset property is not present
authorJaehoon Chung <jh80.chung@samsung.com>
Wed, 21 Oct 2020 12:28:41 +0000 (21:28 +0900)
committerJaehoon Chung <jh80.chung@samsung.com>
Wed, 4 Nov 2020 03:19:48 +0000 (12:19 +0900)
If reset DT property is not present, -ENOENT is returned.
But it's not really error.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
drivers/usb/gadget/dwc2_udc_otg.c

index eaa5dcb..df0b30c 100644 (file)
@@ -1045,7 +1045,7 @@ static int dwc2_udc_otg_reset_init(struct udevice *dev,
        int ret;
 
        ret = reset_get_bulk(dev, resets);
-       if (ret == -ENOTSUPP)
+       if (ret == -ENOTSUPP || ret == -ENOENT)
                return 0;
 
        if (ret)