1 #ifndef __ALPHA_IRQFLAGS_H
2 #define __ALPHA_IRQFLAGS_H
13 #define IPL_POWERFAIL 6
17 #ifdef CONFIG_ALPHA_BROKEN_IRQ_MASK
19 #define IPL_MIN __min_ipl
23 #define getipl() (rdps() & 7)
24 #define setipl(ipl) ((void) swpipl(ipl))
26 static inline unsigned long arch_local_save_flags(void)
31 static inline void arch_local_irq_disable(void)
37 static inline unsigned long arch_local_irq_save(void)
39 unsigned long flags
= swpipl(IPL_MAX
);
44 static inline void arch_local_irq_enable(void)
50 static inline void arch_local_irq_restore(unsigned long flags
)
57 static inline bool arch_irqs_disabled_flags(unsigned long flags
)
59 return flags
== IPL_MAX
;
62 static inline bool arch_irqs_disabled(void)
64 return arch_irqs_disabled_flags(getipl());
67 #endif /* __ALPHA_IRQFLAGS_H */