+ if (DWC3_GCTL_PRTCAP(reg) == DWC3_GCTL_PRTCAP_DEVICE) {
+ ret = readx_poll_timeout(atomic_read,
+ &dwc->dev->power.usage_count,
+ val,
+ val < 2 && !dwc->connected,
+ 1000,
+ PERIPHERAL_DISCONNECT_TIMEOUT);
+ if (ret < 0) {
+ rockchip->skip_suspend = true;
+ dev_warn(rockchip->dev, "Peripheral disconnect timeout\n");
+ }
+ }
+
+ if (!rockchip->skip_suspend) {
+ pm_runtime_put_sync_suspend(dwc->dev);
+ pm_runtime_put_sync_suspend(rockchip->dev);
+ }