1 #ifndef _ALPHA_HARDIRQ_H
2 #define _ALPHA_HARDIRQ_H
4 #include <linux/config.h>
5 #include <linux/threads.h>
6 #include <linux/cache.h>
9 /* entry.S is sensitive to the offsets of these fields */
11 unsigned long __softirq_pending;
12 unsigned int __syscall_count;
13 unsigned long idle_timestamp;
14 struct task_struct * __ksoftirqd_task;
15 } ____cacheline_aligned irq_cpustat_t;
17 #include <linux/irq_cpustat.h> /* Standard mappings for irq_cpustat_t above */
19 #define HARDIRQ_BITS 12
22 * The hardirq mask has to be large enough to have
23 * space for potentially nestable IRQ sources in the system
24 * to nest on a single CPU. On Alpha, interrupts are masked at the CPU
25 * by IPL as well as at the system level. We only have 8 IPLs (UNIX PALcode)
26 * so we really only have 8 nestable IRQs, but allow some overhead
28 #if (1 << HARDIRQ_BITS) < 16
29 #error HARDIRQ_BITS is too low!
32 #define irq_enter() (preempt_count() += HARDIRQ_OFFSET)
35 preempt_count() -= IRQ_EXIT_OFFSET; \
36 if (!in_interrupt() && \
37 softirq_pending(smp_processor_id())) \
39 preempt_enable_no_resched(); \
42 #endif /* _ALPHA_HARDIRQ_H */