home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2006 November (DVD) / PCWELT_11_2006.ISO / casper / filesystem.squashfs / usr / src / linux-headers-2.6.17-6 / include / asm-alpha / irq.h < prev    next >
Encoding:
C/C++ Source or Header  |  2006-08-11  |  2.5 KB  |  100 lines

  1. #ifndef _ALPHA_IRQ_H
  2. #define _ALPHA_IRQ_H
  3.  
  4. /*
  5.  *    linux/include/alpha/irq.h
  6.  *
  7.  *    (C) 1994 Linus Torvalds
  8.  */
  9.  
  10. #include <linux/linkage.h>
  11.  
  12. #if   defined(CONFIG_ALPHA_GENERIC)
  13.  
  14. /* Here NR_IRQS is not exact, but rather an upper bound.  This is used
  15.    many places throughout the kernel to size static arrays.  That's ok,
  16.    we'll use alpha_mv.nr_irqs when we want the real thing.  */
  17.  
  18. /* When LEGACY_START_ADDRESS is selected, we leave out:
  19.      TITAN
  20.      WILDFIRE
  21.      MARVEL
  22.  
  23.    This helps keep the kernel object size reasonable for the majority
  24.    of machines.
  25. */
  26.  
  27. # if defined(CONFIG_ALPHA_LEGACY_START_ADDRESS)
  28. #  define NR_IRQS      (128)           /* max is RAWHIDE/TAKARA */
  29. # else
  30. #  define NR_IRQS      (32768 + 16)    /* marvel - 32 pids */
  31. # endif
  32.  
  33. #elif defined(CONFIG_ALPHA_CABRIOLET) || \
  34.       defined(CONFIG_ALPHA_EB66P)     || \
  35.       defined(CONFIG_ALPHA_EB164)     || \
  36.       defined(CONFIG_ALPHA_PC164)     || \
  37.       defined(CONFIG_ALPHA_LX164)
  38. # define NR_IRQS    35
  39.  
  40. #elif defined(CONFIG_ALPHA_EB66)      || \
  41.       defined(CONFIG_ALPHA_EB64P)     || \
  42.       defined(CONFIG_ALPHA_MIKASA)
  43. # define NR_IRQS    32
  44.  
  45. #elif defined(CONFIG_ALPHA_ALCOR)     || \
  46.       defined(CONFIG_ALPHA_MIATA)     || \
  47.       defined(CONFIG_ALPHA_RUFFIAN)   || \
  48.       defined(CONFIG_ALPHA_RX164)     || \
  49.       defined(CONFIG_ALPHA_NORITAKE)
  50. # define NR_IRQS    48
  51.  
  52. #elif defined(CONFIG_ALPHA_SABLE)     || \
  53.       defined(CONFIG_ALPHA_SX164)
  54. # define NR_IRQS    40
  55.  
  56. #elif defined(CONFIG_ALPHA_DP264) || \
  57.       defined(CONFIG_ALPHA_LYNX)  || \
  58.       defined(CONFIG_ALPHA_SHARK) || \
  59.       defined(CONFIG_ALPHA_EIGER)
  60. # define NR_IRQS    64
  61.  
  62. #elif defined(CONFIG_ALPHA_TITAN)
  63. #define NR_IRQS        80
  64.  
  65. #elif defined(CONFIG_ALPHA_RAWHIDE) || \
  66.     defined(CONFIG_ALPHA_TAKARA)
  67. # define NR_IRQS    128
  68.  
  69. #elif defined(CONFIG_ALPHA_WILDFIRE)
  70. # define NR_IRQS    2048 /* enuff for 8 QBBs */
  71.  
  72. #elif defined(CONFIG_ALPHA_MARVEL)
  73. # define NR_IRQS    (32768 + 16)     /* marvel - 32 pids*/
  74.  
  75. #else /* everyone else */
  76. # define NR_IRQS    16
  77. #endif
  78.  
  79. static __inline__ int irq_canonicalize(int irq)
  80. {
  81.     /*
  82.      * XXX is this true for all Alpha's?  The old serial driver
  83.      * did it this way for years without any complaints, so....
  84.      */
  85.     return ((irq == 2) ? 9 : irq);
  86. }
  87.  
  88. extern void disable_irq(unsigned int);
  89. extern void disable_irq_nosync(unsigned int);
  90. extern void enable_irq(unsigned int);
  91.  
  92. struct pt_regs;
  93. extern void (*perf_irq)(unsigned long, struct pt_regs *);
  94.  
  95. struct irqaction;
  96. int handle_IRQ_event(unsigned int, struct pt_regs *, struct irqaction *);
  97.  
  98.  
  99. #endif /* _ALPHA_IRQ_H */
  100.