[PATCH] clk: spacemit: ccu_mix: fix inverted condition in ccu_mix_trigger_fc()

From: Shuwei Wu

Date: Thu Mar 05 2026 - 07:46:38 EST


Fix inverted condition that skips frequency change trigger,
causing kernel panics during cpufreq scaling.

Fixes: 1b72c59db0ad ("clk: spacemit: Add clock support for SpacemiT K1 SoC")
Signed-off-by: Shuwei Wu <shuwei.wu@xxxxxxxxxxx>
---
drivers/clk/spacemit/ccu_mix.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/spacemit/ccu_mix.c b/drivers/clk/spacemit/ccu_mix.c
index 9578366e9746..a8b407049bf4 100644
--- a/drivers/clk/spacemit/ccu_mix.c
+++ b/drivers/clk/spacemit/ccu_mix.c
@@ -73,7 +73,7 @@ static int ccu_mix_trigger_fc(struct clk_hw *hw)
struct ccu_common *common = hw_to_ccu_common(hw);
unsigned int val;

- if (common->reg_fc)
+ if (!common->reg_fc)
return 0;

ccu_update(common, fc, common->mask_fc, common->mask_fc);

---
base-commit: c107785c7e8dbabd1c18301a1c362544b5786282
change-id: 20260305-k1-clk-fix-25b101c88459

Best regards,
--
Shuwei Wu <shuwei.wu@xxxxxxxxxxx>