phy: qcom-qmp-combo: drop pipe clock lane suffix
authorJohan Hovold <johan+linaro@kernel.org>
Tue, 30 Aug 2022 11:29:20 +0000 (13:29 +0200)
committerVinod Koul <vkoul@kernel.org>
Tue, 30 Aug 2022 13:26:22 +0000 (18:56 +0530)
The pipe clock is defined in the "lane" node so there's no need to keep
adding a redundant lane-number suffix to the clock name.

Update driver to support the new binding where the pipe clock name has
been deprecated by instead requesting the clock by index.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://lore.kernel.org/r/20220830112923.3725-28-johan+linaro@kernel.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/qualcomm/phy-qcom-qmp-combo.c

index 41e7548ef0b56b6fb06a53aebc27435669d41727..d200cd5ca4fa3f019a32bcd070dedcab5ac73650 100644 (file)
@@ -2723,7 +2723,6 @@ int qcom_qmp_phy_combo_create(struct device *dev, struct device_node *np, int id
        struct phy *generic_phy;
        struct qmp_phy *qphy;
        const struct phy_ops *ops;
-       char prop_name[MAX_PROP_NAME];
        int ret;
 
        qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
@@ -2789,8 +2788,7 @@ int qcom_qmp_phy_combo_create(struct device *dev, struct device_node *np, int id
         * Otherwise, we initialize pipe clock to NULL for
         * all phys that don't need this.
         */
-       snprintf(prop_name, sizeof(prop_name), "pipe%d", id);
-       qphy->pipe_clk = devm_get_clk_from_child(dev, np, prop_name);
+       qphy->pipe_clk = devm_get_clk_from_child(dev, np, NULL);
        if (IS_ERR(qphy->pipe_clk)) {
                if (cfg->type == PHY_TYPE_USB3) {
                        ret = PTR_ERR(qphy->pipe_clk);