phy: qcom-qmp-pcie-msm8996: fix init-count imbalance
authorJohan Hovold <johan+linaro@kernel.org>
Tue, 2 May 2023 10:38:10 +0000 (12:38 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Jun 2023 08:34:23 +0000 (10:34 +0200)
commit867ad8cba251b4f8f08be398955727b0fb47455c
treec46dacf58ea75f35726092dbd7433fa87d145bdb
parent5daf7a171d27f581d212cdf1bdb97e304facbdba
phy: qcom-qmp-pcie-msm8996: fix init-count imbalance

commit e42f110700ed7293700c26145e1ed07ea05ac3f6 upstream.

The init counter is not decremented on initialisation errors, which
prevents retrying initialisation.

Add the missing decrement on initialisation errors so that the counter
reflects the state of the device.

Fixes: e78f3d15e115 ("phy: qcom-qmp: new qmp phy driver for qcom-chipsets")
Cc: stable@vger.kernel.org # 4.12
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://lore.kernel.org/r/20230502103810.12061-3-johan+linaro@kernel.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/phy/qualcomm/phy-qcom-qmp-pcie-msm8996.c