irq.h 1.1 KB

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