The runtime power management of sdcc can be controlled by userspace with auto/on modes by writing into /sys/devices/platform/msm_sdcc.1/power/control entry. "auto" mode allows runtime pm suspend to happen. "on" mode forbids runtime suspend of sdcc and also take care of resuming the device if already suspended. During this resume process there is a deadlock as described below: o User writes "on" into control parameter. o The sysfs write triggers a rpm_resume() (assume sdcc is already suspended, hence rpm_resume() tries to wake it up). o rpm_resume() -> msmsdcc_runtime_resume() -> mmc_claim_host() -> msmsdcc_enable() -> pm_runtime_get_sync() -> rpm_resume() -> wait for previous rpm_resume() completion which cause deadlock. CRs-Fixed: 372071 Change-Id: I0f666b56b6db98b182b8fc828588b476fd4eef6a Signed-off-by: Sujit Reddy Thumma <sthumma@codeaurora.org>