From: Li Jun Date: Sat, 27 Sep 2014 14:34:58 +0000 (+0800) Subject: MLK-9617-10 usb: common: otg: update condition from a_host to a_suspend X-Git-Tag: C0P2-H0.0--20200415~4649 X-Git-Url: https://git.somdevices.com/?a=commitdiff_plain;h=e68aa02448e484ce751bb6717cd65205542d18c7;p=linux.git MLK-9617-10 usb: common: otg: update condition from a_host to a_suspend This patch updates condition from a_host to a_suspend according to On-The-Go and Embedded Host Supplement to the USB Revision 2.0 Specification Revision 2.0 version 1.1a. Signed-off-by: Li Jun (cherry picked from commit f3acf74150683d4555c82ad32b9c669d8a0a7fb5) (cherry picked from commit a938eb1ccabe9213c0b232d45da2caeb75f8b9fe) --- diff --git a/drivers/usb/common/usb-otg-fsm.c b/drivers/usb/common/usb-otg-fsm.c index 0f34224c8604..b117f5bb3459 100644 --- a/drivers/usb/common/usb-otg-fsm.c +++ b/drivers/usb/common/usb-otg-fsm.c @@ -438,8 +438,7 @@ int otg_statemachine(struct otg_fsm *fsm) case OTG_STATE_A_HOST: if (fsm->id || fsm->a_bus_drop) otg_set_state(fsm, OTG_STATE_A_WAIT_VFALL); - else if ((!fsm->a_bus_req || fsm->a_suspend_req_inf) && - fsm->otg->host->b_hnp_enable) + else if (!fsm->a_bus_req || fsm->a_suspend_req_inf) otg_set_state(fsm, OTG_STATE_A_SUSPEND); else if (!fsm->b_conn) otg_set_state(fsm, OTG_STATE_A_WAIT_BCON);