aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/phy
diff options
context:
space:
mode:
authorAnton Tikhomirov <av.tikhomirov@samsung.com>2013-12-20 05:06:24 -0500
committerNitin Garg <nitin.garg@freescale.com>2014-04-16 12:02:29 -0400
commite9e2b335eb1d24d953575b3c2245a57e34ae3780 (patch)
treee9ed2399efebb74d4d64a97218b062f8877f9b30 /drivers/usb/phy
parentd111ef70050791756fa3f33bca02a0536942ccad (diff)
usb: phy: Fix double lock in OTG FSM
Mutex obtained at the beginning of the function should be released at the end to avoid double locking. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 16da4b174b08c42076cd3384c420f352c909d467)
Diffstat (limited to 'drivers/usb/phy')
-rw-r--r--drivers/usb/phy/phy-fsm-usb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/phy/phy-fsm-usb.c b/drivers/usb/phy/phy-fsm-usb.c
index 62238726fb1c..65c3a728ef4f 100644
--- a/drivers/usb/phy/phy-fsm-usb.c
+++ b/drivers/usb/phy/phy-fsm-usb.c
@@ -357,7 +357,7 @@ int otg_statemachine(struct otg_fsm *fsm)
357 default: 357 default:
358 break; 358 break;
359 } 359 }
360 mutex_lock(&fsm->lock); 360 mutex_unlock(&fsm->lock);
361 361
362 VDBG("quit statemachine, changed = %d\n", state_changed); 362 VDBG("quit statemachine, changed = %d\n", state_changed);
363 return state_changed; 363 return state_changed;