diff options
Diffstat (limited to 'drivers/usb/otg/ab8500-usb.c')
-rw-r--r-- | drivers/usb/otg/ab8500-usb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/otg/ab8500-usb.c b/drivers/usb/otg/ab8500-usb.c index d6e83a4d671..d6b71fcfcfe 100644 --- a/drivers/usb/otg/ab8500-usb.c +++ b/drivers/usb/otg/ab8500-usb.c @@ -689,7 +689,7 @@ static int ab8500_usb_set_peripheral(struct usb_otg *otg, * Do not update ab8500 registers directly till this * is fixed. */ - if (!gadget) + if (!gadget && ab->mode == USB_PERIPHERAL) schedule_work(&ab->phy_dis_work); return 0; @@ -710,7 +710,7 @@ static int ab8500_usb_set_host(struct usb_otg *otg, struct usb_bus *host) * Do not update ab8500 registers directly till this * is fixed. */ - if (!host) + if (!host && ab->mode == USB_HOST) schedule_work(&ab->phy_dis_work); return 0; |