* [PATCH v4 1/4] clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
@ 2026-01-29 9:54 ` Lukasz Majewski
2026-01-29 9:54 ` [PATCH v4 2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define Lukasz Majewski
` (4 subsequent siblings)
5 siblings, 0 replies; 12+ messages in thread
From: Lukasz Majewski @ 2026-01-29 9:54 UTC (permalink / raw)
To: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel, Lukasz Majewski
The VF610_CLK_END was previously defined in vf610-clock.h to indicate
the number of clocks.
It is solely used in the clk driver to allocate proper size of the clk
table.
Moreover, when new clocks (like e.g. ones for MTIP L2 switch) are defined
its value also changes, so it shall be locally adjusted.
Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
---
Changes for v4:
- Separate patch
- Add comment regarding value of VF610_CLK_END
---
drivers/clk/imx/clk-vf610.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/clk/imx/clk-vf610.c b/drivers/clk/imx/clk-vf610.c
index 9e11f1c7c397..457156944c67 100644
--- a/drivers/clk/imx/clk-vf610.c
+++ b/drivers/clk/imx/clk-vf610.c
@@ -11,6 +11,13 @@
#include "clk.h"
+/*
+ * The VF610_CLK_END corresponds to ones defined in
+ * include/dt-bindings/clock/vf610-clock.h
+ * It shall be the value of the last defined clock +1
+ */
+#define VF610_CLK_END 191
+
#define CCM_CCR (ccm_base + 0x00)
#define CCM_CSR (ccm_base + 0x04)
#define CCM_CCSR (ccm_base + 0x08)
--
2.39.5
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v4 2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
2026-01-29 9:54 ` [PATCH v4 1/4] clk: vf610: Move VF610_CLK_END define to clk-vf610 driver Lukasz Majewski
@ 2026-01-29 9:54 ` Lukasz Majewski
2026-01-29 16:56 ` Rob Herring (Arm)
2026-01-29 9:54 ` [PATCH v4 3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch Lukasz Majewski
` (3 subsequent siblings)
5 siblings, 1 reply; 12+ messages in thread
From: Lukasz Majewski @ 2026-01-29 9:54 UTC (permalink / raw)
To: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel, Lukasz Majewski
The VF610_CLK_END should be dropped as it is not part of the ABI.
Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
---
Changes for v4:
- New, separate patch
---
include/dt-bindings/clock/vf610-clock.h | 1 -
1 file changed, 1 deletion(-)
diff --git a/include/dt-bindings/clock/vf610-clock.h b/include/dt-bindings/clock/vf610-clock.h
index 373644e46747..c91fb86fa9a1 100644
--- a/include/dt-bindings/clock/vf610-clock.h
+++ b/include/dt-bindings/clock/vf610-clock.h
@@ -197,6 +197,5 @@
#define VF610_CLK_TCON1 188
#define VF610_CLK_CAAM 189
#define VF610_CLK_CRC 190
-#define VF610_CLK_END 191
#endif /* __DT_BINDINGS_CLOCK_VF610_H */
--
2.39.5
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [PATCH v4 2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define
2026-01-29 9:54 ` [PATCH v4 2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define Lukasz Majewski
@ 2026-01-29 16:56 ` Rob Herring (Arm)
0 siblings, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2026-01-29 16:56 UTC (permalink / raw)
To: Lukasz Majewski
Cc: imx, Stephen Boyd, linux-clk, linux-kernel, Fabio Estevam,
Peng Fan, Krzysztof Kozlowski, devicetree, Shawn Guo,
Conor Dooley, linux-arm-kernel, Michael Turquette,
Pengutronix Kernel Team, Abel Vesa, Sascha Hauer
On Thu, 29 Jan 2026 10:54:40 +0100, Lukasz Majewski wrote:
> The VF610_CLK_END should be dropped as it is not part of the ABI.
>
> Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
> ---
> Changes for v4:
> - New, separate patch
> ---
> include/dt-bindings/clock/vf610-clock.h | 1 -
> 1 file changed, 1 deletion(-)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH v4 3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
2026-01-29 9:54 ` [PATCH v4 1/4] clk: vf610: Move VF610_CLK_END define to clk-vf610 driver Lukasz Majewski
2026-01-29 9:54 ` [PATCH v4 2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define Lukasz Majewski
@ 2026-01-29 9:54 ` Lukasz Majewski
2026-01-29 16:57 ` Rob Herring (Arm)
2026-01-29 9:54 ` [PATCH v4 4/4] clk: vf610: Add support for the Ethernet switch clocks Lukasz Majewski
` (2 subsequent siblings)
5 siblings, 1 reply; 12+ messages in thread
From: Lukasz Majewski @ 2026-01-29 9:54 UTC (permalink / raw)
To: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel, Lukasz Majewski
This patch adds VF610_CLK_ESW and VF610_CLK_ESW_MAC_TAB{0123}
macros definitions for L2 switch.
Those definitions describe clocks for MoreThanIP switch IP block;
the switch itself and the MAC address lookup table clocks.
Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
---
Changes for v4:
- Do not change VF610_CLK_END
---
include/dt-bindings/clock/vf610-clock.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/include/dt-bindings/clock/vf610-clock.h b/include/dt-bindings/clock/vf610-clock.h
index c91fb86fa9a1..5d94bd561a2e 100644
--- a/include/dt-bindings/clock/vf610-clock.h
+++ b/include/dt-bindings/clock/vf610-clock.h
@@ -197,5 +197,10 @@
#define VF610_CLK_TCON1 188
#define VF610_CLK_CAAM 189
#define VF610_CLK_CRC 190
+#define VF610_CLK_ESW 191
+#define VF610_CLK_ESW_MAC_TAB0 192
+#define VF610_CLK_ESW_MAC_TAB1 193
+#define VF610_CLK_ESW_MAC_TAB2 194
+#define VF610_CLK_ESW_MAC_TAB3 195
#endif /* __DT_BINDINGS_CLOCK_VF610_H */
--
2.39.5
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [PATCH v4 3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
2026-01-29 9:54 ` [PATCH v4 3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch Lukasz Majewski
@ 2026-01-29 16:57 ` Rob Herring (Arm)
0 siblings, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2026-01-29 16:57 UTC (permalink / raw)
To: Lukasz Majewski
Cc: Sascha Hauer, Pengutronix Kernel Team, Michael Turquette,
linux-kernel, Krzysztof Kozlowski, linux-clk, Conor Dooley,
Abel Vesa, linux-arm-kernel, imx, devicetree, Peng Fan,
Fabio Estevam, Stephen Boyd, Shawn Guo
On Thu, 29 Jan 2026 10:54:41 +0100, Lukasz Majewski wrote:
> This patch adds VF610_CLK_ESW and VF610_CLK_ESW_MAC_TAB{0123}
> macros definitions for L2 switch.
>
> Those definitions describe clocks for MoreThanIP switch IP block;
> the switch itself and the MAC address lookup table clocks.
>
> Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
> ---
> Changes for v4:
> - Do not change VF610_CLK_END
> ---
> include/dt-bindings/clock/vf610-clock.h | 5 +++++
> 1 file changed, 5 insertions(+)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH v4 4/4] clk: vf610: Add support for the Ethernet switch clocks
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
` (2 preceding siblings ...)
2026-01-29 9:54 ` [PATCH v4 3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch Lukasz Majewski
@ 2026-01-29 9:54 ` Lukasz Majewski
2026-02-02 1:56 ` [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Peng Fan
2026-03-18 15:39 ` Abel Vesa
5 siblings, 0 replies; 12+ messages in thread
From: Lukasz Majewski @ 2026-01-29 9:54 UTC (permalink / raw)
To: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel, Lukasz Majewski
The vf610 device has built in the MoreThanIP L2 switch. For proper
operation it is required to enable ESW and MAC table lookup
clocks.
The MAC table spans from 0x400E_C000 for 0x4000 and it is necessary
to provide clocks for each AIPS1-"slot", which size is 0x1000
(hence four separate entries).
Those can be enabled via clock gating CCM_CCGR10 register
(0x4006_B068).
Signed-off-by: Lukasz Majewski <lukma@nabladev.com>
---
Changes for v4:
- Adjust VF610_CLK_END
---
drivers/clk/imx/clk-vf610.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-vf610.c b/drivers/clk/imx/clk-vf610.c
index 457156944c67..766119a86841 100644
--- a/drivers/clk/imx/clk-vf610.c
+++ b/drivers/clk/imx/clk-vf610.c
@@ -16,7 +16,7 @@
* include/dt-bindings/clock/vf610-clock.h
* It shall be the value of the last defined clock +1
*/
-#define VF610_CLK_END 191
+#define VF610_CLK_END 196
#define CCM_CCR (ccm_base + 0x00)
#define CCM_CSR (ccm_base + 0x04)
@@ -316,6 +316,11 @@ static void __init vf610_clocks_init(struct device_node *ccm_node)
clk[VF610_CLK_ENET_TS] = imx_clk_gate("enet_ts", "enet_ts_sel", CCM_CSCDR1, 23);
clk[VF610_CLK_ENET0] = imx_clk_gate2("enet0", "ipg_bus", CCM_CCGR9, CCM_CCGRx_CGn(0));
clk[VF610_CLK_ENET1] = imx_clk_gate2("enet1", "ipg_bus", CCM_CCGR9, CCM_CCGRx_CGn(1));
+ clk[VF610_CLK_ESW] = imx_clk_gate2("esw", "ipg_bus", CCM_CCGR10, CCM_CCGRx_CGn(8));
+ clk[VF610_CLK_ESW_MAC_TAB0] = imx_clk_gate2("esw_tab0", "ipg_bus", CCM_CCGR10, CCM_CCGRx_CGn(12));
+ clk[VF610_CLK_ESW_MAC_TAB1] = imx_clk_gate2("esw_tab1", "ipg_bus", CCM_CCGR10, CCM_CCGRx_CGn(13));
+ clk[VF610_CLK_ESW_MAC_TAB2] = imx_clk_gate2("esw_tab2", "ipg_bus", CCM_CCGR10, CCM_CCGRx_CGn(14));
+ clk[VF610_CLK_ESW_MAC_TAB3] = imx_clk_gate2("esw_tab3", "ipg_bus", CCM_CCGR10, CCM_CCGRx_CGn(15));
clk[VF610_CLK_PIT] = imx_clk_gate2("pit", "ipg_bus", CCM_CCGR1, CCM_CCGRx_CGn(7));
--
2.39.5
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
` (3 preceding siblings ...)
2026-01-29 9:54 ` [PATCH v4 4/4] clk: vf610: Add support for the Ethernet switch clocks Lukasz Majewski
@ 2026-02-02 1:56 ` Peng Fan
2026-02-16 9:15 ` Łukasz Majewski
2026-03-18 15:39 ` Abel Vesa
5 siblings, 1 reply; 12+ messages in thread
From: Peng Fan @ 2026-02-02 1:56 UTC (permalink / raw)
To: Lukasz Majewski
Cc: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Shawn Guo, Sascha Hauer,
Pengutronix Kernel Team, Fabio Estevam, linux-clk, devicetree,
linux-kernel, imx, linux-arm-kernel
On Thu, Jan 29, 2026 at 10:54:38AM +0100, Lukasz Majewski wrote:
>This patch series:
>- cleans up clocks' setup on vf610 by moving VF610_CLK_END define
> to driver code
>- introduces support for several clocks required by MTIP switch IP block
>
>Lukasz Majewski (4):
> clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
> dt-bindings: clock: vf610: Drop VF610_CLK_END define
> dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
> clk: vf610: Add support for the Ethernet switch clocks
Reviewed-by: Peng Fan <peng.fan@nxp.com>
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch
2026-02-02 1:56 ` [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Peng Fan
@ 2026-02-16 9:15 ` Łukasz Majewski
2026-02-16 10:32 ` Abel Vesa
0 siblings, 1 reply; 12+ messages in thread
From: Łukasz Majewski @ 2026-02-16 9:15 UTC (permalink / raw)
To: Peng Fan, Abel Vesa
Cc: Peng Fan, Michael Turquette, Stephen Boyd, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Shawn Guo, Sascha Hauer,
Pengutronix Kernel Team, Fabio Estevam, linux-clk, devicetree,
linux-kernel, imx, linux-arm-kernel
Dear all,
> On Thu, Jan 29, 2026 at 10:54:38AM +0100, Lukasz Majewski wrote:
> >This patch series:
> >- cleans up clocks' setup on vf610 by moving VF610_CLK_END define
> > to driver code
> >- introduces support for several clocks required by MTIP switch IP
> >block
> >
> >Lukasz Majewski (4):
> > clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
> > dt-bindings: clock: vf610: Drop VF610_CLK_END define
> > dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
> > clk: vf610: Add support for the Ethernet switch clocks
>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
Gentle ping regarding this patch set...
--
Best regards,
Lukasz Majewski
--
Nabla Software Engineering GmbH
HRB 40522 Augsburg
Phone: +49 821 45592596
E-Mail: office@nabladev.com
Managing Director : Stefano Babic
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch
2026-02-16 9:15 ` Łukasz Majewski
@ 2026-02-16 10:32 ` Abel Vesa
2026-02-16 11:33 ` Łukasz Majewski
0 siblings, 1 reply; 12+ messages in thread
From: Abel Vesa @ 2026-02-16 10:32 UTC (permalink / raw)
To: Łukasz Majewski
Cc: Peng Fan, Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel
On 26-02-16 10:15:38, Łukasz Majewski wrote:
> Dear all,
>
> > On Thu, Jan 29, 2026 at 10:54:38AM +0100, Lukasz Majewski wrote:
> > >This patch series:
> > >- cleans up clocks' setup on vf610 by moving VF610_CLK_END define
> > > to driver code
> > >- introduces support for several clocks required by MTIP switch IP
> > >block
> > >
> > >Lukasz Majewski (4):
> > > clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
> > > dt-bindings: clock: vf610: Drop VF610_CLK_END define
> > > dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
> > > clk: vf610: Add support for the Ethernet switch clocks
> >
> > Reviewed-by: Peng Fan <peng.fan@nxp.com>
>
> Gentle ping regarding this patch set...
Will apply after rc1.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch
2026-02-16 10:32 ` Abel Vesa
@ 2026-02-16 11:33 ` Łukasz Majewski
0 siblings, 0 replies; 12+ messages in thread
From: Łukasz Majewski @ 2026-02-16 11:33 UTC (permalink / raw)
To: Abel Vesa
Cc: Peng Fan, Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd,
Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel
Hi Abel,
> On 26-02-16 10:15:38, Łukasz Majewski wrote:
> > Dear all,
> >
> > > On Thu, Jan 29, 2026 at 10:54:38AM +0100, Lukasz Majewski wrote:
> > > >This patch series:
> > > >- cleans up clocks' setup on vf610 by moving VF610_CLK_END define
> > > > to driver code
> > > >- introduces support for several clocks required by MTIP switch
> > > >IP block
> > > >
> > > >Lukasz Majewski (4):
> > > > clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
> > > > dt-bindings: clock: vf610: Drop VF610_CLK_END define
> > > > dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
> > > > clk: vf610: Add support for the Ethernet switch clocks
> > >
> > > Reviewed-by: Peng Fan <peng.fan@nxp.com>
> >
> > Gentle ping regarding this patch set...
>
> Will apply after rc1.
Thanks :-)
--
Best regards,
Lukasz Majewski
--
Nabla Software Engineering GmbH
HRB 40522 Augsburg
Phone: +49 821 45592596
E-Mail: office@nabladev.com
Managing Director : Stefano Babic
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch
2026-01-29 9:54 [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Lukasz Majewski
` (4 preceding siblings ...)
2026-02-02 1:56 ` [PATCH v4 0/4] clk: vf610: Add clocks to support MTIP L2 switch Peng Fan
@ 2026-03-18 15:39 ` Abel Vesa
5 siblings, 0 replies; 12+ messages in thread
From: Abel Vesa @ 2026-03-18 15:39 UTC (permalink / raw)
To: Abel Vesa, Peng Fan, Michael Turquette, Stephen Boyd,
Lukasz Majewski
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, linux-clk,
devicetree, linux-kernel, imx, linux-arm-kernel
On Thu, 29 Jan 2026 10:54:38 +0100, Lukasz Majewski wrote:
> This patch series:
> - cleans up clocks' setup on vf610 by moving VF610_CLK_END define
> to driver code
> - introduces support for several clocks required by MTIP switch IP block
>
> Lukasz Majewski (4):
> clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
> dt-bindings: clock: vf610: Drop VF610_CLK_END define
> dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
> clk: vf610: Add support for the Ethernet switch clocks
>
> [...]
Applied, thanks!
[1/4] clk: vf610: Move VF610_CLK_END define to clk-vf610 driver
commit: 2c53aa5878f9abe6975ca45591b8e3357794c0e4
[2/4] dt-bindings: clock: vf610: Drop VF610_CLK_END define
commit: 216ad764f8d8c53b85cc74f6090f8d132772fec4
[3/4] dt-bindings: clock: vf610: Add definitions for MTIP L2 switch
commit: 819bfc68251484bb9ba4b6cf91279a80c0fd7047
[4/4] clk: vf610: Add support for the Ethernet switch clocks
commit: 5567730bd36614d8099d73520760c298e80e0fc5
Best regards,
--
Abel Vesa <abel.vesa@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 12+ messages in thread