* [PATCH 0/6] clk: imx93: fix and update
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan
From: Peng Fan <peng.fan@nxp.com>
patch 1 is reported by Dan and marked as fix
During our development, per updated reference mannual and design
information, correct enet and drop tpm 1/3, lpit 1/2.
The TPM/LPIT patch 3,4 are not marked as fixes, there is no user,
so update binding and driver both.
Patch 5 enable HSIO root always on
Patch 6 enable sysctr always on for cpuidle
Jacky Bai (2):
clk: imx: keep hsio bus clock always on
clk: imx93: keep sys ctr clock always on
Peng Fan (4):
clk: imx93: unmap anatop base in error handling path
clk: imx93: correct enet clock
dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
clk: imx93: drop tpm1/3, lpit1/2 clk
drivers/clk/imx/clk-imx93.c | 33 ++++++++++++-------------
include/dt-bindings/clock/imx93-clock.h | 4 ---
2 files changed, 16 insertions(+), 21 deletions(-)
--
2.37.1
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH 0/6] clk: imx93: fix and update
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan
From: Peng Fan <peng.fan@nxp.com>
patch 1 is reported by Dan and marked as fix
During our development, per updated reference mannual and design
information, correct enet and drop tpm 1/3, lpit 1/2.
The TPM/LPIT patch 3,4 are not marked as fixes, there is no user,
so update binding and driver both.
Patch 5 enable HSIO root always on
Patch 6 enable sysctr always on for cpuidle
Jacky Bai (2):
clk: imx: keep hsio bus clock always on
clk: imx93: keep sys ctr clock always on
Peng Fan (4):
clk: imx93: unmap anatop base in error handling path
clk: imx93: correct enet clock
dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
clk: imx93: drop tpm1/3, lpit1/2 clk
drivers/clk/imx/clk-imx93.c | 33 ++++++++++++-------------
include/dt-bindings/clock/imx93-clock.h | 4 ---
2 files changed, 16 insertions(+), 21 deletions(-)
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH 1/6] clk: imx93: unmap anatop base in error handling path
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Dan Carpenter
From: Peng Fan <peng.fan@nxp.com>
The anatop base is not unmapped during error handling path, fix it.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 99cff1fd108b..9ef3fcbdd951 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -258,7 +258,7 @@ static int imx93_clocks_probe(struct platform_device *pdev)
struct device_node *np = dev->of_node;
const struct imx93_clk_root *root;
const struct imx93_clk_ccgr *ccgr;
- void __iomem *base = NULL;
+ void __iomem *base, *anatop_base;
int i, ret;
clk_hw_data = kzalloc(struct_size(clk_hw_data, hws,
@@ -285,20 +285,22 @@ static int imx93_clocks_probe(struct platform_device *pdev)
"sys_pll_pfd2", 1, 2);
np = of_find_compatible_node(NULL, NULL, "fsl,imx93-anatop");
- base = of_iomap(np, 0);
+ anatop_base = of_iomap(np, 0);
of_node_put(np);
- if (WARN_ON(!base))
+ if (WARN_ON(!anatop_base))
return -ENOMEM;
- clks[IMX93_CLK_AUDIO_PLL] = imx_clk_fracn_gppll("audio_pll", "osc_24m", base + 0x1200,
+ clks[IMX93_CLK_AUDIO_PLL] = imx_clk_fracn_gppll("audio_pll", "osc_24m", anatop_base + 0x1200,
&imx_fracn_gppll);
- clks[IMX93_CLK_VIDEO_PLL] = imx_clk_fracn_gppll("video_pll", "osc_24m", base + 0x1400,
+ clks[IMX93_CLK_VIDEO_PLL] = imx_clk_fracn_gppll("video_pll", "osc_24m", anatop_base + 0x1400,
&imx_fracn_gppll);
np = dev->of_node;
base = devm_platform_ioremap_resource(pdev, 0);
- if (WARN_ON(IS_ERR(base)))
+ if (WARN_ON(IS_ERR(base))) {
+ iounmap(anatop_base);
return PTR_ERR(base);
+ }
for (i = 0; i < ARRAY_SIZE(root_array); i++) {
root = &root_array[i];
@@ -327,6 +329,7 @@ static int imx93_clocks_probe(struct platform_device *pdev)
unregister_hws:
imx_unregister_hw_clocks(clks, IMX93_CLK_END);
+ iounmap(anatop_base);
return ret;
}
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 1/6] clk: imx93: unmap anatop base in error handling path
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Dan Carpenter
From: Peng Fan <peng.fan@nxp.com>
The anatop base is not unmapped during error handling path, fix it.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 99cff1fd108b..9ef3fcbdd951 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -258,7 +258,7 @@ static int imx93_clocks_probe(struct platform_device *pdev)
struct device_node *np = dev->of_node;
const struct imx93_clk_root *root;
const struct imx93_clk_ccgr *ccgr;
- void __iomem *base = NULL;
+ void __iomem *base, *anatop_base;
int i, ret;
clk_hw_data = kzalloc(struct_size(clk_hw_data, hws,
@@ -285,20 +285,22 @@ static int imx93_clocks_probe(struct platform_device *pdev)
"sys_pll_pfd2", 1, 2);
np = of_find_compatible_node(NULL, NULL, "fsl,imx93-anatop");
- base = of_iomap(np, 0);
+ anatop_base = of_iomap(np, 0);
of_node_put(np);
- if (WARN_ON(!base))
+ if (WARN_ON(!anatop_base))
return -ENOMEM;
- clks[IMX93_CLK_AUDIO_PLL] = imx_clk_fracn_gppll("audio_pll", "osc_24m", base + 0x1200,
+ clks[IMX93_CLK_AUDIO_PLL] = imx_clk_fracn_gppll("audio_pll", "osc_24m", anatop_base + 0x1200,
&imx_fracn_gppll);
- clks[IMX93_CLK_VIDEO_PLL] = imx_clk_fracn_gppll("video_pll", "osc_24m", base + 0x1400,
+ clks[IMX93_CLK_VIDEO_PLL] = imx_clk_fracn_gppll("video_pll", "osc_24m", anatop_base + 0x1400,
&imx_fracn_gppll);
np = dev->of_node;
base = devm_platform_ioremap_resource(pdev, 0);
- if (WARN_ON(IS_ERR(base)))
+ if (WARN_ON(IS_ERR(base))) {
+ iounmap(anatop_base);
return PTR_ERR(base);
+ }
for (i = 0; i < ARRAY_SIZE(root_array); i++) {
root = &root_array[i];
@@ -327,6 +329,7 @@ static int imx93_clocks_probe(struct platform_device *pdev)
unregister_hws:
imx_unregister_hw_clocks(clks, IMX93_CLK_END);
+ iounmap(anatop_base);
return ret;
}
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 2/6] clk: imx93: correct enet clock
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Ye Li
From: Peng Fan <peng.fan@nxp.com>
Per update Reference Mannual, correct the enet clock parent to
wakeup_axi_root.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 9ef3fcbdd951..7fdc30062a46 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
{ IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
- { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
+ { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
{ IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 2/6] clk: imx93: correct enet clock
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Ye Li
From: Peng Fan <peng.fan@nxp.com>
Per update Reference Mannual, correct the enet clock parent to
wakeup_axi_root.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 9ef3fcbdd951..7fdc30062a46 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
{ IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
- { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
+ { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
{ IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 3/6] dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
From: Peng Fan <peng.fan@nxp.com>
Per updated Reference Mannual, the TPM[1,3] LPIT[1,2] root clock entries
are reserved. So drop them.
Reviewed-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
include/dt-bindings/clock/imx93-clock.h | 4 ----
1 file changed, 4 deletions(-)
diff --git a/include/dt-bindings/clock/imx93-clock.h b/include/dt-bindings/clock/imx93-clock.h
index 19bc32788d81..8e02859d8ce2 100644
--- a/include/dt-bindings/clock/imx93-clock.h
+++ b/include/dt-bindings/clock/imx93-clock.h
@@ -28,13 +28,9 @@
#define IMX93_CLK_M33_SYSTICK 19
#define IMX93_CLK_FLEXIO1 20
#define IMX93_CLK_FLEXIO2 21
-#define IMX93_CLK_LPIT1 22
-#define IMX93_CLK_LPIT2 23
#define IMX93_CLK_LPTMR1 24
#define IMX93_CLK_LPTMR2 25
-#define IMX93_CLK_TPM1 26
#define IMX93_CLK_TPM2 27
-#define IMX93_CLK_TPM3 28
#define IMX93_CLK_TPM4 29
#define IMX93_CLK_TPM5 30
#define IMX93_CLK_TPM6 31
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 3/6] dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
From: Peng Fan <peng.fan@nxp.com>
Per updated Reference Mannual, the TPM[1,3] LPIT[1,2] root clock entries
are reserved. So drop them.
Reviewed-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
include/dt-bindings/clock/imx93-clock.h | 4 ----
1 file changed, 4 deletions(-)
diff --git a/include/dt-bindings/clock/imx93-clock.h b/include/dt-bindings/clock/imx93-clock.h
index 19bc32788d81..8e02859d8ce2 100644
--- a/include/dt-bindings/clock/imx93-clock.h
+++ b/include/dt-bindings/clock/imx93-clock.h
@@ -28,13 +28,9 @@
#define IMX93_CLK_M33_SYSTICK 19
#define IMX93_CLK_FLEXIO1 20
#define IMX93_CLK_FLEXIO2 21
-#define IMX93_CLK_LPIT1 22
-#define IMX93_CLK_LPIT2 23
#define IMX93_CLK_LPTMR1 24
#define IMX93_CLK_LPTMR2 25
-#define IMX93_CLK_TPM1 26
#define IMX93_CLK_TPM2 27
-#define IMX93_CLK_TPM3 28
#define IMX93_CLK_TPM4 29
#define IMX93_CLK_TPM5 30
#define IMX93_CLK_TPM6 31
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 4/6] clk: imx93: drop tpm1/3, lpit1/2 clk
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
From: Peng Fan <peng.fan@nxp.com>
Per Reference Mannual System Clocks Table,
LPIT1 and TPM1 sources from bus_aon_root
LPIT2 and TPM3 sources from bus_wakeup_root
So update driver to reflect that.
Reviewed-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 7fdc30062a46..422ad3c89845 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -64,13 +64,9 @@ static const struct imx93_clk_root {
{ IMX93_CLK_M33_SYSTICK, "m33_systick_root", 0x0480, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_FLEXIO1, "flexio1_root", 0x0500, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_FLEXIO2, "flexio2_root", 0x0580, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_LPIT1, "lpit1_root", 0x0600, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_LPIT2, "lpit2_root", 0x0680, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_LPTMR1, "lptmr1_root", 0x0700, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_LPTMR2, "lptmr2_root", 0x0780, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_TPM1, "tpm1_root", 0x0800, TPM_SEL, },
{ IMX93_CLK_TPM2, "tpm2_root", 0x0880, TPM_SEL, },
- { IMX93_CLK_TPM3, "tpm3_root", 0x0900, TPM_SEL, },
{ IMX93_CLK_TPM4, "tpm4_root", 0x0980, TPM_SEL, },
{ IMX93_CLK_TPM5, "tpm5_root", 0x0a00, TPM_SEL, },
{ IMX93_CLK_TPM6, "tpm6_root", 0x0a80, TPM_SEL, },
@@ -177,13 +173,13 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_GPIO4_GATE, "gpio4", "bus_wakeup_root", 0x8940, },
{ IMX93_CLK_FLEXIO1_GATE, "flexio1", "flexio1_root", 0x8980, },
{ IMX93_CLK_FLEXIO2_GATE, "flexio2", "flexio2_root", 0x89c0, },
- { IMX93_CLK_LPIT1_GATE, "lpit1", "lpit1_root", 0x8a00, },
- { IMX93_CLK_LPIT2_GATE, "lpit2", "lpit2_root", 0x8a40, },
+ { IMX93_CLK_LPIT1_GATE, "lpit1", "bus_aon_root", 0x8a00, },
+ { IMX93_CLK_LPIT2_GATE, "lpit2", "bus_wakeup_root", 0x8a40, },
{ IMX93_CLK_LPTMR1_GATE, "lptmr1", "lptmr1_root", 0x8a80, },
{ IMX93_CLK_LPTMR2_GATE, "lptmr2", "lptmr2_root", 0x8ac0, },
- { IMX93_CLK_TPM1_GATE, "tpm1", "tpm1_root", 0x8b00, },
+ { IMX93_CLK_TPM1_GATE, "tpm1", "bus_aon_root", 0x8b00, },
{ IMX93_CLK_TPM2_GATE, "tpm2", "tpm2_root", 0x8b40, },
- { IMX93_CLK_TPM3_GATE, "tpm3", "tpm3_root", 0x8b80, },
+ { IMX93_CLK_TPM3_GATE, "tpm3", "bus_wakeup_root", 0x8b80, },
{ IMX93_CLK_TPM4_GATE, "tpm4", "tpm4_root", 0x8bc0, },
{ IMX93_CLK_TPM5_GATE, "tpm5", "tpm5_root", 0x8c00, },
{ IMX93_CLK_TPM6_GATE, "tpm6", "tpm6_root", 0x8c40, },
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 4/6] clk: imx93: drop tpm1/3, lpit1/2 clk
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
From: Peng Fan <peng.fan@nxp.com>
Per Reference Mannual System Clocks Table,
LPIT1 and TPM1 sources from bus_aon_root
LPIT2 and TPM3 sources from bus_wakeup_root
So update driver to reflect that.
Reviewed-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 7fdc30062a46..422ad3c89845 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -64,13 +64,9 @@ static const struct imx93_clk_root {
{ IMX93_CLK_M33_SYSTICK, "m33_systick_root", 0x0480, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_FLEXIO1, "flexio1_root", 0x0500, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_FLEXIO2, "flexio2_root", 0x0580, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_LPIT1, "lpit1_root", 0x0600, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_LPIT2, "lpit2_root", 0x0680, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_LPTMR1, "lptmr1_root", 0x0700, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_LPTMR2, "lptmr2_root", 0x0780, LOW_SPEED_IO_SEL, },
- { IMX93_CLK_TPM1, "tpm1_root", 0x0800, TPM_SEL, },
{ IMX93_CLK_TPM2, "tpm2_root", 0x0880, TPM_SEL, },
- { IMX93_CLK_TPM3, "tpm3_root", 0x0900, TPM_SEL, },
{ IMX93_CLK_TPM4, "tpm4_root", 0x0980, TPM_SEL, },
{ IMX93_CLK_TPM5, "tpm5_root", 0x0a00, TPM_SEL, },
{ IMX93_CLK_TPM6, "tpm6_root", 0x0a80, TPM_SEL, },
@@ -177,13 +173,13 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_GPIO4_GATE, "gpio4", "bus_wakeup_root", 0x8940, },
{ IMX93_CLK_FLEXIO1_GATE, "flexio1", "flexio1_root", 0x8980, },
{ IMX93_CLK_FLEXIO2_GATE, "flexio2", "flexio2_root", 0x89c0, },
- { IMX93_CLK_LPIT1_GATE, "lpit1", "lpit1_root", 0x8a00, },
- { IMX93_CLK_LPIT2_GATE, "lpit2", "lpit2_root", 0x8a40, },
+ { IMX93_CLK_LPIT1_GATE, "lpit1", "bus_aon_root", 0x8a00, },
+ { IMX93_CLK_LPIT2_GATE, "lpit2", "bus_wakeup_root", 0x8a40, },
{ IMX93_CLK_LPTMR1_GATE, "lptmr1", "lptmr1_root", 0x8a80, },
{ IMX93_CLK_LPTMR2_GATE, "lptmr2", "lptmr2_root", 0x8ac0, },
- { IMX93_CLK_TPM1_GATE, "tpm1", "tpm1_root", 0x8b00, },
+ { IMX93_CLK_TPM1_GATE, "tpm1", "bus_aon_root", 0x8b00, },
{ IMX93_CLK_TPM2_GATE, "tpm2", "tpm2_root", 0x8b40, },
- { IMX93_CLK_TPM3_GATE, "tpm3", "tpm3_root", 0x8b80, },
+ { IMX93_CLK_TPM3_GATE, "tpm3", "bus_wakeup_root", 0x8b80, },
{ IMX93_CLK_TPM4_GATE, "tpm4", "tpm4_root", 0x8bc0, },
{ IMX93_CLK_TPM5_GATE, "tpm5", "tpm5_root", 0x8c00, },
{ IMX93_CLK_TPM6_GATE, "tpm6", "tpm6_root", 0x8c40, },
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 5/6] clk: imx: keep hsio bus clock always on
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
From: Jacky Bai <ping.bai@nxp.com>
During Linux System suspend/resume stress test after System Sleep
enabled, system will stuck sometimes. It is because NICMIX is powered
down, which HSIOMIX(always on) is not powered down. When NICMIX
powering down, HSIOMIX will get a hardware handshake, without HSIO ROOT
clk, the handshake will lose. Then after NICMIX power on when system
resume, the access to HSIOMIX through NICMIX would be broken. So keep HSIO
ROOT always on.
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
[Peng Fan] rewrite commit message
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 422ad3c89845..74e8d810db7f 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -109,7 +109,7 @@ static const struct imx93_clk_root {
{ IMX93_CLK_CCM_CKO2, "ccm_cko2_root", 0x1d00, CKO2_SEL, },
{ IMX93_CLK_CCM_CKO3, "ccm_cko3_root", 0x1d80, CKO1_SEL, },
{ IMX93_CLK_CCM_CKO4, "ccm_cko4_root", 0x1e00, CKO2_SEL, },
- { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, },
+ { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, CLK_IS_CRITICAL},
{ IMX93_CLK_HSIO_USB_TEST_60M, "hsio_usb_test_60m_root", 0x1f00, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_HSIO_ACSCAN_80M, "hsio_acscan_80m_root", 0x1f80, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_HSIO_ACSCAN_480M, "hsio_acscan_480m_root", 0x2000, MISC_SEL, },
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 5/6] clk: imx: keep hsio bus clock always on
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
From: Jacky Bai <ping.bai@nxp.com>
During Linux System suspend/resume stress test after System Sleep
enabled, system will stuck sometimes. It is because NICMIX is powered
down, which HSIOMIX(always on) is not powered down. When NICMIX
powering down, HSIOMIX will get a hardware handshake, without HSIO ROOT
clk, the handshake will lose. Then after NICMIX power on when system
resume, the access to HSIOMIX through NICMIX would be broken. So keep HSIO
ROOT always on.
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
[Peng Fan] rewrite commit message
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 422ad3c89845..74e8d810db7f 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -109,7 +109,7 @@ static const struct imx93_clk_root {
{ IMX93_CLK_CCM_CKO2, "ccm_cko2_root", 0x1d00, CKO2_SEL, },
{ IMX93_CLK_CCM_CKO3, "ccm_cko3_root", 0x1d80, CKO1_SEL, },
{ IMX93_CLK_CCM_CKO4, "ccm_cko4_root", 0x1e00, CKO2_SEL, },
- { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, },
+ { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, CLK_IS_CRITICAL},
{ IMX93_CLK_HSIO_USB_TEST_60M, "hsio_usb_test_60m_root", 0x1f00, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_HSIO_ACSCAN_80M, "hsio_acscan_80m_root", 0x1f80, LOW_SPEED_IO_SEL, },
{ IMX93_CLK_HSIO_ACSCAN_480M, "hsio_acscan_480m_root", 0x2000, MISC_SEL, },
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 6/6] clk: imx93: keep sys ctr clock always on
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 10:11 ` Peng Fan (OSS)
-1 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
From: Jacky Bai <ping.bai@nxp.com>
Keep sys ctr clock always on to make sure its register
can be accessed for cpuidle.
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 74e8d810db7f..91db356564c1 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -238,7 +238,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
{ IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
- { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
+ { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, CLK_IS_CRITICAL},
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
{ IMX93_CLK_TSTMR2_GATE, "tstmr2", "bus_wakeup_root", 0x9f00, },
{ IMX93_CLK_TMC_GATE, "tmc", "osc_24m", 0x9f40, },
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 6/6] clk: imx93: keep sys ctr clock always on
@ 2022-10-27 10:11 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-27 10:11 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
From: Jacky Bai <ping.bai@nxp.com>
Keep sys ctr clock always on to make sure its register
can be accessed for cpuidle.
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Jacky Bai <ping.bai@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 74e8d810db7f..91db356564c1 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -238,7 +238,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
{ IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
- { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
+ { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, CLK_IS_CRITICAL},
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
{ IMX93_CLK_TSTMR2_GATE, "tstmr2", "bus_wakeup_root", 0x9f00, },
{ IMX93_CLK_TMC_GATE, "tmc", "osc_24m", 0x9f40, },
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH 3/6] dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 21:17 ` Krzysztof Kozlowski
-1 siblings, 0 replies; 24+ messages in thread
From: Krzysztof Kozlowski @ 2022-10-27 21:17 UTC (permalink / raw)
To: Peng Fan (OSS),
abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
On 27/10/2022 06:11, Peng Fan (OSS) wrote:
> From: Peng Fan <peng.fan@nxp.com>
>
> Per updated Reference Mannual, the TPM[1,3] LPIT[1,2] root clock entries
> are reserved. So drop them.
Reserved as firmware does not allow OS to use them? You are now
affecting the ABI, so "drop them" should be nicely explained.
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 3/6] dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry
@ 2022-10-27 21:17 ` Krzysztof Kozlowski
0 siblings, 0 replies; 24+ messages in thread
From: Krzysztof Kozlowski @ 2022-10-27 21:17 UTC (permalink / raw)
To: Peng Fan (OSS),
abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Jacky Bai
On 27/10/2022 06:11, Peng Fan (OSS) wrote:
> From: Peng Fan <peng.fan@nxp.com>
>
> Per updated Reference Mannual, the TPM[1,3] LPIT[1,2] root clock entries
> are reserved. So drop them.
Reserved as firmware does not allow OS to use them? You are now
affecting the ABI, so "drop them" should be nicely explained.
Best regards,
Krzysztof
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 6/6] clk: imx93: keep sys ctr clock always on
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 23:05 ` Stephen Boyd
-1 siblings, 0 replies; 24+ messages in thread
From: Stephen Boyd @ 2022-10-27 23:05 UTC (permalink / raw)
To: Peng Fan, abel.vesa, abelvesa, festevam, kernel,
krzysztof.kozlowski+dt, mturquette, robh+dt, s.hauer, shawnguo
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
Quoting Peng Fan (OSS) (2022-10-27 03:11:59)
> From: Jacky Bai <ping.bai@nxp.com>
>
> Keep sys ctr clock always on to make sure its register
> can be accessed for cpuidle.
>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Jacky Bai <ping.bai@nxp.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 74e8d810db7f..91db356564c1 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -238,7 +238,7 @@ static const struct imx93_clk_ccgr {
> { IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
> { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
> { IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
> - { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
> + { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, CLK_IS_CRITICAL},
Please add a comment like
/* Critical because clk accessed during CPU idle */
> { IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
> { IMX93_CLK_TSTMR2_GATE, "tstmr2", "bus_wakeup_root", 0x9f00, },
> { IMX93_CLK_TMC_GATE, "tmc", "osc_24m", 0x9f40, },
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 6/6] clk: imx93: keep sys ctr clock always on
@ 2022-10-27 23:05 ` Stephen Boyd
0 siblings, 0 replies; 24+ messages in thread
From: Stephen Boyd @ 2022-10-27 23:05 UTC (permalink / raw)
To: Peng Fan, abel.vesa, abelvesa, festevam, kernel,
krzysztof.kozlowski+dt, mturquette, robh+dt, s.hauer, shawnguo
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
Quoting Peng Fan (OSS) (2022-10-27 03:11:59)
> From: Jacky Bai <ping.bai@nxp.com>
>
> Keep sys ctr clock always on to make sure its register
> can be accessed for cpuidle.
>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Jacky Bai <ping.bai@nxp.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 74e8d810db7f..91db356564c1 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -238,7 +238,7 @@ static const struct imx93_clk_ccgr {
> { IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
> { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
> { IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
> - { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
> + { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, CLK_IS_CRITICAL},
Please add a comment like
/* Critical because clk accessed during CPU idle */
> { IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
> { IMX93_CLK_TSTMR2_GATE, "tstmr2", "bus_wakeup_root", 0x9f00, },
> { IMX93_CLK_TMC_GATE, "tmc", "osc_24m", 0x9f40, },
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 5/6] clk: imx: keep hsio bus clock always on
2022-10-27 10:11 ` Peng Fan (OSS)
@ 2022-10-27 23:09 ` Stephen Boyd
-1 siblings, 0 replies; 24+ messages in thread
From: Stephen Boyd @ 2022-10-27 23:09 UTC (permalink / raw)
To: Peng Fan, abel.vesa, abelvesa, festevam, kernel,
krzysztof.kozlowski+dt, mturquette, robh+dt, s.hauer, shawnguo
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
Quoting Peng Fan (OSS) (2022-10-27 03:11:58)
> From: Jacky Bai <ping.bai@nxp.com>
>
> During Linux System suspend/resume stress test after System Sleep
> enabled, system will stuck sometimes. It is because NICMIX is powered
> down, which HSIOMIX(always on) is not powered down. When NICMIX
> powering down, HSIOMIX will get a hardware handshake, without HSIO ROOT
> clk, the handshake will lose. Then after NICMIX power on when system
> resume, the access to HSIOMIX through NICMIX would be broken. So keep HSIO
> ROOT always on.
>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Jacky Bai <ping.bai@nxp.com>
> [Peng Fan] rewrite commit message
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 422ad3c89845..74e8d810db7f 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -109,7 +109,7 @@ static const struct imx93_clk_root {
> { IMX93_CLK_CCM_CKO2, "ccm_cko2_root", 0x1d00, CKO2_SEL, },
> { IMX93_CLK_CCM_CKO3, "ccm_cko3_root", 0x1d80, CKO1_SEL, },
> { IMX93_CLK_CCM_CKO4, "ccm_cko4_root", 0x1e00, CKO2_SEL, },
> - { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, },
> + { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, CLK_IS_CRITICAL},
Similarly add a comment for critical flag please.
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 5/6] clk: imx: keep hsio bus clock always on
@ 2022-10-27 23:09 ` Stephen Boyd
0 siblings, 0 replies; 24+ messages in thread
From: Stephen Boyd @ 2022-10-27 23:09 UTC (permalink / raw)
To: Peng Fan, abel.vesa, abelvesa, festevam, kernel,
krzysztof.kozlowski+dt, mturquette, robh+dt, s.hauer, shawnguo
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Jacky Bai, Peng Fan
Quoting Peng Fan (OSS) (2022-10-27 03:11:58)
> From: Jacky Bai <ping.bai@nxp.com>
>
> During Linux System suspend/resume stress test after System Sleep
> enabled, system will stuck sometimes. It is because NICMIX is powered
> down, which HSIOMIX(always on) is not powered down. When NICMIX
> powering down, HSIOMIX will get a hardware handshake, without HSIO ROOT
> clk, the handshake will lose. Then after NICMIX power on when system
> resume, the access to HSIOMIX through NICMIX would be broken. So keep HSIO
> ROOT always on.
>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Jacky Bai <ping.bai@nxp.com>
> [Peng Fan] rewrite commit message
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 422ad3c89845..74e8d810db7f 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -109,7 +109,7 @@ static const struct imx93_clk_root {
> { IMX93_CLK_CCM_CKO2, "ccm_cko2_root", 0x1d00, CKO2_SEL, },
> { IMX93_CLK_CCM_CKO3, "ccm_cko3_root", 0x1d80, CKO1_SEL, },
> { IMX93_CLK_CCM_CKO4, "ccm_cko4_root", 0x1e00, CKO2_SEL, },
> - { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, },
> + { IMX93_CLK_HSIO, "hsio_root", 0x1e80, LOW_SPEED_IO_SEL, CLK_IS_CRITICAL},
Similarly add a comment for critical flag please.
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 2/6] clk: imx93: correct enet clock
2022-10-28 9:52 ` Peng Fan (OSS)
@ 2022-11-04 20:52 ` Abel Vesa
-1 siblings, 0 replies; 24+ messages in thread
From: Abel Vesa @ 2022-11-04 20:52 UTC (permalink / raw)
To: Peng Fan (OSS)
Cc: abelvesa, mturquette, sboyd, shawnguo, s.hauer, kernel, festevam,
robh+dt, krzysztof.kozlowski+dt, linux-imx, linux-clk,
linux-arm-kernel, linux-kernel, devicetree, Peng Fan, Ye Li
On 22-10-28 17:52:07, Peng Fan (OSS) wrote:
> From: Peng Fan <peng.fan@nxp.com>
>
> Per update Reference Mannual, correct the enet clock parent to
> wakeup_axi_root.
>
> Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
> Reviewed-by: Ye Li <ye.li@nxp.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Abel Vesa <abel.vesa@linaro.org>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 9ef3fcbdd951..7fdc30062a46 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
> { IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
> { IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
> { IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
> - { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
> + { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
> { IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
> { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
> { IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
> --
> 2.37.1
>
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH 2/6] clk: imx93: correct enet clock
@ 2022-11-04 20:52 ` Abel Vesa
0 siblings, 0 replies; 24+ messages in thread
From: Abel Vesa @ 2022-11-04 20:52 UTC (permalink / raw)
To: Peng Fan (OSS)
Cc: abelvesa, mturquette, sboyd, shawnguo, s.hauer, kernel, festevam,
robh+dt, krzysztof.kozlowski+dt, linux-imx, linux-clk,
linux-arm-kernel, linux-kernel, devicetree, Peng Fan, Ye Li
On 22-10-28 17:52:07, Peng Fan (OSS) wrote:
> From: Peng Fan <peng.fan@nxp.com>
>
> Per update Reference Mannual, correct the enet clock parent to
> wakeup_axi_root.
>
> Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
> Reviewed-by: Ye Li <ye.li@nxp.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Abel Vesa <abel.vesa@linaro.org>
> ---
> drivers/clk/imx/clk-imx93.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index 9ef3fcbdd951..7fdc30062a46 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
> { IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
> { IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
> { IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
> - { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
> + { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
> { IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
> { IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
> { IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
> --
> 2.37.1
>
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH 2/6] clk: imx93: correct enet clock
2022-10-28 9:52 [PATCH 0/6] clk: imx93: fix and update Peng Fan (OSS)
@ 2022-10-28 9:52 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-28 9:52 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Ye Li
From: Peng Fan <peng.fan@nxp.com>
Per update Reference Mannual, correct the enet clock parent to
wakeup_axi_root.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 9ef3fcbdd951..7fdc30062a46 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
{ IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
- { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
+ { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
{ IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
--
2.37.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH 2/6] clk: imx93: correct enet clock
@ 2022-10-28 9:52 ` Peng Fan (OSS)
0 siblings, 0 replies; 24+ messages in thread
From: Peng Fan (OSS) @ 2022-10-28 9:52 UTC (permalink / raw)
To: abelvesa, abel.vesa, mturquette, sboyd, shawnguo, s.hauer,
kernel, festevam, robh+dt, krzysztof.kozlowski+dt
Cc: linux-imx, linux-clk, linux-arm-kernel, linux-kernel, devicetree,
Peng Fan, Ye Li
From: Peng Fan <peng.fan@nxp.com>
Per update Reference Mannual, correct the enet clock parent to
wakeup_axi_root.
Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
drivers/clk/imx/clk-imx93.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index 9ef3fcbdd951..7fdc30062a46 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -240,7 +240,7 @@ static const struct imx93_clk_ccgr {
{ IMX93_CLK_AUD_XCVR_GATE, "aud_xcvr", "audio_xcvr_root", 0x9b80, },
{ IMX93_CLK_SPDIF_GATE, "spdif", "spdif_root", 0x9c00, },
{ IMX93_CLK_HSIO_32K_GATE, "hsio_32k", "osc_32k", 0x9dc0, },
- { IMX93_CLK_ENET1_GATE, "enet1", "enet_root", 0x9e00, },
+ { IMX93_CLK_ENET1_GATE, "enet1", "wakeup_axi_root", 0x9e00, },
{ IMX93_CLK_ENET_QOS_GATE, "enet_qos", "wakeup_axi_root", 0x9e40, },
{ IMX93_CLK_SYS_CNT_GATE, "sys_cnt", "osc_24m", 0x9e80, },
{ IMX93_CLK_TSTMR1_GATE, "tstmr1", "bus_aon_root", 0x9ec0, },
--
2.37.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
end of thread, other threads:[~2022-11-04 20:53 UTC | newest]
Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-27 10:11 [PATCH 0/6] clk: imx93: fix and update Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 10:11 ` [PATCH 1/6] clk: imx93: unmap anatop base in error handling path Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 10:11 ` [PATCH 2/6] clk: imx93: correct enet clock Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 10:11 ` [PATCH 3/6] dt-bindings: clock: imx93: drop TPM1/3 LPIT1/2 entry Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 21:17 ` Krzysztof Kozlowski
2022-10-27 21:17 ` Krzysztof Kozlowski
2022-10-27 10:11 ` [PATCH 4/6] clk: imx93: drop tpm1/3, lpit1/2 clk Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 10:11 ` [PATCH 5/6] clk: imx: keep hsio bus clock always on Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 23:09 ` Stephen Boyd
2022-10-27 23:09 ` Stephen Boyd
2022-10-27 10:11 ` [PATCH 6/6] clk: imx93: keep sys ctr " Peng Fan (OSS)
2022-10-27 10:11 ` Peng Fan (OSS)
2022-10-27 23:05 ` Stephen Boyd
2022-10-27 23:05 ` Stephen Boyd
2022-10-28 9:52 [PATCH 0/6] clk: imx93: fix and update Peng Fan (OSS)
2022-10-28 9:52 ` [PATCH 2/6] clk: imx93: correct enet clock Peng Fan (OSS)
2022-10-28 9:52 ` Peng Fan (OSS)
2022-11-04 20:52 ` Abel Vesa
2022-11-04 20:52 ` Abel Vesa
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.