summaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorBob Liu <lliubbo@gmail.com>2010-10-23 05:12:00 -0500
committerFelipe Balbi <balbi@ti.com>2010-11-05 14:12:22 +0200
commit68f64714dc35a515a3064b300729e7809bcdd0e0 (patch)
tree114f55a2d481851b2ffa9be6e3b107e1d0c4629b /drivers/usb
parent1e393c6eece048052d4131ec4dad3b98e35a98e2 (diff)
downloadlinux-68f64714dc35a515a3064b300729e7809bcdd0e0.tar.bz2
USB: musb: blackfin: fix dynamic device<->host changing
We need to restart the timer in order to recognize USB devices in host-only mode. Signed-off-by: Bob Liu <lliubbo@gmail.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/musb/blackfin.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/usb/musb/blackfin.c b/drivers/usb/musb/blackfin.c
index 32cc6d927760..ade45a219c47 100644
--- a/drivers/usb/musb/blackfin.c
+++ b/drivers/usb/musb/blackfin.c
@@ -171,8 +171,9 @@ static irqreturn_t blackfin_interrupt(int irq, void *__hci)
}
/* Start sampling ID pin, when plug is removed from MUSB */
- if (is_otg_enabled(musb) && (musb->xceiv->state == OTG_STATE_B_IDLE
- || musb->xceiv->state == OTG_STATE_A_WAIT_BCON)) {
+ if ((is_otg_enabled(musb) && (musb->xceiv->state == OTG_STATE_B_IDLE
+ || musb->xceiv->state == OTG_STATE_A_WAIT_BCON)) ||
+ (musb->int_usb & MUSB_INTR_DISCONNECT && is_host_active(musb))) {
mod_timer(&musb_conn_timer, jiffies + TIMER_DELAY);
musb->a_wait_bcon = TIMER_DELAY;
}