Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

phy: phy-snps-eusb2: fix repeater imbalance on phy_init() failure

Make sure to disable the repeater PHY also on phy_init() failure.

Fixes: 3584f6392f09 ("phy: qcom: phy-qcom-snps-eusb2: Add support for eUSB2 repeater")
Cc: Abel Vesa <abel.vesa@linaro.org>
Cc: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Reviewed-by: Abel Vesa <abel.vesa@linaro.org>
Link: https://lore.kernel.org/r/20250523084839.11015-3-johan+linaro@kernel.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Johan Hovold and committed by
Vinod Koul
3232a6b0 641fa5b5

+3 -2
+3 -2
drivers/phy/phy-snps-eusb2.c
··· 468 468 ret = clk_bulk_prepare_enable(phy->data->num_clks, phy->clks); 469 469 if (ret) { 470 470 dev_err(&p->dev, "failed to enable ref clock, %d\n", ret); 471 - goto disable_vreg; 471 + goto exit_repeater; 472 472 } 473 473 474 474 ret = reset_control_assert(phy->phy_reset); ··· 493 493 494 494 disable_ref_clk: 495 495 clk_bulk_disable_unprepare(phy->data->num_clks, phy->clks); 496 - 496 + exit_repeater: 497 + phy_exit(phy->repeater); 497 498 disable_vreg: 498 499 regulator_bulk_disable(ARRAY_SIZE(phy->vregs), phy->vregs); 499 500