]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - drivers/usb/musb-new/sunxi.c
musb: Allow musb_platform_enable to return an error code
[karo-tx-uboot.git] / drivers / usb / musb-new / sunxi.c
index 052e0657d03d22261f9951a13c9295cc119c395b..c123d61af2c3d274b76d7395b9e4460b257624ec 100644 (file)
@@ -199,12 +199,12 @@ static irqreturn_t sunxi_musb_interrupt(int irq, void *__hci)
 /* musb_core does not call enable / disable in a balanced manner <sigh> */
 static bool enabled = false;
 
-static void sunxi_musb_enable(struct musb *musb)
+static int sunxi_musb_enable(struct musb *musb)
 {
        pr_debug("%s():\n", __func__);
 
        if (enabled)
-               return;
+               return 0;
 
        /* select PIO mode */
        musb_writeb(musb->mregs, USBC_REG_o_VEND0, 0);
@@ -215,6 +215,7 @@ static void sunxi_musb_enable(struct musb *musb)
        USBC_ForceVbusValidToHigh(musb->mregs);
 
        enabled = true;
+       return 0;
 }
 
 static void sunxi_musb_disable(struct musb *musb)