Re: [PATCH] ASoC: codecs: lpass-rx-macro: fix PM ref leak in swclk_gate_enable

From: Prasad Kumpatla

Date: Thu Oct 29 2026 - 13:35:04 EST



On 10/28/2026 5:15 PM, Tang Bin wrote:
swclk_gate_enable() calls pm_runtime_resume_and_get() (incrementing the PM
usage counter and, via of_pm_clk_add_clks, enabling mclk) before
rx_macro_mclk_enable(). On rx_macro_mclk_enable() failure it called
clk_disable_unprepare(rx->mclk) and returned, leaking the PM usage counter
and potentially unbalancing the clock that the PM clock domain also
manages. The sibling tx-macro/va-macro drivers call
pm_runtime_put_autosuspend() here; do the same.

Fixes: e38cbb75248a ("ASoC: codecs: lpass-rx-macro: Propagate regcache_sync() errors")
Signed-off-by: Tang Bin <tangbin@xxxxxxxxxxxxxxxxxxxx>

LGTM,

Reviewed-by: Prasad Kumpatla<prasad.kumpatla@xxxxxxxxxxxxxxxx>

Thanks,
Prasad