usb: otg: cpcap: Allow suspend in host mode
authorBenoit Goby <benoit@android.com>
Tue, 28 Dec 2010 23:32:45 +0000 (15:32 -0800)
committerBenoit Goby <benoit@android.com>
Fri, 7 Jan 2011 02:18:52 +0000 (18:18 -0800)
Change-Id: I6e96aef913e8b1da4f84c594d426cb05d7e940d7
Signed-off-by: Benoit Goby <benoit@android.com>
drivers/usb/otg/cpcap-otg.c

index 28e83dfda0353007123885867b259799c71c9784..108705f437c03413cfaf0bf9018d011b139c8a95 100644 (file)
@@ -131,7 +131,7 @@ static int cpcap_otg_notify(struct notifier_block *nb, unsigned long event,
                return 0;
        otg->state = to;
 
-       if (to != OTG_STATE_A_SUSPEND)
+       if (to == OTG_STATE_B_PERIPHERAL)
                wake_lock(&cpcap->wake_lock);
 
        dev_info(cpcap->otg.dev, "%s --> %s", cpcap_state_name(from),