Thread (150 messages) 150 messages, 3 authors, 1d ago

Re: [RFC PATCH 10/36] arm64: irqflags: save and use both DAIF and PMR

From: Vladimir Murzin <hidden>
Date: 2026-07-14 09:44:44

On 7/10/26 09:11, Jinjie Ruan wrote:
quoted
quoted
diff --git a/arch/arm64/include/asm/ptrace.h b/arch/arm64/include/asm/ptrace.h
index f7dc5fb9427d..192eb97cd50b 100644
--- a/arch/arm64/include/asm/ptrace.h
+++ b/arch/arm64/include/asm/ptrace.h
@@ -205,7 +205,7 @@ static inline void forget_syscall(struct pt_regs *regs)
 
 #define irqs_priority_unmasked(regs)					\
 	(system_uses_irq_prio_masking() ?				\
-		(regs)->pmr == GIC_PRIO_IRQON :				\
+		(regs)->pmr >= GIC_PRIO_IRQON :				\
 		true)
 
 static __always_inline bool regs_irqs_disabled(const struct pt_regs *regs)
Is there any reason to keep interrupt_enabled()? It appears to be rarely used
across interrupt and exception code. So far, i've only found a single use in
gic_handle_irq(), corret me if i'm wrong. So using regs_irqs_disable() directly
might reduce the number of small helper that people need to remember.
For arm32.
Indeed, gic_handle_irq() is shared between arm64 and arm32, and latter
doesn't provide regs_irqs_disabled(), thus we have to keep
interrupt_enabled() for now.

Thanks
Vladimir
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help