phy: phy-core: remove mutex lock for rockchip rv1126-usb2phy calibrate

For RV1126, phy_calibrate will run in dwc3 reset irq function and lead
to dead lock. Besides, there is no critical area resources. So we should
remove mutex lock in phy calibrate for Rockchip platform.

Signed-off-by: Ren Jianing <jianing.ren@rock-chips.com>
Change-Id: Ic205959d96e7a6831aa9426738c1fd06deee1a22
This commit is contained in:
Ren Jianing
2021-01-28 11:26:05 +08:00
committed by Tao Huang
parent 66605ab268
commit ec70606fce

View File

@@ -399,6 +399,13 @@ int phy_calibrate(struct phy *phy)
if (!phy || !phy->ops->calibrate)
return 0;
if (phy->dev.parent &&
of_device_is_compatible(phy->dev.parent->of_node,
"rockchip,rv1126-usb2phy")) {
ret = phy->ops->calibrate(phy);
return ret;
}
mutex_lock(&phy->mutex);
ret = phy->ops->calibrate(phy);
mutex_unlock(&phy->mutex);