* [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC
@ 2025-08-28 10:32 Luo Jie
2025-08-28 10:32 ` [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id Luo Jie
` (10 more replies)
0 siblings, 11 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie,
Konrad Dybcio
The NSS clock controller on the IPQ5424 SoC provides clocks and resets
to the networking related hardware blocks such as the Packet Processing
Engine (PPE) and UNIPHY (PCS). Its parent clocks are sourced from the
GCC, CMN PLL, and UNIPHY blocks.
Additionally, register the gpll0_out_aux GCC clock, which serves as one
of the parent clocks for some of the NSS clocks.
The NSS NoC clocks are also enabled to use the icc-clk framework, enabling
the creation of interconnect paths for the network subsystem’s connections
with these NoCs.
The NSS clock controller receives its input clocks from the CMN PLL outputs.
The related patch series which adds support for IPQ5424 SoC in the CMN PLL
driver is listed below.
https://lore.kernel.org/all/20250610-qcom_ipq5424_cmnpll-v3-0-ceada8165645@quicinc.com/
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
Changes in v4:
- Add new, generic clock names "nss" and "ppe" in DT bindings to support
the newer SoC such as IPQ5424 SoC, while retaining existing clock names
for IPQ9574.
- Register all necessary NoC clocks as interconnect paths.
- Separate the fix for correcting icc_first_node_id into its own patch.
- Separate the fix requiring the "#interconnect-cells" property for NSS
clock controller node.
- Update commit titles from "clock:" to "clk:" for consistency.
- Update copyright to remove year as per guidelines in all driver files.
- Remove the Acked-by tag from the "Add Qualcomm IPQ5424 NSSNOC IDs" patch"
as the new NOC IDs are added.
- Link to v3: https://lore.kernel.org/r/20250710-qcom_ipq5424_nsscc-v3-0-f149dc461212@quicinc.com
Changes in v3:
- Remove frequency suffix from clock names for PPE and NSS clocks in
IPQ9574 DT binding and DTS.
- Update IPQ5424 DT bindings and DTS to as per new PPE and NSS clock names.
- Expand the register region of IPQ5424 NSSCC to utilize the entire 0x100_000
address range, ensuring inclusion of the wrapper region.
- Collect the reviewed-by tags.
- Link to v2: https://lore.kernel.org/r/20250627-qcom_ipq5424_nsscc-v2-0-8d392f65102a@quicinc.com
Changes in v2:
- Add new, separate clock names "nss" and "ppe" in dtbindings to support
the IPQ5424 SoC.
- Wrap the commit message body at 75 columns.
- Fix the indentation issue in the `IPQ_NSSCC_5424` Kconfig entry.
- Enhance the commit message for the defconfig patch to clarify the requirement
for enabling `IPQ_NSSCC_5424`.
- Link to v1: https://lore.kernel.org/r/20250617-qcom_ipq5424_nsscc-v1-0-4dc2d6b3cdfc@quicinc.com
---
Luo Jie (10):
clk: qcom: gcc-ipq5424: Correct the icc_first_node_id
dt-bindings: interconnect: Add Qualcomm IPQ5424 NSSNOC IDs
clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk
dt-bindings: clock: gcc-ipq5424: Add definition for GPLL0_OUT_AUX
clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock
dt-bindings: clock: Add required "interconnect-cells" property
dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC
clk: qcom: Add NSS clock controller driver for IPQ5424
arm64: dts: qcom: ipq5424: Add NSS clock controller node
arm64: defconfig: Build NSS clock controller driver for IPQ5424
.../bindings/clock/qcom,ipq9574-nsscc.yaml | 64 +-
arch/arm64/boot/dts/qcom/ipq5424.dtsi | 32 +-
arch/arm64/configs/defconfig | 1 +
drivers/clk/qcom/Kconfig | 11 +
drivers/clk/qcom/Makefile | 1 +
drivers/clk/qcom/gcc-ipq5424.c | 28 +-
drivers/clk/qcom/nsscc-ipq5424.c | 1340 ++++++++++++++++++++
include/dt-bindings/clock/qcom,ipq5424-gcc.h | 3 +-
include/dt-bindings/clock/qcom,ipq5424-nsscc.h | 65 +
include/dt-bindings/interconnect/qcom,ipq5424.h | 33 +
include/dt-bindings/reset/qcom,ipq5424-nsscc.h | 46 +
11 files changed, 1613 insertions(+), 11 deletions(-)
---
base-commit: 8cd53fb40a304576fa86ba985f3045d5c55b0ae3
change-id: 20250828-qcom_ipq5424_nsscc-d9f4eaf21795
Best regards,
--
Luo Jie <quic_luoj@quicinc.com>
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-09-02 12:07 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 02/10] dt-bindings: interconnect: Add Qualcomm IPQ5424 NSSNOC IDs Luo Jie
` (9 subsequent siblings)
10 siblings, 1 reply; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
Update to use the expected icc_first_node_id for registering the icc
clocks, ensuring correct association of clocks with interconnect nodes.
Fixes: 170f3d2c065e ("clk: qcom: ipq5424: Use icc-clk for enabling NoC related clocks")
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
drivers/clk/qcom/gcc-ipq5424.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/qcom/gcc-ipq5424.c b/drivers/clk/qcom/gcc-ipq5424.c
index 3d42f3d85c7a..71afa1b86b72 100644
--- a/drivers/clk/qcom/gcc-ipq5424.c
+++ b/drivers/clk/qcom/gcc-ipq5424.c
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Copyright (c) 2018,2020 The Linux Foundation. All rights reserved.
- * Copyright (c) 2024 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
*/
#include <linux/clk-provider.h>
@@ -3284,6 +3284,7 @@ static const struct qcom_cc_desc gcc_ipq5424_desc = {
.num_clk_hws = ARRAY_SIZE(gcc_ipq5424_hws),
.icc_hws = icc_ipq5424_hws,
.num_icc_hws = ARRAY_SIZE(icc_ipq5424_hws),
+ .icc_first_node_id = IPQ_APPS_ID,
};
static int gcc_ipq5424_probe(struct platform_device *pdev)
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 02/10] dt-bindings: interconnect: Add Qualcomm IPQ5424 NSSNOC IDs
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
2025-08-28 10:32 ` [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk Luo Jie
` (8 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
Add the NSSNOC master/slave ids for Qualcomm IPQ5424 network subsystem
(NSS) hardware blocks. These will be used by the gcc-ipq5424 driver
that provides the interconnect services by using the icc-clk framework.
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
include/dt-bindings/interconnect/qcom,ipq5424.h | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/include/dt-bindings/interconnect/qcom,ipq5424.h b/include/dt-bindings/interconnect/qcom,ipq5424.h
index afd7e0683a24..c5e0dec0b300 100644
--- a/include/dt-bindings/interconnect/qcom,ipq5424.h
+++ b/include/dt-bindings/interconnect/qcom,ipq5424.h
@@ -20,6 +20,26 @@
#define SLAVE_CNOC_PCIE3 15
#define MASTER_CNOC_USB 16
#define SLAVE_CNOC_USB 17
+#define MASTER_NSSNOC_NSSCC 18
+#define SLAVE_NSSNOC_NSSCC 19
+#define MASTER_NSSNOC_SNOC_0 20
+#define SLAVE_NSSNOC_SNOC_0 21
+#define MASTER_NSSNOC_SNOC_1 22
+#define SLAVE_NSSNOC_SNOC_1 23
+#define MASTER_NSSNOC_PCNOC_1 24
+#define SLAVE_NSSNOC_PCNOC_1 25
+#define MASTER_NSSNOC_QOSGEN_REF 26
+#define SLAVE_NSSNOC_QOSGEN_REF 27
+#define MASTER_NSSNOC_TIMEOUT_REF 28
+#define SLAVE_NSSNOC_TIMEOUT_REF 29
+#define MASTER_NSSNOC_XO_DCD 30
+#define SLAVE_NSSNOC_XO_DCD 31
+#define MASTER_NSSNOC_ATB 32
+#define SLAVE_NSSNOC_ATB 33
+#define MASTER_CNOC_LPASS_CFG 34
+#define SLAVE_CNOC_LPASS_CFG 35
+#define MASTER_SNOC_LPASS 36
+#define SLAVE_SNOC_LPASS 37
#define MASTER_CPU 0
#define SLAVE_L3 1
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
2025-08-28 10:32 ` [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id Luo Jie
2025-08-28 10:32 ` [PATCH v4 02/10] dt-bindings: interconnect: Add Qualcomm IPQ5424 NSSNOC IDs Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-09-02 12:11 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 04/10] dt-bindings: clock: gcc-ipq5424: Add definition for GPLL0_OUT_AUX Luo Jie
` (7 subsequent siblings)
10 siblings, 1 reply; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
Add NSS NoC clocks using the icc-clk framework to create interconnect
paths. The network subsystem (NSS) can be connected to these NoCs.
Additionally, add the LPASS CNOC and SNOC nodes to establish the complete
interconnect path.
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
drivers/clk/qcom/gcc-ipq5424.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/drivers/clk/qcom/gcc-ipq5424.c b/drivers/clk/qcom/gcc-ipq5424.c
index 71afa1b86b72..6cfe4f2b2888 100644
--- a/drivers/clk/qcom/gcc-ipq5424.c
+++ b/drivers/clk/qcom/gcc-ipq5424.c
@@ -3250,6 +3250,16 @@ static const struct qcom_icc_hws_data icc_ipq5424_hws[] = {
{ MASTER_ANOC_PCIE3, SLAVE_ANOC_PCIE3, GCC_ANOC_PCIE3_2LANE_M_CLK },
{ MASTER_CNOC_PCIE3, SLAVE_CNOC_PCIE3, GCC_CNOC_PCIE3_2LANE_S_CLK },
{ MASTER_CNOC_USB, SLAVE_CNOC_USB, GCC_CNOC_USB_CLK },
+ { MASTER_NSSNOC_NSSCC, SLAVE_NSSNOC_NSSCC, GCC_NSSNOC_NSSCC_CLK },
+ { MASTER_NSSNOC_SNOC_0, SLAVE_NSSNOC_SNOC_0, GCC_NSSNOC_SNOC_CLK },
+ { MASTER_NSSNOC_SNOC_1, SLAVE_NSSNOC_SNOC_1, GCC_NSSNOC_SNOC_1_CLK },
+ { MASTER_NSSNOC_PCNOC_1, SLAVE_NSSNOC_PCNOC_1, GCC_NSSNOC_PCNOC_1_CLK },
+ { MASTER_NSSNOC_QOSGEN_REF, SLAVE_NSSNOC_QOSGEN_REF, GCC_NSSNOC_QOSGEN_REF_CLK },
+ { MASTER_NSSNOC_TIMEOUT_REF, SLAVE_NSSNOC_TIMEOUT_REF, GCC_NSSNOC_TIMEOUT_REF_CLK },
+ { MASTER_NSSNOC_XO_DCD, SLAVE_NSSNOC_XO_DCD, GCC_NSSNOC_XO_DCD_CLK },
+ { MASTER_NSSNOC_ATB, SLAVE_NSSNOC_ATB, GCC_NSSNOC_ATB_CLK },
+ { MASTER_CNOC_LPASS_CFG, SLAVE_CNOC_LPASS_CFG, GCC_CNOC_LPASS_CFG_CLK },
+ { MASTER_SNOC_LPASS, SLAVE_SNOC_LPASS, GCC_SNOC_LPASS_CLK },
};
static const struct of_device_id gcc_ipq5424_match_table[] = {
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 04/10] dt-bindings: clock: gcc-ipq5424: Add definition for GPLL0_OUT_AUX
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (2 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock Luo Jie
` (6 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
The GCC clock GPLL0_OUT_AUX is one of source clocks for IPQ5424 NSS clock
controller.
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
include/dt-bindings/clock/qcom,ipq5424-gcc.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/dt-bindings/clock/qcom,ipq5424-gcc.h b/include/dt-bindings/clock/qcom,ipq5424-gcc.h
index c15ad16923bd..3ae33a0fa002 100644
--- a/include/dt-bindings/clock/qcom,ipq5424-gcc.h
+++ b/include/dt-bindings/clock/qcom,ipq5424-gcc.h
@@ -1,7 +1,7 @@
/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */
/*
* Copyright (c) 2018,2020 The Linux Foundation. All rights reserved.
- * Copyright (c) 2024 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
*/
#ifndef _DT_BINDINGS_CLOCK_IPQ_GCC_IPQ5424_H
@@ -152,5 +152,6 @@
#define GCC_PCIE3_RCHNG_CLK 143
#define GCC_IM_SLEEP_CLK 144
#define GCC_XO_CLK 145
+#define GPLL0_OUT_AUX 146
#endif
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (3 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 04/10] dt-bindings: clock: gcc-ipq5424: Add definition for GPLL0_OUT_AUX Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-09-02 12:11 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property Luo Jie
` (5 subsequent siblings)
10 siblings, 1 reply; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
The clock gpll0_out_aux acts as the parent clock for some of the NSS
(Network Subsystem) clocks.
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
drivers/clk/qcom/gcc-ipq5424.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/drivers/clk/qcom/gcc-ipq5424.c b/drivers/clk/qcom/gcc-ipq5424.c
index 6cfe4f2b2888..35af6ffeeb85 100644
--- a/drivers/clk/qcom/gcc-ipq5424.c
+++ b/drivers/clk/qcom/gcc-ipq5424.c
@@ -79,6 +79,20 @@ static struct clk_fixed_factor gpll0_div2 = {
},
};
+static struct clk_alpha_pll_postdiv gpll0_out_aux = {
+ .offset = 0x20000,
+ .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT],
+ .width = 4,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "gpll0_out_aux",
+ .parent_hws = (const struct clk_hw *[]) {
+ &gpll0.clkr.hw
+ },
+ .num_parents = 1,
+ .ops = &clk_alpha_pll_postdiv_ro_ops,
+ },
+};
+
static struct clk_alpha_pll gpll2 = {
.offset = 0x21000,
.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_NSS_HUAYRA],
@@ -2934,6 +2948,7 @@ static struct clk_regmap *gcc_ipq5424_clocks[] = {
[GPLL2] = &gpll2.clkr,
[GPLL2_OUT_MAIN] = &gpll2_out_main.clkr,
[GPLL4] = &gpll4.clkr,
+ [GPLL0_OUT_AUX] = &gpll0_out_aux.clkr,
};
static const struct qcom_reset_map gcc_ipq5424_resets[] = {
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (4 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-29 7:37 ` Krzysztof Kozlowski
2025-08-28 10:32 ` [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC Luo Jie
` (4 subsequent siblings)
10 siblings, 1 reply; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
ICC clocks are always provided by the NSS clock controller of IPQ9574,
so add interconnect-cells as required DT property.
Fixes: 28300ecedce4 ("dt-bindings: clock: Add ipq9574 NSSCC clock and reset definitions")
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
index 17252b6ea3be..fc604279114f 100644
--- a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
+++ b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
@@ -57,6 +57,7 @@ required:
- compatible
- clocks
- clock-names
+ - '#interconnect-cells'
allOf:
- $ref: qcom,gcc.yaml#
@@ -94,5 +95,6 @@ examples:
"bus";
#clock-cells = <1>;
#reset-cells = <1>;
+ #interconnect-cells = <1>;
};
...
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (5 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-29 7:38 ` Krzysztof Kozlowski
2025-08-28 10:32 ` [PATCH v4 08/10] clk: qcom: Add NSS clock controller driver for IPQ5424 Luo Jie
` (3 subsequent siblings)
10 siblings, 1 reply; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
NSS clock controller provides the clocks and resets to the networking
blocks such as PPE (Packet Process Engine) and UNIPHY (PCS) on IPQ5424
devices.
Add support for the compatible string "qcom,ipq5424-nsscc" based on the
existing IPQ9574 NSS clock controller Device Tree binding. Additionally,
update the clock names for PPE and NSS for newer SoC additions like
IPQ5424 to use generic and reusable identifiers "nss" and "ppe" without
the clock rate suffix.
Also add master/slave ids for IPQ5424 networking interfaces, which is
used by nss-ipq5424 driver for providing interconnect services using
icc-clk framework.
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
.../bindings/clock/qcom,ipq9574-nsscc.yaml | 62 ++++++++++++++++++---
include/dt-bindings/clock/qcom,ipq5424-nsscc.h | 65 ++++++++++++++++++++++
include/dt-bindings/interconnect/qcom,ipq5424.h | 13 +++++
include/dt-bindings/reset/qcom,ipq5424-nsscc.h | 46 +++++++++++++++
4 files changed, 178 insertions(+), 8 deletions(-)
diff --git a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
index fc604279114f..35e5c1b7dcbe 100644
--- a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
+++ b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
@@ -4,7 +4,7 @@
$id: http://devicetree.org/schemas/clock/qcom,ipq9574-nsscc.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
-title: Qualcomm Networking Sub System Clock & Reset Controller on IPQ9574
+title: Qualcomm Networking Sub System Clock & Reset Controller on IPQ9574 and IPQ5424
maintainers:
- Bjorn Andersson <andersson@kernel.org>
@@ -12,21 +12,29 @@ maintainers:
description: |
Qualcomm networking sub system clock control module provides the clocks,
- resets on IPQ9574
+ resets on IPQ9574 and IPQ5424
- See also::
+ See also:
+ include/dt-bindings/clock/qcom,ipq5424-nsscc.h
include/dt-bindings/clock/qcom,ipq9574-nsscc.h
+ include/dt-bindings/reset/qcom,ipq5424-nsscc.h
include/dt-bindings/reset/qcom,ipq9574-nsscc.h
properties:
compatible:
- const: qcom,ipq9574-nsscc
+ enum:
+ - qcom,ipq5424-nsscc
+ - qcom,ipq9574-nsscc
clocks:
items:
- description: Board XO source
- - description: CMN_PLL NSS 1200MHz (Bias PLL cc) clock source
- - description: CMN_PLL PPE 353MHz (Bias PLL ubi nc) clock source
+ - description: CMN_PLL NSS (Bias PLL cc) clock source. This clock rate
+ can vary for different IPQ SoCs. For example, it is 1200 MHz on the
+ IPQ9574 and 300 MHz on the IPQ5424.
+ - description: CMN_PLL PPE (Bias PLL ubi nc) clock source. The clock
+ rate can vary for different IPQ SoCs. For example, it is 353 MHz
+ on the IPQ9574 and 375 MHz on the IPQ5424.
- description: GCC GPLL0 OUT AUX clock source
- description: Uniphy0 NSS Rx clock source
- description: Uniphy0 NSS Tx clock source
@@ -42,8 +50,12 @@ properties:
clock-names:
items:
- const: xo
- - const: nss_1200
- - const: ppe_353
+ - enum:
+ - nss_1200
+ - nss
+ - enum:
+ - ppe_353
+ - ppe
- const: gpll0_out
- const: uniphy0_rx
- const: uniphy0_tx
@@ -61,6 +73,40 @@ required:
allOf:
- $ref: qcom,gcc.yaml#
+ - if:
+ properties:
+ compatible:
+ const: qcom,ipq9574-nsscc
+ then:
+ properties:
+ clock-names:
+ items:
+ - const: xo
+ - const: nss_1200
+ - const: ppe_353
+ - const: gpll0_out
+ - const: uniphy0_rx
+ - const: uniphy0_tx
+ - const: uniphy1_rx
+ - const: uniphy1_tx
+ - const: uniphy2_rx
+ - const: uniphy2_tx
+ - const: bus
+ else:
+ properties:
+ clock-names:
+ items:
+ - const: xo
+ - const: nss
+ - const: ppe
+ - const: gpll0_out
+ - const: uniphy0_rx
+ - const: uniphy0_tx
+ - const: uniphy1_rx
+ - const: uniphy1_tx
+ - const: uniphy2_rx
+ - const: uniphy2_tx
+ - const: bus
unevaluatedProperties: false
diff --git a/include/dt-bindings/clock/qcom,ipq5424-nsscc.h b/include/dt-bindings/clock/qcom,ipq5424-nsscc.h
new file mode 100644
index 000000000000..eeae0dc38042
--- /dev/null
+++ b/include/dt-bindings/clock/qcom,ipq5424-nsscc.h
@@ -0,0 +1,65 @@
+/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */
+/*
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
+ */
+
+#ifndef _DT_BINDINGS_CLOCK_QCOM_IPQ5424_NSSCC_H
+#define _DT_BINDINGS_CLOCK_QCOM_IPQ5424_NSSCC_H
+
+/* NSS_CC clocks */
+#define NSS_CC_CE_APB_CLK 0
+#define NSS_CC_CE_AXI_CLK 1
+#define NSS_CC_CE_CLK_SRC 2
+#define NSS_CC_CFG_CLK_SRC 3
+#define NSS_CC_DEBUG_CLK 4
+#define NSS_CC_EIP_BFDCD_CLK_SRC 5
+#define NSS_CC_EIP_CLK 6
+#define NSS_CC_NSS_CSR_CLK 7
+#define NSS_CC_NSSNOC_CE_APB_CLK 8
+#define NSS_CC_NSSNOC_CE_AXI_CLK 9
+#define NSS_CC_NSSNOC_EIP_CLK 10
+#define NSS_CC_NSSNOC_NSS_CSR_CLK 11
+#define NSS_CC_NSSNOC_PPE_CFG_CLK 12
+#define NSS_CC_NSSNOC_PPE_CLK 13
+#define NSS_CC_PORT1_MAC_CLK 14
+#define NSS_CC_PORT1_RX_CLK 15
+#define NSS_CC_PORT1_RX_CLK_SRC 16
+#define NSS_CC_PORT1_RX_DIV_CLK_SRC 17
+#define NSS_CC_PORT1_TX_CLK 18
+#define NSS_CC_PORT1_TX_CLK_SRC 19
+#define NSS_CC_PORT1_TX_DIV_CLK_SRC 20
+#define NSS_CC_PORT2_MAC_CLK 21
+#define NSS_CC_PORT2_RX_CLK 22
+#define NSS_CC_PORT2_RX_CLK_SRC 23
+#define NSS_CC_PORT2_RX_DIV_CLK_SRC 24
+#define NSS_CC_PORT2_TX_CLK 25
+#define NSS_CC_PORT2_TX_CLK_SRC 26
+#define NSS_CC_PORT2_TX_DIV_CLK_SRC 27
+#define NSS_CC_PORT3_MAC_CLK 28
+#define NSS_CC_PORT3_RX_CLK 29
+#define NSS_CC_PORT3_RX_CLK_SRC 30
+#define NSS_CC_PORT3_RX_DIV_CLK_SRC 31
+#define NSS_CC_PORT3_TX_CLK 32
+#define NSS_CC_PORT3_TX_CLK_SRC 33
+#define NSS_CC_PORT3_TX_DIV_CLK_SRC 34
+#define NSS_CC_PPE_CLK_SRC 35
+#define NSS_CC_PPE_EDMA_CFG_CLK 36
+#define NSS_CC_PPE_EDMA_CLK 37
+#define NSS_CC_PPE_SWITCH_BTQ_CLK 38
+#define NSS_CC_PPE_SWITCH_CFG_CLK 39
+#define NSS_CC_PPE_SWITCH_CLK 40
+#define NSS_CC_PPE_SWITCH_IPE_CLK 41
+#define NSS_CC_UNIPHY_PORT1_RX_CLK 42
+#define NSS_CC_UNIPHY_PORT1_TX_CLK 43
+#define NSS_CC_UNIPHY_PORT2_RX_CLK 44
+#define NSS_CC_UNIPHY_PORT2_TX_CLK 45
+#define NSS_CC_UNIPHY_PORT3_RX_CLK 46
+#define NSS_CC_UNIPHY_PORT3_TX_CLK 47
+#define NSS_CC_XGMAC0_PTP_REF_CLK 48
+#define NSS_CC_XGMAC0_PTP_REF_DIV_CLK_SRC 49
+#define NSS_CC_XGMAC1_PTP_REF_CLK 50
+#define NSS_CC_XGMAC1_PTP_REF_DIV_CLK_SRC 51
+#define NSS_CC_XGMAC2_PTP_REF_CLK 52
+#define NSS_CC_XGMAC2_PTP_REF_DIV_CLK_SRC 53
+
+#endif
diff --git a/include/dt-bindings/interconnect/qcom,ipq5424.h b/include/dt-bindings/interconnect/qcom,ipq5424.h
index c5e0dec0b300..07b786bee7d6 100644
--- a/include/dt-bindings/interconnect/qcom,ipq5424.h
+++ b/include/dt-bindings/interconnect/qcom,ipq5424.h
@@ -44,4 +44,17 @@
#define MASTER_CPU 0
#define SLAVE_L3 1
+#define MASTER_NSSNOC_PPE 0
+#define SLAVE_NSSNOC_PPE 1
+#define MASTER_NSSNOC_PPE_CFG 2
+#define SLAVE_NSSNOC_PPE_CFG 3
+#define MASTER_NSSNOC_NSS_CSR 4
+#define SLAVE_NSSNOC_NSS_CSR 5
+#define MASTER_NSSNOC_CE_AXI 6
+#define SLAVE_NSSNOC_CE_AXI 7
+#define MASTER_NSSNOC_CE_APB 8
+#define SLAVE_NSSNOC_CE_APB 9
+#define MASTER_NSSNOC_EIP 10
+#define SLAVE_NSSNOC_EIP 11
+
#endif /* INTERCONNECT_QCOM_IPQ5424_H */
diff --git a/include/dt-bindings/reset/qcom,ipq5424-nsscc.h b/include/dt-bindings/reset/qcom,ipq5424-nsscc.h
new file mode 100644
index 000000000000..9627e3b0ad30
--- /dev/null
+++ b/include/dt-bindings/reset/qcom,ipq5424-nsscc.h
@@ -0,0 +1,46 @@
+/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */
+/*
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
+ */
+
+#ifndef _DT_BINDINGS_RESET_QCOM_IPQ5424_NSSCC_H
+#define _DT_BINDINGS_RESET_QCOM_IPQ5424_NSSCC_H
+
+#define NSS_CC_CE_APB_CLK_ARES 0
+#define NSS_CC_CE_AXI_CLK_ARES 1
+#define NSS_CC_DEBUG_CLK_ARES 2
+#define NSS_CC_EIP_CLK_ARES 3
+#define NSS_CC_NSS_CSR_CLK_ARES 4
+#define NSS_CC_NSSNOC_CE_APB_CLK_ARES 5
+#define NSS_CC_NSSNOC_CE_AXI_CLK_ARES 6
+#define NSS_CC_NSSNOC_EIP_CLK_ARES 7
+#define NSS_CC_NSSNOC_NSS_CSR_CLK_ARES 8
+#define NSS_CC_NSSNOC_PPE_CLK_ARES 9
+#define NSS_CC_NSSNOC_PPE_CFG_CLK_ARES 10
+#define NSS_CC_PORT1_MAC_CLK_ARES 11
+#define NSS_CC_PORT1_RX_CLK_ARES 12
+#define NSS_CC_PORT1_TX_CLK_ARES 13
+#define NSS_CC_PORT2_MAC_CLK_ARES 14
+#define NSS_CC_PORT2_RX_CLK_ARES 15
+#define NSS_CC_PORT2_TX_CLK_ARES 16
+#define NSS_CC_PORT3_MAC_CLK_ARES 17
+#define NSS_CC_PORT3_RX_CLK_ARES 18
+#define NSS_CC_PORT3_TX_CLK_ARES 19
+#define NSS_CC_PPE_BCR 20
+#define NSS_CC_PPE_EDMA_CLK_ARES 21
+#define NSS_CC_PPE_EDMA_CFG_CLK_ARES 22
+#define NSS_CC_PPE_SWITCH_BTQ_CLK_ARES 23
+#define NSS_CC_PPE_SWITCH_CLK_ARES 24
+#define NSS_CC_PPE_SWITCH_CFG_CLK_ARES 25
+#define NSS_CC_PPE_SWITCH_IPE_CLK_ARES 26
+#define NSS_CC_UNIPHY_PORT1_RX_CLK_ARES 27
+#define NSS_CC_UNIPHY_PORT1_TX_CLK_ARES 28
+#define NSS_CC_UNIPHY_PORT2_RX_CLK_ARES 29
+#define NSS_CC_UNIPHY_PORT2_TX_CLK_ARES 30
+#define NSS_CC_UNIPHY_PORT3_RX_CLK_ARES 31
+#define NSS_CC_UNIPHY_PORT3_TX_CLK_ARES 32
+#define NSS_CC_XGMAC0_PTP_REF_CLK_ARES 33
+#define NSS_CC_XGMAC1_PTP_REF_CLK_ARES 34
+#define NSS_CC_XGMAC2_PTP_REF_CLK_ARES 35
+
+#endif
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 08/10] clk: qcom: Add NSS clock controller driver for IPQ5424
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (6 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 09/10] arm64: dts: qcom: ipq5424: Add NSS clock controller node Luo Jie
` (2 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie,
Konrad Dybcio
NSS (Network Subsystem) clock controller provides the clocks and resets
to the networking hardware blocks of the IPQ5424 SoC.
The icc-clk framework is used to enable NoC related clocks to create
paths so that the networking blocks can connect to these NoCs.
Acked-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
drivers/clk/qcom/Kconfig | 11 +
drivers/clk/qcom/Makefile | 1 +
drivers/clk/qcom/nsscc-ipq5424.c | 1340 ++++++++++++++++++++++++++++++++++++++
3 files changed, 1352 insertions(+)
diff --git a/drivers/clk/qcom/Kconfig b/drivers/clk/qcom/Kconfig
index aeb6197d7c90..f6bd73613ebd 100644
--- a/drivers/clk/qcom/Kconfig
+++ b/drivers/clk/qcom/Kconfig
@@ -290,6 +290,17 @@ config IPQ_GCC_9574
i2c, USB, SD/eMMC, etc. Select this for the root clock
of ipq9574.
+config IPQ_NSSCC_5424
+ tristate "IPQ5424 NSS Clock Controller"
+ depends on ARM64 || COMPILE_TEST
+ depends on IPQ_GCC_5424
+ help
+ Support for NSS clock controller on ipq5424 devices.
+ NSSCC receives the clock sources from GCC, CMN PLL and UNIPHY (PCS).
+ It in turn supplies the clocks and resets to the networking hardware.
+ Say Y or M if you want to enable networking function on the
+ IPQ5424 devices.
+
config IPQ_NSSCC_9574
tristate "IPQ9574 NSS Clock Controller"
depends on ARM64 || COMPILE_TEST
diff --git a/drivers/clk/qcom/Makefile b/drivers/clk/qcom/Makefile
index 98de55eb6402..8ee3d92a020d 100644
--- a/drivers/clk/qcom/Makefile
+++ b/drivers/clk/qcom/Makefile
@@ -40,6 +40,7 @@ obj-$(CONFIG_IPQ_GCC_6018) += gcc-ipq6018.o
obj-$(CONFIG_IPQ_GCC_806X) += gcc-ipq806x.o
obj-$(CONFIG_IPQ_GCC_8074) += gcc-ipq8074.o
obj-$(CONFIG_IPQ_GCC_9574) += gcc-ipq9574.o
+obj-$(CONFIG_IPQ_NSSCC_5424) += nsscc-ipq5424.o
obj-$(CONFIG_IPQ_NSSCC_9574) += nsscc-ipq9574.o
obj-$(CONFIG_IPQ_LCC_806X) += lcc-ipq806x.o
obj-$(CONFIG_IPQ_NSSCC_QCA8K) += nsscc-qca8k.o
diff --git a/drivers/clk/qcom/nsscc-ipq5424.c b/drivers/clk/qcom/nsscc-ipq5424.c
new file mode 100644
index 000000000000..5893c7146180
--- /dev/null
+++ b/drivers/clk/qcom/nsscc-ipq5424.c
@@ -0,0 +1,1340 @@
+// SPDX-License-Identifier: GPL-2.0-only
+/*
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
+ */
+
+#include <linux/clk.h>
+#include <linux/clk-provider.h>
+#include <linux/err.h>
+#include <linux/interconnect-provider.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/of.h>
+#include <linux/of_device.h>
+#include <linux/platform_device.h>
+#include <linux/pm_clock.h>
+#include <linux/pm_runtime.h>
+#include <linux/regmap.h>
+
+#include <dt-bindings/clock/qcom,ipq5424-nsscc.h>
+#include <dt-bindings/interconnect/qcom,ipq5424.h>
+#include <dt-bindings/reset/qcom,ipq5424-nsscc.h>
+
+#include "clk-branch.h"
+#include "clk-rcg.h"
+#include "clk-regmap.h"
+#include "clk-regmap-divider.h"
+#include "common.h"
+#include "reset.h"
+
+/* Need to match the order of clocks in DT binding */
+enum {
+ DT_CMN_PLL_XO_CLK,
+ DT_CMN_PLL_NSS_300M_CLK,
+ DT_CMN_PLL_NSS_375M_CLK,
+ DT_GCC_GPLL0_OUT_AUX,
+ DT_UNIPHY0_NSS_RX_CLK,
+ DT_UNIPHY0_NSS_TX_CLK,
+ DT_UNIPHY1_NSS_RX_CLK,
+ DT_UNIPHY1_NSS_TX_CLK,
+ DT_UNIPHY2_NSS_RX_CLK,
+ DT_UNIPHY2_NSS_TX_CLK,
+};
+
+enum {
+ P_CMN_PLL_XO_CLK,
+ P_CMN_PLL_NSS_300M_CLK,
+ P_CMN_PLL_NSS_375M_CLK,
+ P_GCC_GPLL0_OUT_AUX,
+ P_UNIPHY0_NSS_RX_CLK,
+ P_UNIPHY0_NSS_TX_CLK,
+ P_UNIPHY1_NSS_RX_CLK,
+ P_UNIPHY1_NSS_TX_CLK,
+ P_UNIPHY2_NSS_RX_CLK,
+ P_UNIPHY2_NSS_TX_CLK,
+};
+
+static const struct parent_map nss_cc_parent_map_0[] = {
+ { P_CMN_PLL_XO_CLK, 0 },
+ { P_GCC_GPLL0_OUT_AUX, 2 },
+ { P_CMN_PLL_NSS_300M_CLK, 5 },
+ { P_CMN_PLL_NSS_375M_CLK, 6 },
+};
+
+static const struct clk_parent_data nss_cc_parent_data_0[] = {
+ { .index = DT_CMN_PLL_XO_CLK },
+ { .index = DT_GCC_GPLL0_OUT_AUX },
+ { .index = DT_CMN_PLL_NSS_300M_CLK },
+ { .index = DT_CMN_PLL_NSS_375M_CLK },
+};
+
+static const struct parent_map nss_cc_parent_map_1[] = {
+ { P_CMN_PLL_XO_CLK, 0 },
+ { P_GCC_GPLL0_OUT_AUX, 2 },
+ { P_UNIPHY0_NSS_RX_CLK, 3 },
+ { P_UNIPHY0_NSS_TX_CLK, 4 },
+ { P_CMN_PLL_NSS_300M_CLK, 5 },
+ { P_CMN_PLL_NSS_375M_CLK, 6 },
+};
+
+static const struct clk_parent_data nss_cc_parent_data_1[] = {
+ { .index = DT_CMN_PLL_XO_CLK },
+ { .index = DT_GCC_GPLL0_OUT_AUX },
+ { .index = DT_UNIPHY0_NSS_RX_CLK },
+ { .index = DT_UNIPHY0_NSS_TX_CLK },
+ { .index = DT_CMN_PLL_NSS_300M_CLK },
+ { .index = DT_CMN_PLL_NSS_375M_CLK },
+};
+
+static const struct parent_map nss_cc_parent_map_2[] = {
+ { P_CMN_PLL_XO_CLK, 0 },
+ { P_GCC_GPLL0_OUT_AUX, 2 },
+ { P_UNIPHY1_NSS_RX_CLK, 3 },
+ { P_UNIPHY1_NSS_TX_CLK, 4 },
+ { P_CMN_PLL_NSS_300M_CLK, 5 },
+ { P_CMN_PLL_NSS_375M_CLK, 6 },
+};
+
+static const struct clk_parent_data nss_cc_parent_data_2[] = {
+ { .index = DT_CMN_PLL_XO_CLK },
+ { .index = DT_GCC_GPLL0_OUT_AUX },
+ { .index = DT_UNIPHY1_NSS_RX_CLK },
+ { .index = DT_UNIPHY1_NSS_TX_CLK },
+ { .index = DT_CMN_PLL_NSS_300M_CLK },
+ { .index = DT_CMN_PLL_NSS_375M_CLK },
+};
+
+static const struct parent_map nss_cc_parent_map_3[] = {
+ { P_CMN_PLL_XO_CLK, 0 },
+ { P_GCC_GPLL0_OUT_AUX, 2 },
+ { P_UNIPHY2_NSS_RX_CLK, 3 },
+ { P_UNIPHY2_NSS_TX_CLK, 4 },
+ { P_CMN_PLL_NSS_300M_CLK, 5 },
+ { P_CMN_PLL_NSS_375M_CLK, 6 },
+};
+
+static const struct clk_parent_data nss_cc_parent_data_3[] = {
+ { .index = DT_CMN_PLL_XO_CLK },
+ { .index = DT_GCC_GPLL0_OUT_AUX },
+ { .index = DT_UNIPHY2_NSS_RX_CLK },
+ { .index = DT_UNIPHY2_NSS_TX_CLK },
+ { .index = DT_CMN_PLL_NSS_300M_CLK },
+ { .index = DT_CMN_PLL_NSS_375M_CLK },
+};
+
+static const struct freq_tbl ftbl_nss_cc_ce_clk_src[] = {
+ F(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ F(375000000, P_CMN_PLL_NSS_375M_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_ce_clk_src = {
+ .cmd_rcgr = 0x5e0,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_0,
+ .freq_tbl = ftbl_nss_cc_ce_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ce_clk_src",
+ .parent_data = nss_cc_parent_data_0,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_0),
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_rcg2_ops,
+ },
+};
+
+static const struct freq_tbl ftbl_nss_cc_cfg_clk_src[] = {
+ F(100000000, P_GCC_GPLL0_OUT_AUX, 8, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_cfg_clk_src = {
+ .cmd_rcgr = 0x6a8,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_0,
+ .freq_tbl = ftbl_nss_cc_cfg_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_cfg_clk_src",
+ .parent_data = nss_cc_parent_data_0,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_0),
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_rcg2_ops,
+ },
+};
+
+static const struct freq_tbl ftbl_nss_cc_eip_bfdcd_clk_src[] = {
+ F(300000000, P_CMN_PLL_NSS_300M_CLK, 1, 0, 0),
+ F(375000000, P_CMN_PLL_NSS_375M_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_eip_bfdcd_clk_src = {
+ .cmd_rcgr = 0x644,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_0,
+ .freq_tbl = ftbl_nss_cc_eip_bfdcd_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_eip_bfdcd_clk_src",
+ .parent_data = nss_cc_parent_data_0,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_0),
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_rcg2_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port1_rx_clk_src_25[] = {
+ C(P_UNIPHY0_NSS_RX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY0_NSS_RX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port1_rx_clk_src_125[] = {
+ C(P_UNIPHY0_NSS_RX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY0_NSS_RX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port1_rx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port1_rx_clk_src_25),
+ FMS(78125000, P_UNIPHY0_NSS_RX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port1_rx_clk_src_125),
+ FMS(156250000, P_UNIPHY0_NSS_RX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY0_NSS_RX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port1_rx_clk_src = {
+ .cmd_rcgr = 0x4b4,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_1,
+ .freq_multi_tbl = ftbl_nss_cc_port1_rx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port1_rx_clk_src",
+ .parent_data = nss_cc_parent_data_1,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_1),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port1_tx_clk_src_25[] = {
+ C(P_UNIPHY0_NSS_TX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY0_NSS_TX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port1_tx_clk_src_125[] = {
+ C(P_UNIPHY0_NSS_TX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY0_NSS_TX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port1_tx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port1_tx_clk_src_25),
+ FMS(78125000, P_UNIPHY0_NSS_TX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port1_tx_clk_src_125),
+ FMS(156250000, P_UNIPHY0_NSS_TX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY0_NSS_TX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port1_tx_clk_src = {
+ .cmd_rcgr = 0x4c0,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_1,
+ .freq_multi_tbl = ftbl_nss_cc_port1_tx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port1_tx_clk_src",
+ .parent_data = nss_cc_parent_data_1,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_1),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port2_rx_clk_src_25[] = {
+ C(P_UNIPHY1_NSS_RX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY1_NSS_RX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port2_rx_clk_src_125[] = {
+ C(P_UNIPHY1_NSS_RX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY1_NSS_RX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port2_rx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port2_rx_clk_src_25),
+ FMS(78125000, P_UNIPHY1_NSS_RX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port2_rx_clk_src_125),
+ FMS(156250000, P_UNIPHY1_NSS_RX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY1_NSS_RX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port2_rx_clk_src = {
+ .cmd_rcgr = 0x4cc,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_2,
+ .freq_multi_tbl = ftbl_nss_cc_port2_rx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port2_rx_clk_src",
+ .parent_data = nss_cc_parent_data_2,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_2),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port2_tx_clk_src_25[] = {
+ C(P_UNIPHY1_NSS_TX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY1_NSS_TX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port2_tx_clk_src_125[] = {
+ C(P_UNIPHY1_NSS_TX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY1_NSS_TX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port2_tx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port2_tx_clk_src_25),
+ FMS(78125000, P_UNIPHY1_NSS_TX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port2_tx_clk_src_125),
+ FMS(156250000, P_UNIPHY1_NSS_TX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY1_NSS_TX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port2_tx_clk_src = {
+ .cmd_rcgr = 0x4d8,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_2,
+ .freq_multi_tbl = ftbl_nss_cc_port2_tx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port2_tx_clk_src",
+ .parent_data = nss_cc_parent_data_2,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_2),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port3_rx_clk_src_25[] = {
+ C(P_UNIPHY2_NSS_RX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY2_NSS_RX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port3_rx_clk_src_125[] = {
+ C(P_UNIPHY2_NSS_RX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY2_NSS_RX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port3_rx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port3_rx_clk_src_25),
+ FMS(78125000, P_UNIPHY2_NSS_RX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port3_rx_clk_src_125),
+ FMS(156250000, P_UNIPHY2_NSS_RX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY2_NSS_RX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port3_rx_clk_src = {
+ .cmd_rcgr = 0x4e4,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_3,
+ .freq_multi_tbl = ftbl_nss_cc_port3_rx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port3_rx_clk_src",
+ .parent_data = nss_cc_parent_data_3,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_3),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static const struct freq_conf ftbl_nss_cc_port3_tx_clk_src_25[] = {
+ C(P_UNIPHY2_NSS_TX_CLK, 12.5, 0, 0),
+ C(P_UNIPHY2_NSS_TX_CLK, 5, 0, 0),
+};
+
+static const struct freq_conf ftbl_nss_cc_port3_tx_clk_src_125[] = {
+ C(P_UNIPHY2_NSS_TX_CLK, 2.5, 0, 0),
+ C(P_UNIPHY2_NSS_TX_CLK, 1, 0, 0),
+};
+
+static const struct freq_multi_tbl ftbl_nss_cc_port3_tx_clk_src[] = {
+ FMS(24000000, P_CMN_PLL_XO_CLK, 1, 0, 0),
+ FM(25000000, ftbl_nss_cc_port3_tx_clk_src_25),
+ FMS(78125000, P_UNIPHY2_NSS_TX_CLK, 4, 0, 0),
+ FM(125000000, ftbl_nss_cc_port3_tx_clk_src_125),
+ FMS(156250000, P_UNIPHY2_NSS_TX_CLK, 2, 0, 0),
+ FMS(312500000, P_UNIPHY2_NSS_TX_CLK, 1, 0, 0),
+ { }
+};
+
+static struct clk_rcg2 nss_cc_port3_tx_clk_src = {
+ .cmd_rcgr = 0x4f0,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_3,
+ .freq_multi_tbl = ftbl_nss_cc_port3_tx_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port3_tx_clk_src",
+ .parent_data = nss_cc_parent_data_3,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_3),
+ .ops = &clk_rcg2_fm_ops,
+ },
+};
+
+static struct clk_rcg2 nss_cc_ppe_clk_src = {
+ .cmd_rcgr = 0x3ec,
+ .mnd_width = 0,
+ .hid_width = 5,
+ .parent_map = nss_cc_parent_map_0,
+ .freq_tbl = ftbl_nss_cc_ce_clk_src,
+ .clkr.hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_clk_src",
+ .parent_data = nss_cc_parent_data_0,
+ .num_parents = ARRAY_SIZE(nss_cc_parent_data_0),
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_rcg2_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port1_rx_div_clk_src = {
+ .reg = 0x4bc,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port1_rx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_rx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port1_tx_div_clk_src = {
+ .reg = 0x4c8,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port1_tx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_tx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port2_rx_div_clk_src = {
+ .reg = 0x4d4,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port2_rx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_rx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port2_tx_div_clk_src = {
+ .reg = 0x4e0,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port2_tx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_tx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port3_rx_div_clk_src = {
+ .reg = 0x4ec,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port3_rx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_rx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_port3_tx_div_clk_src = {
+ .reg = 0x4f8,
+ .shift = 0,
+ .width = 9,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_port3_tx_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_tx_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_xgmac0_ptp_ref_div_clk_src = {
+ .reg = 0x3f4,
+ .shift = 0,
+ .width = 4,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_xgmac0_ptp_ref_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ro_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_xgmac1_ptp_ref_div_clk_src = {
+ .reg = 0x3f8,
+ .shift = 0,
+ .width = 4,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_xgmac1_ptp_ref_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ro_ops,
+ },
+};
+
+static struct clk_regmap_div nss_cc_xgmac2_ptp_ref_div_clk_src = {
+ .reg = 0x3fc,
+ .shift = 0,
+ .width = 4,
+ .clkr.hw.init = &(const struct clk_init_data) {
+ .name = "nss_cc_xgmac2_ptp_ref_div_clk_src",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_regmap_div_ro_ops,
+ },
+};
+
+static struct clk_branch nss_cc_ce_apb_clk = {
+ .halt_reg = 0x5e8,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x5e8,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ce_apb_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ce_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ce_axi_clk = {
+ .halt_reg = 0x5ec,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x5ec,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ce_axi_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ce_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_debug_clk = {
+ .halt_reg = 0x70c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x70c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_debug_clk",
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_eip_clk = {
+ .halt_reg = 0x658,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x658,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_eip_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_eip_bfdcd_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nss_csr_clk = {
+ .halt_reg = 0x6b0,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x6b0,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nss_csr_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_cfg_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_ce_apb_clk = {
+ .halt_reg = 0x5f4,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x5f4,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_ce_apb_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ce_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_ce_axi_clk = {
+ .halt_reg = 0x5f8,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x5f8,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_ce_axi_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ce_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_eip_clk = {
+ .halt_reg = 0x660,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x660,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_eip_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_eip_bfdcd_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_nss_csr_clk = {
+ .halt_reg = 0x6b4,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x6b4,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_nss_csr_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_cfg_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_ppe_cfg_clk = {
+ .halt_reg = 0x444,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x444,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_ppe_cfg_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_nssnoc_ppe_clk = {
+ .halt_reg = 0x440,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x440,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_nssnoc_ppe_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port1_mac_clk = {
+ .halt_reg = 0x428,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x428,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port1_mac_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port1_rx_clk = {
+ .halt_reg = 0x4fc,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x4fc,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port1_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port1_tx_clk = {
+ .halt_reg = 0x504,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x504,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port1_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port2_mac_clk = {
+ .halt_reg = 0x430,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x430,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port2_mac_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port2_rx_clk = {
+ .halt_reg = 0x50c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x50c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port2_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port2_tx_clk = {
+ .halt_reg = 0x514,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x514,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port2_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port3_mac_clk = {
+ .halt_reg = 0x438,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x438,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port3_mac_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port3_rx_clk = {
+ .halt_reg = 0x51c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x51c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port3_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_port3_tx_clk = {
+ .halt_reg = 0x524,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x524,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_port3_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_edma_cfg_clk = {
+ .halt_reg = 0x424,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x424,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_edma_cfg_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_edma_clk = {
+ .halt_reg = 0x41c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x41c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_edma_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_switch_btq_clk = {
+ .halt_reg = 0x408,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x408,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_switch_btq_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_switch_cfg_clk = {
+ .halt_reg = 0x418,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x418,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_switch_cfg_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_switch_clk = {
+ .halt_reg = 0x410,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x410,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_switch_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_ppe_switch_ipe_clk = {
+ .halt_reg = 0x400,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x400,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_ppe_switch_ipe_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_ppe_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port1_rx_clk = {
+ .halt_reg = 0x57c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x57c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port1_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port1_tx_clk = {
+ .halt_reg = 0x580,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x580,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port1_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port1_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port2_rx_clk = {
+ .halt_reg = 0x584,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x584,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port2_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port2_tx_clk = {
+ .halt_reg = 0x588,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x588,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port2_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port2_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port3_rx_clk = {
+ .halt_reg = 0x58c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x58c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port3_rx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_rx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_uniphy_port3_tx_clk = {
+ .halt_reg = 0x590,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x590,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_uniphy_port3_tx_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_port3_tx_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_xgmac0_ptp_ref_clk = {
+ .halt_reg = 0x448,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x448,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_xgmac0_ptp_ref_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_xgmac0_ptp_ref_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_xgmac1_ptp_ref_clk = {
+ .halt_reg = 0x44c,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x44c,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_xgmac1_ptp_ref_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_xgmac1_ptp_ref_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_branch nss_cc_xgmac2_ptp_ref_clk = {
+ .halt_reg = 0x450,
+ .halt_check = BRANCH_HALT,
+ .clkr = {
+ .enable_reg = 0x450,
+ .enable_mask = BIT(0),
+ .hw.init = &(const struct clk_init_data){
+ .name = "nss_cc_xgmac2_ptp_ref_clk",
+ .parent_hws = (const struct clk_hw*[]){
+ &nss_cc_xgmac2_ptp_ref_div_clk_src.clkr.hw,
+ },
+ .num_parents = 1,
+ .flags = CLK_SET_RATE_PARENT,
+ .ops = &clk_branch2_ops,
+ },
+ },
+};
+
+static struct clk_regmap *nss_cc_ipq5424_clocks[] = {
+ [NSS_CC_CE_APB_CLK] = &nss_cc_ce_apb_clk.clkr,
+ [NSS_CC_CE_AXI_CLK] = &nss_cc_ce_axi_clk.clkr,
+ [NSS_CC_CE_CLK_SRC] = &nss_cc_ce_clk_src.clkr,
+ [NSS_CC_CFG_CLK_SRC] = &nss_cc_cfg_clk_src.clkr,
+ [NSS_CC_DEBUG_CLK] = &nss_cc_debug_clk.clkr,
+ [NSS_CC_EIP_BFDCD_CLK_SRC] = &nss_cc_eip_bfdcd_clk_src.clkr,
+ [NSS_CC_EIP_CLK] = &nss_cc_eip_clk.clkr,
+ [NSS_CC_NSS_CSR_CLK] = &nss_cc_nss_csr_clk.clkr,
+ [NSS_CC_NSSNOC_CE_APB_CLK] = &nss_cc_nssnoc_ce_apb_clk.clkr,
+ [NSS_CC_NSSNOC_CE_AXI_CLK] = &nss_cc_nssnoc_ce_axi_clk.clkr,
+ [NSS_CC_NSSNOC_EIP_CLK] = &nss_cc_nssnoc_eip_clk.clkr,
+ [NSS_CC_NSSNOC_NSS_CSR_CLK] = &nss_cc_nssnoc_nss_csr_clk.clkr,
+ [NSS_CC_NSSNOC_PPE_CFG_CLK] = &nss_cc_nssnoc_ppe_cfg_clk.clkr,
+ [NSS_CC_NSSNOC_PPE_CLK] = &nss_cc_nssnoc_ppe_clk.clkr,
+ [NSS_CC_PORT1_MAC_CLK] = &nss_cc_port1_mac_clk.clkr,
+ [NSS_CC_PORT1_RX_CLK] = &nss_cc_port1_rx_clk.clkr,
+ [NSS_CC_PORT1_RX_CLK_SRC] = &nss_cc_port1_rx_clk_src.clkr,
+ [NSS_CC_PORT1_RX_DIV_CLK_SRC] = &nss_cc_port1_rx_div_clk_src.clkr,
+ [NSS_CC_PORT1_TX_CLK] = &nss_cc_port1_tx_clk.clkr,
+ [NSS_CC_PORT1_TX_CLK_SRC] = &nss_cc_port1_tx_clk_src.clkr,
+ [NSS_CC_PORT1_TX_DIV_CLK_SRC] = &nss_cc_port1_tx_div_clk_src.clkr,
+ [NSS_CC_PORT2_MAC_CLK] = &nss_cc_port2_mac_clk.clkr,
+ [NSS_CC_PORT2_RX_CLK] = &nss_cc_port2_rx_clk.clkr,
+ [NSS_CC_PORT2_RX_CLK_SRC] = &nss_cc_port2_rx_clk_src.clkr,
+ [NSS_CC_PORT2_RX_DIV_CLK_SRC] = &nss_cc_port2_rx_div_clk_src.clkr,
+ [NSS_CC_PORT2_TX_CLK] = &nss_cc_port2_tx_clk.clkr,
+ [NSS_CC_PORT2_TX_CLK_SRC] = &nss_cc_port2_tx_clk_src.clkr,
+ [NSS_CC_PORT2_TX_DIV_CLK_SRC] = &nss_cc_port2_tx_div_clk_src.clkr,
+ [NSS_CC_PORT3_MAC_CLK] = &nss_cc_port3_mac_clk.clkr,
+ [NSS_CC_PORT3_RX_CLK] = &nss_cc_port3_rx_clk.clkr,
+ [NSS_CC_PORT3_RX_CLK_SRC] = &nss_cc_port3_rx_clk_src.clkr,
+ [NSS_CC_PORT3_RX_DIV_CLK_SRC] = &nss_cc_port3_rx_div_clk_src.clkr,
+ [NSS_CC_PORT3_TX_CLK] = &nss_cc_port3_tx_clk.clkr,
+ [NSS_CC_PORT3_TX_CLK_SRC] = &nss_cc_port3_tx_clk_src.clkr,
+ [NSS_CC_PORT3_TX_DIV_CLK_SRC] = &nss_cc_port3_tx_div_clk_src.clkr,
+ [NSS_CC_PPE_CLK_SRC] = &nss_cc_ppe_clk_src.clkr,
+ [NSS_CC_PPE_EDMA_CFG_CLK] = &nss_cc_ppe_edma_cfg_clk.clkr,
+ [NSS_CC_PPE_EDMA_CLK] = &nss_cc_ppe_edma_clk.clkr,
+ [NSS_CC_PPE_SWITCH_BTQ_CLK] = &nss_cc_ppe_switch_btq_clk.clkr,
+ [NSS_CC_PPE_SWITCH_CFG_CLK] = &nss_cc_ppe_switch_cfg_clk.clkr,
+ [NSS_CC_PPE_SWITCH_CLK] = &nss_cc_ppe_switch_clk.clkr,
+ [NSS_CC_PPE_SWITCH_IPE_CLK] = &nss_cc_ppe_switch_ipe_clk.clkr,
+ [NSS_CC_UNIPHY_PORT1_RX_CLK] = &nss_cc_uniphy_port1_rx_clk.clkr,
+ [NSS_CC_UNIPHY_PORT1_TX_CLK] = &nss_cc_uniphy_port1_tx_clk.clkr,
+ [NSS_CC_UNIPHY_PORT2_RX_CLK] = &nss_cc_uniphy_port2_rx_clk.clkr,
+ [NSS_CC_UNIPHY_PORT2_TX_CLK] = &nss_cc_uniphy_port2_tx_clk.clkr,
+ [NSS_CC_UNIPHY_PORT3_RX_CLK] = &nss_cc_uniphy_port3_rx_clk.clkr,
+ [NSS_CC_UNIPHY_PORT3_TX_CLK] = &nss_cc_uniphy_port3_tx_clk.clkr,
+ [NSS_CC_XGMAC0_PTP_REF_CLK] = &nss_cc_xgmac0_ptp_ref_clk.clkr,
+ [NSS_CC_XGMAC0_PTP_REF_DIV_CLK_SRC] = &nss_cc_xgmac0_ptp_ref_div_clk_src.clkr,
+ [NSS_CC_XGMAC1_PTP_REF_CLK] = &nss_cc_xgmac1_ptp_ref_clk.clkr,
+ [NSS_CC_XGMAC1_PTP_REF_DIV_CLK_SRC] = &nss_cc_xgmac1_ptp_ref_div_clk_src.clkr,
+ [NSS_CC_XGMAC2_PTP_REF_CLK] = &nss_cc_xgmac2_ptp_ref_clk.clkr,
+ [NSS_CC_XGMAC2_PTP_REF_DIV_CLK_SRC] = &nss_cc_xgmac2_ptp_ref_div_clk_src.clkr,
+};
+
+static const struct qcom_reset_map nss_cc_ipq5424_resets[] = {
+ [NSS_CC_CE_APB_CLK_ARES] = { 0x5e8, 2 },
+ [NSS_CC_CE_AXI_CLK_ARES] = { 0x5ec, 2 },
+ [NSS_CC_DEBUG_CLK_ARES] = { 0x70c, 2 },
+ [NSS_CC_EIP_CLK_ARES] = { 0x658, 2 },
+ [NSS_CC_NSS_CSR_CLK_ARES] = { 0x6b0, 2 },
+ [NSS_CC_NSSNOC_CE_APB_CLK_ARES] = { 0x5f4, 2 },
+ [NSS_CC_NSSNOC_CE_AXI_CLK_ARES] = { 0x5f8, 2 },
+ [NSS_CC_NSSNOC_EIP_CLK_ARES] = { 0x660, 2 },
+ [NSS_CC_NSSNOC_NSS_CSR_CLK_ARES] = { 0x6b4, 2 },
+ [NSS_CC_NSSNOC_PPE_CLK_ARES] = { 0x440, 2 },
+ [NSS_CC_NSSNOC_PPE_CFG_CLK_ARES] = { 0x444, 2 },
+ [NSS_CC_PORT1_MAC_CLK_ARES] = { 0x428, 2 },
+ [NSS_CC_PORT1_RX_CLK_ARES] = { 0x4fc, 2 },
+ [NSS_CC_PORT1_TX_CLK_ARES] = { 0x504, 2 },
+ [NSS_CC_PORT2_MAC_CLK_ARES] = { 0x430, 2 },
+ [NSS_CC_PORT2_RX_CLK_ARES] = { 0x50c, 2 },
+ [NSS_CC_PORT2_TX_CLK_ARES] = { 0x514, 2 },
+ [NSS_CC_PORT3_MAC_CLK_ARES] = { 0x438, 2 },
+ [NSS_CC_PORT3_RX_CLK_ARES] = { 0x51c, 2 },
+ [NSS_CC_PORT3_TX_CLK_ARES] = { 0x524, 2 },
+ [NSS_CC_PPE_BCR] = { 0x3e8 },
+ [NSS_CC_PPE_EDMA_CLK_ARES] = { 0x41c, 2 },
+ [NSS_CC_PPE_EDMA_CFG_CLK_ARES] = { 0x424, 2 },
+ [NSS_CC_PPE_SWITCH_BTQ_CLK_ARES] = { 0x408, 2 },
+ [NSS_CC_PPE_SWITCH_CLK_ARES] = { 0x410, 2 },
+ [NSS_CC_PPE_SWITCH_CFG_CLK_ARES] = { 0x418, 2 },
+ [NSS_CC_PPE_SWITCH_IPE_CLK_ARES] = { 0x400, 2 },
+ [NSS_CC_UNIPHY_PORT1_RX_CLK_ARES] = { 0x57c, 2 },
+ [NSS_CC_UNIPHY_PORT1_TX_CLK_ARES] = { 0x580, 2 },
+ [NSS_CC_UNIPHY_PORT2_RX_CLK_ARES] = { 0x584, 2 },
+ [NSS_CC_UNIPHY_PORT2_TX_CLK_ARES] = { 0x588, 2 },
+ [NSS_CC_UNIPHY_PORT3_RX_CLK_ARES] = { 0x58c, 2 },
+ [NSS_CC_UNIPHY_PORT3_TX_CLK_ARES] = { 0x590, 2 },
+ [NSS_CC_XGMAC0_PTP_REF_CLK_ARES] = { 0x448, 2 },
+ [NSS_CC_XGMAC1_PTP_REF_CLK_ARES] = { 0x44c, 2 },
+ [NSS_CC_XGMAC2_PTP_REF_CLK_ARES] = { 0x450, 2 },
+};
+
+static const struct regmap_config nss_cc_ipq5424_regmap_config = {
+ .reg_bits = 32,
+ .reg_stride = 4,
+ .val_bits = 32,
+ .max_register = 0x800,
+ .fast_io = true,
+};
+
+static const struct qcom_icc_hws_data icc_ipq5424_nss_hws[] = {
+ { MASTER_NSSNOC_PPE, SLAVE_NSSNOC_PPE, NSS_CC_NSSNOC_PPE_CLK },
+ { MASTER_NSSNOC_PPE_CFG, SLAVE_NSSNOC_PPE_CFG, NSS_CC_NSSNOC_PPE_CFG_CLK },
+ { MASTER_NSSNOC_NSS_CSR, SLAVE_NSSNOC_NSS_CSR, NSS_CC_NSSNOC_NSS_CSR_CLK },
+ { MASTER_NSSNOC_CE_AXI, SLAVE_NSSNOC_CE_AXI, NSS_CC_NSSNOC_CE_AXI_CLK},
+ { MASTER_NSSNOC_CE_APB, SLAVE_NSSNOC_CE_APB, NSS_CC_NSSNOC_CE_APB_CLK},
+ { MASTER_NSSNOC_EIP, SLAVE_NSSNOC_EIP, NSS_CC_NSSNOC_EIP_CLK},
+};
+
+#define IPQ_NSSCC_ID (5424 * 2) /* some unique value */
+
+static const struct qcom_cc_desc nss_cc_ipq5424_desc = {
+ .config = &nss_cc_ipq5424_regmap_config,
+ .clks = nss_cc_ipq5424_clocks,
+ .num_clks = ARRAY_SIZE(nss_cc_ipq5424_clocks),
+ .resets = nss_cc_ipq5424_resets,
+ .num_resets = ARRAY_SIZE(nss_cc_ipq5424_resets),
+ .icc_hws = icc_ipq5424_nss_hws,
+ .num_icc_hws = ARRAY_SIZE(icc_ipq5424_nss_hws),
+ .icc_first_node_id = IPQ_NSSCC_ID,
+};
+
+static const struct dev_pm_ops nss_cc_ipq5424_pm_ops = {
+ SET_RUNTIME_PM_OPS(pm_clk_suspend, pm_clk_resume, NULL)
+};
+
+static const struct of_device_id nss_cc_ipq5424_match_table[] = {
+ { .compatible = "qcom,ipq5424-nsscc" },
+ { }
+};
+MODULE_DEVICE_TABLE(of, nss_cc_ipq5424_match_table);
+
+static int nss_cc_ipq5424_probe(struct platform_device *pdev)
+{
+ int ret;
+
+ ret = devm_pm_runtime_enable(&pdev->dev);
+ if (ret)
+ return dev_err_probe(&pdev->dev, ret, "Fail to enable runtime PM\n");
+
+ ret = devm_pm_clk_create(&pdev->dev);
+ if (ret)
+ return dev_err_probe(&pdev->dev, ret, "Fail to create PM clock\n");
+
+ ret = pm_clk_add(&pdev->dev, "bus");
+ if (ret)
+ return dev_err_probe(&pdev->dev, ret, "Fail to add bus clock\n");
+
+ ret = pm_runtime_resume_and_get(&pdev->dev);
+ if (ret)
+ return dev_err_probe(&pdev->dev, ret, "Fail to resume\n");
+
+ ret = qcom_cc_probe(pdev, &nss_cc_ipq5424_desc);
+ pm_runtime_put(&pdev->dev);
+
+ return ret;
+}
+
+static struct platform_driver nss_cc_ipq5424_driver = {
+ .probe = nss_cc_ipq5424_probe,
+ .driver = {
+ .name = "qcom,ipq5424-nsscc",
+ .of_match_table = nss_cc_ipq5424_match_table,
+ .pm = &nss_cc_ipq5424_pm_ops,
+ .sync_state = icc_sync_state,
+ },
+};
+module_platform_driver(nss_cc_ipq5424_driver);
+
+MODULE_DESCRIPTION("Qualcomm Technologies, Inc. NSSCC IPQ5424 Driver");
+MODULE_LICENSE("GPL");
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 09/10] arm64: dts: qcom: ipq5424: Add NSS clock controller node
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (7 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 08/10] clk: qcom: Add NSS clock controller driver for IPQ5424 Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 10/10] arm64: defconfig: Build NSS clock controller driver for IPQ5424 Luo Jie
2025-08-29 7:34 ` [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Krzysztof Kozlowski
10 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie,
Konrad Dybcio
NSS clock controller provides the clocks and resets to the networking
hardware blocks on the IPQ5424, such as PPE (Packet Process Engine) and
UNIPHY (PCS) blocks.
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
arch/arm64/boot/dts/qcom/ipq5424.dtsi | 32 +++++++++++++++++++++++++++++++-
1 file changed, 31 insertions(+), 1 deletion(-)
diff --git a/arch/arm64/boot/dts/qcom/ipq5424.dtsi b/arch/arm64/boot/dts/qcom/ipq5424.dtsi
index 67877fbbdf3a..ea7b3b6bc756 100644
--- a/arch/arm64/boot/dts/qcom/ipq5424.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq5424.dtsi
@@ -3,7 +3,7 @@
* IPQ5424 device tree source
*
* Copyright (c) 2020-2021 The Linux Foundation. All rights reserved.
- * Copyright (c) 2022-2025 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
*/
#include <dt-bindings/interrupt-controller/arm-gic.h>
@@ -809,6 +809,36 @@ apss_clk: clock-controller@fa80000 {
#interconnect-cells = <1>;
};
+ clock-controller@39b00000 {
+ compatible = "qcom,ipq5424-nsscc";
+ reg = <0 0x39b00000 0 0x100000>;
+ clocks = <&cmn_pll IPQ5424_XO_24MHZ_CLK>,
+ <&cmn_pll IPQ5424_NSS_300MHZ_CLK>,
+ <&cmn_pll IPQ5424_PPE_375MHZ_CLK>,
+ <&gcc GPLL0_OUT_AUX>,
+ <0>,
+ <0>,
+ <0>,
+ <0>,
+ <0>,
+ <0>,
+ <&gcc GCC_NSSCC_CLK>;
+ clock-names = "xo",
+ "nss",
+ "ppe",
+ "gpll0_out",
+ "uniphy0_rx",
+ "uniphy0_tx",
+ "uniphy1_rx",
+ "uniphy1_tx",
+ "uniphy2_rx",
+ "uniphy2_tx",
+ "bus";
+ #clock-cells = <1>;
+ #reset-cells = <1>;
+ #interconnect-cells = <1>;
+ };
+
pcie3: pcie@40000000 {
compatible = "qcom,pcie-ipq5424", "qcom,pcie-ipq9574";
reg = <0x0 0x40000000 0x0 0xf1c>,
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH v4 10/10] arm64: defconfig: Build NSS clock controller driver for IPQ5424
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (8 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 09/10] arm64: dts: qcom: ipq5424: Add NSS clock controller node Luo Jie
@ 2025-08-28 10:32 ` Luo Jie
2025-08-29 7:34 ` [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Krzysztof Kozlowski
10 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-08-28 10:32 UTC (permalink / raw)
To: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia, Luo Jie
NSS clock controller is needed for supplying clocks and resets to the
networking blocks for the Ethernet functions on the IPQ5424 platforms.
All boards based on the IPQ5424 SoC will require this driver to be enabled.
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
---
arch/arm64/configs/defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index acb6807d3461..013325255119 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -1379,6 +1379,7 @@ CONFIG_IPQ_GCC_5424=y
CONFIG_IPQ_GCC_6018=y
CONFIG_IPQ_GCC_8074=y
CONFIG_IPQ_GCC_9574=y
+CONFIG_IPQ_NSSCC_5424=m
CONFIG_IPQ_NSSCC_9574=m
CONFIG_MSM_GCC_8916=y
CONFIG_MSM_MMCC_8994=m
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
` (9 preceding siblings ...)
2025-08-28 10:32 ` [PATCH v4 10/10] arm64: defconfig: Build NSS clock controller driver for IPQ5424 Luo Jie
@ 2025-08-29 7:34 ` Krzysztof Kozlowski
2025-09-02 13:01 ` Luo Jie
10 siblings, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-08-29 7:34 UTC (permalink / raw)
To: Luo Jie
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia, Konrad Dybcio
On Thu, Aug 28, 2025 at 06:32:13PM +0800, Luo Jie wrote:
> - Remove the Acked-by tag from the "Add Qualcomm IPQ5424 NSSNOC IDs" patch"
> as the new NOC IDs are added.
So let's wait for v6 with acking :/
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property
2025-08-28 10:32 ` [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property Luo Jie
@ 2025-08-29 7:37 ` Krzysztof Kozlowski
2025-09-02 12:56 ` Luo Jie
0 siblings, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-08-29 7:37 UTC (permalink / raw)
To: Luo Jie
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia
On Thu, Aug 28, 2025 at 06:32:19PM +0800, Luo Jie wrote:
> ICC clocks are always provided by the NSS clock controller of IPQ9574,
> so add interconnect-cells as required DT property.
Does not make sense. If clocks are always, you require different
property?
>
> Fixes: 28300ecedce4 ("dt-bindings: clock: Add ipq9574 NSSCC clock and reset definitions")
> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
Fixes cannot be in the middle of patchset.
See submitting patches and your internal guideline explaining it with
great details.
> ---
> Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
> index 17252b6ea3be..fc604279114f 100644
> --- a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
> +++ b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
> @@ -57,6 +57,7 @@ required:
> - compatible
> - clocks
> - clock-names
> + - '#interconnect-cells'
ABI break without explanation.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC
2025-08-28 10:32 ` [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC Luo Jie
@ 2025-08-29 7:38 ` Krzysztof Kozlowski
2025-09-02 12:58 ` Luo Jie
0 siblings, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-08-29 7:38 UTC (permalink / raw)
To: Luo Jie
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia
On Thu, Aug 28, 2025 at 06:32:20PM +0800, Luo Jie wrote:
> NSS clock controller provides the clocks and resets to the networking
> blocks such as PPE (Packet Process Engine) and UNIPHY (PCS) on IPQ5424
> devices.
>
> Add support for the compatible string "qcom,ipq5424-nsscc" based on the
> existing IPQ9574 NSS clock controller Device Tree binding. Additionally,
> update the clock names for PPE and NSS for newer SoC additions like
> IPQ5424 to use generic and reusable identifiers "nss" and "ppe" without
> the clock rate suffix.
>
> Also add master/slave ids for IPQ5424 networking interfaces, which is
> used by nss-ipq5424 driver for providing interconnect services using
> icc-clk framework.
>
> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
> ---
> .../bindings/clock/qcom,ipq9574-nsscc.yaml | 62 ++++++++++++++++++---
> include/dt-bindings/clock/qcom,ipq5424-nsscc.h | 65 ++++++++++++++++++++++
> include/dt-bindings/interconnect/qcom,ipq5424.h | 13 +++++
> include/dt-bindings/reset/qcom,ipq5424-nsscc.h | 46 +++++++++++++++
> 4 files changed, 178 insertions(+), 8 deletions(-)
Are you going to change the binding in next version?
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id
2025-08-28 10:32 ` [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id Luo Jie
@ 2025-09-02 12:07 ` Konrad Dybcio
0 siblings, 0 replies; 20+ messages in thread
From: Konrad Dybcio @ 2025-09-02 12:07 UTC (permalink / raw)
To: Luo Jie, Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia
On 8/28/25 12:32 PM, Luo Jie wrote:
> Update to use the expected icc_first_node_id for registering the icc
> clocks, ensuring correct association of clocks with interconnect nodes.
>
> Fixes: 170f3d2c065e ("clk: qcom: ipq5424: Use icc-clk for enabling NoC related clocks")
> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk
2025-08-28 10:32 ` [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk Luo Jie
@ 2025-09-02 12:11 ` Konrad Dybcio
0 siblings, 0 replies; 20+ messages in thread
From: Konrad Dybcio @ 2025-09-02 12:11 UTC (permalink / raw)
To: Luo Jie, Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia
On 8/28/25 12:32 PM, Luo Jie wrote:
> Add NSS NoC clocks using the icc-clk framework to create interconnect
> paths. The network subsystem (NSS) can be connected to these NoCs.
>
> Additionally, add the LPASS CNOC and SNOC nodes to establish the complete
> interconnect path.
>
> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock
2025-08-28 10:32 ` [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock Luo Jie
@ 2025-09-02 12:11 ` Konrad Dybcio
0 siblings, 0 replies; 20+ messages in thread
From: Konrad Dybcio @ 2025-09-02 12:11 UTC (permalink / raw)
To: Luo Jie, Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon
Cc: linux-arm-msm, linux-clk, linux-kernel, linux-pm, devicetree,
Krzysztof Kozlowski, netdev, linux-arm-kernel, quic_kkumarcs,
quic_linchen, quic_leiwei, quic_pavir, quic_suruchia
On 8/28/25 12:32 PM, Luo Jie wrote:
> The clock gpll0_out_aux acts as the parent clock for some of the NSS
> (Network Subsystem) clocks.
>
> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property
2025-08-29 7:37 ` Krzysztof Kozlowski
@ 2025-09-02 12:56 ` Luo Jie
0 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-09-02 12:56 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia
On 8/29/2025 3:37 PM, Krzysztof Kozlowski wrote:
> On Thu, Aug 28, 2025 at 06:32:19PM +0800, Luo Jie wrote:
>> ICC clocks are always provided by the NSS clock controller of IPQ9574,
>> so add interconnect-cells as required DT property.
>
> Does not make sense. If clocks are always, you require different
> property?
The '#interconnect-cells' property is mandatory in the DTS so that the
client driver such as PPE driver can acquire the ICC clocks from the NSS
CC provider. This is already part of the IPQ9574 DTS which is merged. We
had missed adding it as 'Required' at that time and fixing it now.
I will update the commit message to describe this better in the next
version to avoid confusion.
>
>>
>> Fixes: 28300ecedce4 ("dt-bindings: clock: Add ipq9574 NSSCC clock and reset definitions")
>> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
>
> Fixes cannot be in the middle of patchset.
>
> See submitting patches and your internal guideline explaining it with
> great details.
>
I understand that fixes should not be placed in the middle of a
patchset. I will reorder the patches to ensure that all fixes are at the
beginning of the series.
>> ---
>> Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
>> index 17252b6ea3be..fc604279114f 100644
>> --- a/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
>> +++ b/Documentation/devicetree/bindings/clock/qcom,ipq9574-nsscc.yaml
>> @@ -57,6 +57,7 @@ required:
>> - compatible
>> - clocks
>> - clock-names
>> + - '#interconnect-cells'
>
> ABI break without explanation.
>
> Best regards,
> Krzysztof
>
This property is already present in the current IPQ9574 SoC DTS file
which is already merged, and hence no ABI break is introduced for
IPQ9574. I will update the commit message in the next version to clarify
this.
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC
2025-08-29 7:38 ` Krzysztof Kozlowski
@ 2025-09-02 12:58 ` Luo Jie
0 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-09-02 12:58 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia
On 8/29/2025 3:38 PM, Krzysztof Kozlowski wrote:
> On Thu, Aug 28, 2025 at 06:32:20PM +0800, Luo Jie wrote:
>> NSS clock controller provides the clocks and resets to the networking
>> blocks such as PPE (Packet Process Engine) and UNIPHY (PCS) on IPQ5424
>> devices.
>>
>> Add support for the compatible string "qcom,ipq5424-nsscc" based on the
>> existing IPQ9574 NSS clock controller Device Tree binding. Additionally,
>> update the clock names for PPE and NSS for newer SoC additions like
>> IPQ5424 to use generic and reusable identifiers "nss" and "ppe" without
>> the clock rate suffix.
>>
>> Also add master/slave ids for IPQ5424 networking interfaces, which is
>> used by nss-ipq5424 driver for providing interconnect services using
>> icc-clk framework.
>>
>> Signed-off-by: Luo Jie <quic_luoj@quicinc.com>
>> ---
>> .../bindings/clock/qcom,ipq9574-nsscc.yaml | 62 ++++++++++++++++++---
>> include/dt-bindings/clock/qcom,ipq5424-nsscc.h | 65 ++++++++++++++++++++++
>> include/dt-bindings/interconnect/qcom,ipq5424.h | 13 +++++
>> include/dt-bindings/reset/qcom,ipq5424-nsscc.h | 46 +++++++++++++++
>> 4 files changed, 178 insertions(+), 8 deletions(-)
>
>
> Are you going to change the binding in next version?
>
As discussed in response to the comments in IPQ9574 bindings file, I am
not planning to change the binding itself in the next version.
> Best regards,
> Krzysztof
>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC
2025-08-29 7:34 ` [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Krzysztof Kozlowski
@ 2025-09-02 13:01 ` Luo Jie
0 siblings, 0 replies; 20+ messages in thread
From: Luo Jie @ 2025-09-02 13:01 UTC (permalink / raw)
To: Krzysztof Kozlowski
Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd,
Varadarajan Narayanan, Georgi Djakov, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Anusha Rao,
Manikanta Mylavarapu, Devi Priya, Philipp Zabel, Richard Cochran,
Konrad Dybcio, Catalin Marinas, Will Deacon, linux-arm-msm,
linux-clk, linux-kernel, linux-pm, devicetree, netdev,
linux-arm-kernel, quic_kkumarcs, quic_linchen, quic_leiwei,
quic_pavir, quic_suruchia, Konrad Dybcio
On 8/29/2025 3:34 PM, Krzysztof Kozlowski wrote:
> On Thu, Aug 28, 2025 at 06:32:13PM +0800, Luo Jie wrote:
>> - Remove the Acked-by tag from the "Add Qualcomm IPQ5424 NSSNOC IDs" patch"
>> as the new NOC IDs are added.
>
> So let's wait for v6 with acking :/
OK. The next version should be V5.
>
> Best regards,
> Krzysztof
>
^ permalink raw reply [flat|nested] 20+ messages in thread
end of thread, other threads:[~2025-09-02 13:01 UTC | newest]
Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-28 10:32 [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Luo Jie
2025-08-28 10:32 ` [PATCH v4 01/10] clk: qcom: gcc-ipq5424: Correct the icc_first_node_id Luo Jie
2025-09-02 12:07 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 02/10] dt-bindings: interconnect: Add Qualcomm IPQ5424 NSSNOC IDs Luo Jie
2025-08-28 10:32 ` [PATCH v4 03/10] clk: qcom: gcc-ipq5424: Enable NSS NoC clocks to use icc-clk Luo Jie
2025-09-02 12:11 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 04/10] dt-bindings: clock: gcc-ipq5424: Add definition for GPLL0_OUT_AUX Luo Jie
2025-08-28 10:32 ` [PATCH v4 05/10] clk: qcom: gcc-ipq5424: Add gpll0_out_aux clock Luo Jie
2025-09-02 12:11 ` Konrad Dybcio
2025-08-28 10:32 ` [PATCH v4 06/10] dt-bindings: clock: Add required "interconnect-cells" property Luo Jie
2025-08-29 7:37 ` Krzysztof Kozlowski
2025-09-02 12:56 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 07/10] dt-bindings: clock: qcom: Add NSS clock controller for IPQ5424 SoC Luo Jie
2025-08-29 7:38 ` Krzysztof Kozlowski
2025-09-02 12:58 ` Luo Jie
2025-08-28 10:32 ` [PATCH v4 08/10] clk: qcom: Add NSS clock controller driver for IPQ5424 Luo Jie
2025-08-28 10:32 ` [PATCH v4 09/10] arm64: dts: qcom: ipq5424: Add NSS clock controller node Luo Jie
2025-08-28 10:32 ` [PATCH v4 10/10] arm64: defconfig: Build NSS clock controller driver for IPQ5424 Luo Jie
2025-08-29 7:34 ` [PATCH v4 00/10] Add Network Subsystem (NSS) clock controller support for IPQ5424 SoC Krzysztof Kozlowski
2025-09-02 13:01 ` Luo Jie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).