[PATCH 3/3] clk: stm32mp1: don't disable the ck_trace clock when unused
From: Gabriel Fernandez
Date: Tue Oct 20 2026 - 05:55:05 EST
From: Antonio Borneo <antonio.borneo@xxxxxxxxxxx>
The trace clock may have been enabled by the bootloader or by an
external debugger tool. Linux has no consumer for it, so the clock
framework would turn it off at the end of the boot as an unused clock
and break the trace session.
Add CLK_IGNORE_UNUSED to ck_trace, as already done for ck_sys_dbg.
Signed-off-by: Antonio Borneo <antonio.borneo@xxxxxxxxxxx>
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@xxxxxxxxxxx>
---
drivers/clk/stm32/clk-stm32mp1.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/stm32/clk-stm32mp1.c b/drivers/clk/stm32/clk-stm32mp1.c
index 077dd3342911..6fe0b901b063 100644
--- a/drivers/clk/stm32/clk-stm32mp1.c
+++ b/drivers/clk/stm32/clk-stm32mp1.c
@@ -2090,7 +2090,8 @@ static const struct clock_config stm32mp1_clock_cfg[] = {
GATE(CK_DBG, "ck_sys_dbg", "ck_axi", CLK_IGNORE_UNUSED,
RCC_DBGCFGR, 8, 0),
- COMPOSITE(CK_TRACE, "ck_trace", ck_trace_src, CLK_OPS_PARENT_ENABLE,
+ COMPOSITE(CK_TRACE, "ck_trace", ck_trace_src,
+ CLK_OPS_PARENT_ENABLE | CLK_IGNORE_UNUSED,
_GATE(RCC_DBGCFGR, 9, 0),
_NO_MUX,
_DIV(RCC_DBGCFGR, 0, 3, 0, ck_trace_div_table)),
--
2.43.0