From 5c679e90581e278da2c3ca9977bd754436b3429f Mon Sep 17 00:00:00 2001 From: Huibin Hong Date: Mon, 7 Jul 2025 09:53:37 +0800 Subject: [PATCH] soc: rockchip: fiq_debugger: fix dts property 'rockchip,irq-mode-enable' When cpu is ARM-V7 without ATF, the uart interrupt mode is fiq mode when 'rockchip,irq-mode-enable' is 1, and it is irq mode when 'rockchip,irq-mode-enable' is 0. Signed-off-by: Huibin Hong Change-Id: Ia648639a52fe8c08893b7be0d4913233fb6d9607 --- drivers/soc/rockchip/fiq_debugger/rk_fiq_debugger.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/soc/rockchip/fiq_debugger/rk_fiq_debugger.c b/drivers/soc/rockchip/fiq_debugger/rk_fiq_debugger.c index fd71ed617d04..b91d337a7bd0 100644 --- a/drivers/soc/rockchip/fiq_debugger/rk_fiq_debugger.c +++ b/drivers/soc/rockchip/fiq_debugger/rk_fiq_debugger.c @@ -67,6 +67,7 @@ struct rk_fiq_debugger { static int rk_fiq_debugger_id; static int serial_hwirq; +static int irq_mode; #ifdef CONFIG_FIQ_DEBUGGER_TRUST_ZONE static bool tf_fiq_sup; @@ -933,7 +934,7 @@ static void rk_serial_debug_init(void __iomem *base, phys_addr_t phy_base, res[0].start = irq; res[0].end = irq; #if defined(CONFIG_FIQ_GLUE) - if (signal_irq > 0) + if (irq_mode != 1 && signal_irq > 0) res[0].name = "fiq"; else res[0].name = "uart_irq"; @@ -1041,7 +1042,7 @@ static int __init rk_fiqdbg_probe(struct platform_device *pdev) struct device_node *np = pdev->dev.of_node; unsigned int id, ok = 0; int irq, signal_irq = -1, wake_irq = -1; - unsigned int baudrate = 0, irq_mode = 0; + unsigned int baudrate = 0; phys_addr_t phy_base = 0; int serial_id; struct clk *clk;