irq.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /*
  2. * include/asm-parisc/irq.h
  3. *
  4. * Copyright 2005 Matthew Wilcox <matthew@wil.cx>
  5. */
  6. #ifndef _ASM_PARISC_IRQ_H
  7. #define _ASM_PARISC_IRQ_H
  8. #include <linux/cpumask.h>
  9. #include <asm/types.h>
  10. #define NO_IRQ (-1)
  11. #ifdef CONFIG_GSC
  12. #define GSC_IRQ_BASE 16
  13. #define GSC_IRQ_MAX 63
  14. #define CPU_IRQ_BASE 64
  15. #else
  16. #define CPU_IRQ_BASE 16
  17. #endif
  18. #define TIMER_IRQ (CPU_IRQ_BASE + 0)
  19. #define IPI_IRQ (CPU_IRQ_BASE + 1)
  20. #define CPU_IRQ_MAX (CPU_IRQ_BASE + (BITS_PER_LONG - 1))
  21. #define NR_IRQS (CPU_IRQ_MAX + 1)
  22. static __inline__ int irq_canonicalize(int irq)
  23. {
  24. return (irq == 2) ? 9 : irq;
  25. }
  26. struct irq_chip;
  27. struct irq_data;
  28. void cpu_ack_irq(struct irq_data *d);
  29. void cpu_eoi_irq(struct irq_data *d);
  30. extern int txn_alloc_irq(unsigned int nbits);
  31. extern int txn_claim_irq(int);
  32. extern unsigned int txn_alloc_data(unsigned int);
  33. extern unsigned long txn_alloc_addr(unsigned int);
  34. extern unsigned long txn_affinity_addr(unsigned int irq, int cpu);
  35. extern int cpu_claim_irq(unsigned int irq, struct irq_chip *, void *);
  36. extern int cpu_check_affinity(struct irq_data *d, const struct cpumask *dest);
  37. /* soft power switch support (power.c) */
  38. extern struct tasklet_struct power_tasklet;
  39. #endif /* _ASM_PARISC_IRQ_H */