This will ignore any SESSREQ interrupt if musb is B state.
Charger detection may cause spurious SESSREQ interrupts.
Signed-off-by: Heikki Krogerus <ext-heikki.krogerus@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
if (int_usb & MUSB_INTR_SESSREQ) {
void __iomem *mbase = musb->mregs;
+ if (devctl & MUSB_DEVCTL_BDEVICE) {
+ DBG(3, "SessReq while on B state\n");
+ return IRQ_HANDLED;
+ }
+
DBG(1, "SESSION_REQUEST (%s)\n", otg_state_string(musb));
/* IRQ arrives from ID pin sense or (later, if VBUS power