We could ignore IPL2 when running on Atari (untested whitespace-damaged
patch):
--- a/arch/m68k/include/asm/irqflags.h
+++ b/arch/m68k/include/asm/irqflags.h
@@ -67,7 +67,11 @@ static inline void arch_local_irq_restore(unsigned long flags
static inline bool arch_irqs_disabled_flags(unsigned long flags)
{
- return (flags & ~ALLOWINT) != 0;
+ if (MACH_IS_ATARI) {
+ /* Ignore HSYNC = ipl 2 on Atari */
+ return (flags & ~(ALLOWINT | 0x200)) != 0;
+ } else
+ return (flags & ~ALLOWINT) != 0;
}
static inline bool arch_irqs_disabled(void)
or just ignore all priorities on all platforms, and consider interrupts disabled
iff all priorities are disabled:
--- a/arch/m68k/include/asm/irqflags.h
+++ b/arch/m68k/include/asm/irqflags.h
@@ -67,7 +67,7 @@ static inline void arch_local_irq_restore(unsigned long flags
static inline bool arch_irqs_disabled_flags(unsigned long flags)
{
- return (flags & ~ALLOWINT) != 0;
+ return (flags & ~ALLOWINT) != ~ALLOWINT;
}
static inline bool arch_irqs_disabled(void)
The former is safer but slower, the second is faster but will miss cases
where some interrupt priorities are disabled.