ASoC: fsl: Fix PM disable depth imbalance in fsl_easrc_probe
authorZhang Shurong <zhang_shurong@foxmail.com>
Thu, 12 Oct 2023 13:03:15 +0000 (21:03 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 23 Oct 2023 12:27:13 +0000 (13:27 +0100)
commit9e630efb5a4af56fdb15aa10405f5cfd3f5f5b83
tree98646dd41b96eea7d722eeee72001515af173162
parente8ecffd9962fe051d53a0761921b26d653b3df6b
ASoC: fsl: Fix PM disable depth imbalance in fsl_easrc_probe

The pm_runtime_enable will increase power disable depth. Thus
a pairing decrement is needed on the error handling path to
keep it balanced according to context. We fix it by calling
pm_runtime_disable when error returns.

Fixes: 955ac624058f ("ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers")
Signed-off-by: Zhang Shurong <zhang_shurong@foxmail.com>
Link: https://lore.kernel.org/r/tencent_C0D62E6D89818179A02A04A0C248F0DDC40A@qq.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_easrc.c