+++ /dev/null
-From 5bfef756238ed6300056dbf5152f2a2be054b52e Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Tue, 30 Aug 2022 13:29:23 +0200
-Subject: phy: qcom-qmp-usb: drop pipe clock lane suffix
-
-From: Johan Hovold <johan+linaro@kernel.org>
-
-[ Upstream commit c8c5d5e89ac52a462f48264863a7a32f0c76fa1d ]
-
-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-31-johan+linaro@kernel.org
-Signed-off-by: Vinod Koul <vkoul@kernel.org>
-Stable-dep-of: a5d6b1ac56cb ("phy: qcom-qmp-usb: fix memleak on probe deferral")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 687f1a534837..116f60ef0649 100644
---- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2510,7 +2510,6 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
- struct phy *generic_phy;
- struct qmp_phy *qphy;
-- char prop_name[MAX_PROP_NAME];
- int ret;
-
- qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
-@@ -2566,8 +2565,7 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- if (!qphy->pcs_misc)
- dev_vdbg(dev, "PHY pcs_misc-reg not used\n");
-
-- 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)) {
- return dev_err_probe(dev, PTR_ERR(qphy->pipe_clk),
- "failed to get lane%d pipe clock\n", id);
---
-2.35.1
-
-From e0632f4b76cb0969d02f3a521cc9e879d9c6d412 Mon Sep 17 00:00:00 2001
+From e1c35c2f2b63651158f5c4744cf3b5cc3a1a2843 Mon Sep 17 00:00:00 2001
From: Sasha Levin <sashal@kernel.org>
Date: Fri, 16 Sep 2022 12:23:35 +0200
Subject: phy: qcom-qmp-usb: fix memleak on probe deferral
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 57 ++++++++++++++++++-------
- 1 file changed, 42 insertions(+), 15 deletions(-)
+ drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 61 +++++++++++++++++++++++---------
+ 1 file changed, 44 insertions(+), 17 deletions(-)
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 116f60ef0649..b727dcf4f906 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy_usb_ops = {
+@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy
.owner = THIS_MODULE,
};
static
int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
void __iomem *serdes, const struct qmp_phy_cfg *cfg)
-@@ -2510,8 +2525,18 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
+@@ -2511,8 +2526,18 @@ int qcom_qmp_phy_usb_create(struct devic
struct phy *generic_phy;
struct qmp_phy *qphy;
+ char prop_name[MAX_PROP_NAME];
+ bool exclusive = true;
int ret;
qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
if (!qphy)
return -ENOMEM;
-@@ -2524,17 +2549,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2525,17 +2550,17 @@ int qcom_qmp_phy_usb_create(struct devic
* For dual lane PHYs: tx2 -> 3, rx2 -> 4, pcs_misc (optional) -> 5
* For single lane PHYs: pcs_misc (optional) -> 3.
*/
- qphy->tx = of_iomap(np, 0);
- if (!qphy->tx)
- return -ENOMEM;
-+ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
-+ if (IS_ERR(qphy->tx))
-+ return PTR_ERR(qphy->tx);
-
+-
- qphy->rx = of_iomap(np, 1);
- if (!qphy->rx)
- return -ENOMEM;
-+ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
-+ if (IS_ERR(qphy->rx))
-+ return PTR_ERR(qphy->rx);
-
+-
- qphy->pcs = of_iomap(np, 2);
- if (!qphy->pcs)
- return -ENOMEM;
++ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
++ if (IS_ERR(qphy->tx))
++ return PTR_ERR(qphy->tx);
++
++ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
++ if (IS_ERR(qphy->rx))
++ return PTR_ERR(qphy->rx);
++
+ qphy->pcs = qmp_usb_iomap(dev, np, 2, exclusive);
+ if (IS_ERR(qphy->pcs))
+ return PTR_ERR(qphy->pcs);
/*
* If this is a dual-lane PHY, then there should be registers for the
-@@ -2543,9 +2568,9 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2544,9 +2569,9 @@ int qcom_qmp_phy_usb_create(struct devic
* offset from the first lane.
*/
if (cfg->is_dual_lane_phy) {
dev_warn(dev,
"Underspecified device tree, falling back to legacy register regions\n");
-@@ -2555,15 +2580,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2556,15 +2581,17 @@ int qcom_qmp_phy_usb_create(struct devic
qphy->rx2 = qphy->rx + QMP_PHY_LEGACY_LANE_STRIDE;
} else {
+ qphy->pcs_misc = NULL;
+ }
- qphy->pipe_clk = devm_get_clk_from_child(dev, np, NULL);
- if (IS_ERR(qphy->pipe_clk)) {
---
-2.35.1
-
+ snprintf(prop_name, sizeof(prop_name), "pipe%d", id);
+ qphy->pipe_clk = devm_get_clk_from_child(dev, np, prop_name);
phy-qcom-qmp-usb-drop-support-for-non-usb-phy-types.patch
phy-qcom-qmp-usb-cleanup-the-driver.patch
phy-qcom-qmp-usb-clean-up-pipe-clock-handling.patch
-phy-qcom-qmp-usb-drop-pipe-clock-lane-suffix.patch
phy-qcom-qmp-usb-fix-memleak-on-probe-deferral.patch
mtd-rawnand-fsl_elbc-fix-none-ecc-mode.patch
rdma-siw-always-consume-all-skbuf-data-in-sk_data_re.patch
+++ /dev/null
-From 3805907d92cd0199edf405eb7a3d16e023f481fb Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Tue, 30 Aug 2022 13:29:23 +0200
-Subject: phy: qcom-qmp-usb: drop pipe clock lane suffix
-
-From: Johan Hovold <johan+linaro@kernel.org>
-
-[ Upstream commit c8c5d5e89ac52a462f48264863a7a32f0c76fa1d ]
-
-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-31-johan+linaro@kernel.org
-Signed-off-by: Vinod Koul <vkoul@kernel.org>
-Stable-dep-of: a5d6b1ac56cb ("phy: qcom-qmp-usb: fix memleak on probe deferral")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 687f1a534837..116f60ef0649 100644
---- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2510,7 +2510,6 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
- struct phy *generic_phy;
- struct qmp_phy *qphy;
-- char prop_name[MAX_PROP_NAME];
- int ret;
-
- qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
-@@ -2566,8 +2565,7 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- if (!qphy->pcs_misc)
- dev_vdbg(dev, "PHY pcs_misc-reg not used\n");
-
-- 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)) {
- return dev_err_probe(dev, PTR_ERR(qphy->pipe_clk),
- "failed to get lane%d pipe clock\n", id);
---
-2.35.1
-
-From e28891255ecb303288fc26a5982f9a3601ef1e35 Mon Sep 17 00:00:00 2001
+From e1c35c2f2b63651158f5c4744cf3b5cc3a1a2843 Mon Sep 17 00:00:00 2001
From: Sasha Levin <sashal@kernel.org>
Date: Fri, 16 Sep 2022 12:23:35 +0200
Subject: phy: qcom-qmp-usb: fix memleak on probe deferral
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 57 ++++++++++++++++++-------
- 1 file changed, 42 insertions(+), 15 deletions(-)
+ drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 61 +++++++++++++++++++++++---------
+ 1 file changed, 44 insertions(+), 17 deletions(-)
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 116f60ef0649..b727dcf4f906 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy_usb_ops = {
+@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy
.owner = THIS_MODULE,
};
static
int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
void __iomem *serdes, const struct qmp_phy_cfg *cfg)
-@@ -2510,8 +2525,18 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
+@@ -2511,8 +2526,18 @@ int qcom_qmp_phy_usb_create(struct devic
struct phy *generic_phy;
struct qmp_phy *qphy;
+ char prop_name[MAX_PROP_NAME];
+ bool exclusive = true;
int ret;
qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
if (!qphy)
return -ENOMEM;
-@@ -2524,17 +2549,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2525,17 +2550,17 @@ int qcom_qmp_phy_usb_create(struct devic
* For dual lane PHYs: tx2 -> 3, rx2 -> 4, pcs_misc (optional) -> 5
* For single lane PHYs: pcs_misc (optional) -> 3.
*/
- qphy->tx = of_iomap(np, 0);
- if (!qphy->tx)
- return -ENOMEM;
-+ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
-+ if (IS_ERR(qphy->tx))
-+ return PTR_ERR(qphy->tx);
-
+-
- qphy->rx = of_iomap(np, 1);
- if (!qphy->rx)
- return -ENOMEM;
-+ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
-+ if (IS_ERR(qphy->rx))
-+ return PTR_ERR(qphy->rx);
-
+-
- qphy->pcs = of_iomap(np, 2);
- if (!qphy->pcs)
- return -ENOMEM;
++ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
++ if (IS_ERR(qphy->tx))
++ return PTR_ERR(qphy->tx);
++
++ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
++ if (IS_ERR(qphy->rx))
++ return PTR_ERR(qphy->rx);
++
+ qphy->pcs = qmp_usb_iomap(dev, np, 2, exclusive);
+ if (IS_ERR(qphy->pcs))
+ return PTR_ERR(qphy->pcs);
/*
* If this is a dual-lane PHY, then there should be registers for the
-@@ -2543,9 +2568,9 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2544,9 +2569,9 @@ int qcom_qmp_phy_usb_create(struct devic
* offset from the first lane.
*/
if (cfg->is_dual_lane_phy) {
dev_warn(dev,
"Underspecified device tree, falling back to legacy register regions\n");
-@@ -2555,15 +2580,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2556,15 +2581,17 @@ int qcom_qmp_phy_usb_create(struct devic
qphy->rx2 = qphy->rx + QMP_PHY_LEGACY_LANE_STRIDE;
} else {
+ qphy->pcs_misc = NULL;
+ }
- qphy->pipe_clk = devm_get_clk_from_child(dev, np, NULL);
- if (IS_ERR(qphy->pipe_clk)) {
---
-2.35.1
-
+ snprintf(prop_name, sizeof(prop_name), "pipe%d", id);
+ qphy->pipe_clk = devm_get_clk_from_child(dev, np, prop_name);
phy-qcom-qmp-usb-drop-support-for-non-usb-phy-types.patch
phy-qcom-qmp-usb-cleanup-the-driver.patch
phy-qcom-qmp-usb-clean-up-pipe-clock-handling.patch
-phy-qcom-qmp-usb-drop-pipe-clock-lane-suffix.patch
phy-qcom-qmp-usb-fix-memleak-on-probe-deferral.patch
phy-amlogic-phy-meson-axg-mipi-pcie-analog-hold-refe.patch
phy-phy-mtk-tphy-fix-the-phy-type-setting-issue.patch
+++ /dev/null
-From daa06deeda3b3a38d6e779601a66e1134db96bd3 Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Tue, 30 Aug 2022 13:29:23 +0200
-Subject: phy: qcom-qmp-usb: drop pipe clock lane suffix
-
-From: Johan Hovold <johan+linaro@kernel.org>
-
-[ Upstream commit c8c5d5e89ac52a462f48264863a7a32f0c76fa1d ]
-
-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-31-johan+linaro@kernel.org
-Signed-off-by: Vinod Koul <vkoul@kernel.org>
-Stable-dep-of: a5d6b1ac56cb ("phy: qcom-qmp-usb: fix memleak on probe deferral")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 687f1a534837..116f60ef0649 100644
---- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2510,7 +2510,6 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
- struct phy *generic_phy;
- struct qmp_phy *qphy;
-- char prop_name[MAX_PROP_NAME];
- int ret;
-
- qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
-@@ -2566,8 +2565,7 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- if (!qphy->pcs_misc)
- dev_vdbg(dev, "PHY pcs_misc-reg not used\n");
-
-- 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)) {
- return dev_err_probe(dev, PTR_ERR(qphy->pipe_clk),
- "failed to get lane%d pipe clock\n", id);
---
-2.35.1
-
-From 8e399daabb84fb7c47e944fa5aa53259a7fb4099 Mon Sep 17 00:00:00 2001
+From e1c35c2f2b63651158f5c4744cf3b5cc3a1a2843 Mon Sep 17 00:00:00 2001
From: Sasha Levin <sashal@kernel.org>
Date: Fri, 16 Sep 2022 12:23:35 +0200
Subject: phy: qcom-qmp-usb: fix memleak on probe deferral
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 57 ++++++++++++++++++-------
- 1 file changed, 42 insertions(+), 15 deletions(-)
+ drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 61 +++++++++++++++++++++++---------
+ 1 file changed, 44 insertions(+), 17 deletions(-)
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 116f60ef0649..b727dcf4f906 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy_usb_ops = {
+@@ -2503,6 +2503,21 @@ static const struct phy_ops qcom_qmp_phy
.owner = THIS_MODULE,
};
static
int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
void __iomem *serdes, const struct qmp_phy_cfg *cfg)
-@@ -2510,8 +2525,18 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
+@@ -2511,8 +2526,18 @@ int qcom_qmp_phy_usb_create(struct devic
struct phy *generic_phy;
struct qmp_phy *qphy;
+ char prop_name[MAX_PROP_NAME];
+ bool exclusive = true;
int ret;
qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
if (!qphy)
return -ENOMEM;
-@@ -2524,17 +2549,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2525,17 +2550,17 @@ int qcom_qmp_phy_usb_create(struct devic
* For dual lane PHYs: tx2 -> 3, rx2 -> 4, pcs_misc (optional) -> 5
* For single lane PHYs: pcs_misc (optional) -> 3.
*/
- qphy->tx = of_iomap(np, 0);
- if (!qphy->tx)
- return -ENOMEM;
-+ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
-+ if (IS_ERR(qphy->tx))
-+ return PTR_ERR(qphy->tx);
-
+-
- qphy->rx = of_iomap(np, 1);
- if (!qphy->rx)
- return -ENOMEM;
-+ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
-+ if (IS_ERR(qphy->rx))
-+ return PTR_ERR(qphy->rx);
-
+-
- qphy->pcs = of_iomap(np, 2);
- if (!qphy->pcs)
- return -ENOMEM;
++ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
++ if (IS_ERR(qphy->tx))
++ return PTR_ERR(qphy->tx);
++
++ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
++ if (IS_ERR(qphy->rx))
++ return PTR_ERR(qphy->rx);
++
+ qphy->pcs = qmp_usb_iomap(dev, np, 2, exclusive);
+ if (IS_ERR(qphy->pcs))
+ return PTR_ERR(qphy->pcs);
/*
* If this is a dual-lane PHY, then there should be registers for the
-@@ -2543,9 +2568,9 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2544,9 +2569,9 @@ int qcom_qmp_phy_usb_create(struct devic
* offset from the first lane.
*/
if (cfg->is_dual_lane_phy) {
dev_warn(dev,
"Underspecified device tree, falling back to legacy register regions\n");
-@@ -2555,15 +2580,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2556,15 +2581,17 @@ int qcom_qmp_phy_usb_create(struct devic
qphy->rx2 = qphy->rx + QMP_PHY_LEGACY_LANE_STRIDE;
} else {
+ qphy->pcs_misc = NULL;
+ }
- qphy->pipe_clk = devm_get_clk_from_child(dev, np, NULL);
- if (IS_ERR(qphy->pipe_clk)) {
---
-2.35.1
-
+ snprintf(prop_name, sizeof(prop_name), "pipe%d", id);
+ qphy->pipe_clk = devm_get_clk_from_child(dev, np, prop_name);
phy-qcom-qmp-usb-drop-support-for-non-usb-phy-types.patch
phy-qcom-qmp-usb-cleanup-the-driver.patch
phy-qcom-qmp-usb-clean-up-pipe-clock-handling.patch
-phy-qcom-qmp-usb-drop-pipe-clock-lane-suffix.patch
phy-qcom-qmp-usb-fix-memleak-on-probe-deferral.patch
phy-amlogic-phy-meson-axg-mipi-pcie-analog-hold-refe.patch
phy-phy-mtk-tphy-fix-the-phy-type-setting-issue.patch
+++ /dev/null
-From 73c530a52343ed1ac0209422c6b049e611f78561 Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Tue, 30 Aug 2022 13:29:23 +0200
-Subject: phy: qcom-qmp-usb: drop pipe clock lane suffix
-
-From: Johan Hovold <johan+linaro@kernel.org>
-
-[ Upstream commit c8c5d5e89ac52a462f48264863a7a32f0c76fa1d ]
-
-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-31-johan+linaro@kernel.org
-Signed-off-by: Vinod Koul <vkoul@kernel.org>
-Stable-dep-of: a5d6b1ac56cb ("phy: qcom-qmp-usb: fix memleak on probe deferral")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 1eb4ec576361..9f2b6f33c2db 100644
---- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2496,7 +2496,6 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
- struct phy *generic_phy;
- struct qmp_phy *qphy;
-- char prop_name[MAX_PROP_NAME];
- int ret;
-
- qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
-@@ -2555,8 +2554,7 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- if (!qphy->pcs_misc)
- dev_vdbg(dev, "PHY pcs_misc-reg not used\n");
-
-- 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)) {
- return dev_err_probe(dev, PTR_ERR(qphy->pipe_clk),
- "failed to get lane%d pipe clock\n", id);
---
-2.35.1
-
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
- drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 57 ++++++++++++++++++-------
- 1 file changed, 42 insertions(+), 15 deletions(-)
+ drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 61 +++++++++++++++++++++++---------
+ 1 file changed, 44 insertions(+), 17 deletions(-)
-diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-index 9f2b6f33c2db..d14481a501d6 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
-@@ -2489,6 +2489,21 @@ static const struct phy_ops qcom_qmp_phy_usb_ops = {
+@@ -2489,6 +2489,21 @@ static const struct phy_ops qcom_qmp_phy
.owner = THIS_MODULE,
};
static
int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
void __iomem *serdes, const struct qmp_phy_cfg *cfg)
-@@ -2496,8 +2511,18 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
- struct qcom_qmp *qmp = dev_get_drvdata(dev);
+@@ -2497,8 +2512,18 @@ int qcom_qmp_phy_usb_create(struct devic
struct phy *generic_phy;
struct qmp_phy *qphy;
+ char prop_name[MAX_PROP_NAME];
+ bool exclusive = true;
int ret;
qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
if (!qphy)
return -ENOMEM;
-@@ -2510,17 +2535,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2511,17 +2536,17 @@ int qcom_qmp_phy_usb_create(struct devic
* For dual lane PHYs: tx2 -> 3, rx2 -> 4, pcs_misc (optional) -> 5
* For single lane PHYs: pcs_misc (optional) -> 3.
*/
- qphy->tx = of_iomap(np, 0);
- if (!qphy->tx)
- return -ENOMEM;
-+ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
-+ if (IS_ERR(qphy->tx))
-+ return PTR_ERR(qphy->tx);
-
+-
- qphy->rx = of_iomap(np, 1);
- if (!qphy->rx)
- return -ENOMEM;
-+ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
-+ if (IS_ERR(qphy->rx))
-+ return PTR_ERR(qphy->rx);
-
+-
- qphy->pcs = of_iomap(np, 2);
- if (!qphy->pcs)
- return -ENOMEM;
++ qphy->tx = devm_of_iomap(dev, np, 0, NULL);
++ if (IS_ERR(qphy->tx))
++ return PTR_ERR(qphy->tx);
++
++ qphy->rx = devm_of_iomap(dev, np, 1, NULL);
++ if (IS_ERR(qphy->rx))
++ return PTR_ERR(qphy->rx);
++
+ qphy->pcs = qmp_usb_iomap(dev, np, 2, exclusive);
+ if (IS_ERR(qphy->pcs))
+ return PTR_ERR(qphy->pcs);
if (cfg->pcs_usb_offset)
qphy->pcs_usb = qphy->pcs + cfg->pcs_usb_offset;
-@@ -2532,9 +2557,9 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2533,9 +2558,9 @@ int qcom_qmp_phy_usb_create(struct devic
* offset from the first lane.
*/
if (cfg->is_dual_lane_phy) {
dev_warn(dev,
"Underspecified device tree, falling back to legacy register regions\n");
-@@ -2544,15 +2569,17 @@ int qcom_qmp_phy_usb_create(struct device *dev, struct device_node *np, int id,
+@@ -2545,15 +2570,17 @@ int qcom_qmp_phy_usb_create(struct devic
qphy->rx2 = qphy->rx + QMP_PHY_LEGACY_LANE_STRIDE;
} else {
+ qphy->pcs_misc = NULL;
+ }
- qphy->pipe_clk = devm_get_clk_from_child(dev, np, NULL);
- if (IS_ERR(qphy->pipe_clk)) {
---
-2.35.1
-
+ snprintf(prop_name, sizeof(prop_name), "pipe%d", id);
+ qphy->pipe_clk = devm_get_clk_from_child(dev, np, prop_name);
phy-qcom-qmp-pcie-msm8996-fix-memleak-on-probe-defer.patch
phy-qcom-qmp-combo-fix-memleak-on-probe-deferral.patch
phy-qcom-qmp-ufs-fix-memleak-on-probe-deferral.patch
-phy-qcom-qmp-usb-drop-pipe-clock-lane-suffix.patch
phy-qcom-qmp-usb-fix-memleak-on-probe-deferral.patch
phy-amlogic-phy-meson-axg-mipi-pcie-analog-hold-refe.patch
phy-phy-mtk-tphy-fix-the-phy-type-setting-issue.patch