Re: [PATCH 16/21] ASoC: wm8955: Move regulator acquisition to the i2c probe
From: Charles Keepax
Date: Mon Sep 21 2026 - 07:33:11 EST
On Mon, Sep 21, 2026 at 07:46:35PM +0900, Chancel Liu wrote:
> From: Chancel Liu <chancel.liu@xxxxxxx>
>
> component->dev is the underlying i2c device whose devres is only
> released on physical device removal, not on ASoC card unbind. Getting
> the regulator supplies with devm_regulator_bulk_get(component->dev, ...)
> in the component probe therefore leaks the regulator references on every
> card bind/unbind cycle.
>
> Move the devm_regulator_bulk_get() to the i2c probe so the supplies are
> tied to the physical device lifetime.
>
> Signed-off-by: Chancel Liu <chancel.liu@xxxxxxx>
> ---
Reviewed-by: Charles Keepax <ckeepax@xxxxxxxxxxxxxxxxxxxxx>
Thanks,
Charles