Re: [PATCH 2/2] phy: qcom-qmp: fix reset-controller leak on probe errors

Philipp Zabel
2022-04-25T09:45:47Z

Hi Johan,

On Fr, 2022-04-22 at 15:09 +0200, Johan Hovold wrote:
> Make sure to release the lane reset controller in case of a late probe
> error (e.g. probe deferral).

Right. grepping for "of_reset_control_get", there seem to be are a few
other drivers that might share the same issue...

> Note that due to the reset controller being defined in devicetree in
> (questionable) "lane" child nodes, devm_reset_control_get_exclusive()
> cannot be used (and we shouldn't add devres helpers for the legacy reset
> controller API).

Do you mean of_reset_control_get()? Maybe you could switch to
of_reset_control_get_exclusive() while at it?

That one might warrant a devres helper if other drivers were to adopt
the same pattern.

The patch itself looks fine to me,

Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>

regards
Philipp