blob: 23dcb20ce50d8efb89c54204c32727ab815c5678 [file] [log] [blame]
Nicholas Flintham9fafe902014-03-31 13:51:31 +01001#ifndef _ALPHA_IRQ_H
2#define _ALPHA_IRQ_H
3
4
5#include <linux/linkage.h>
6
7#if defined(CONFIG_ALPHA_GENERIC)
8
9
10
11# if defined(CONFIG_ALPHA_LEGACY_START_ADDRESS)
12# define NR_IRQS (128)
13# else
14# define NR_IRQS (32768 + 16)
15# endif
16
17#elif defined(CONFIG_ALPHA_CABRIOLET) || \
18 defined(CONFIG_ALPHA_EB66P) || \
19 defined(CONFIG_ALPHA_EB164) || \
20 defined(CONFIG_ALPHA_PC164) || \
21 defined(CONFIG_ALPHA_LX164)
22# define NR_IRQS 35
23
24#elif defined(CONFIG_ALPHA_EB66) || \
25 defined(CONFIG_ALPHA_EB64P) || \
26 defined(CONFIG_ALPHA_MIKASA)
27# define NR_IRQS 32
28
29#elif defined(CONFIG_ALPHA_ALCOR) || \
30 defined(CONFIG_ALPHA_MIATA) || \
31 defined(CONFIG_ALPHA_RUFFIAN) || \
32 defined(CONFIG_ALPHA_RX164) || \
33 defined(CONFIG_ALPHA_NORITAKE)
34# define NR_IRQS 48
35
36#elif defined(CONFIG_ALPHA_SABLE) || \
37 defined(CONFIG_ALPHA_SX164)
38# define NR_IRQS 40
39
40#elif defined(CONFIG_ALPHA_DP264) || \
41 defined(CONFIG_ALPHA_LYNX) || \
42 defined(CONFIG_ALPHA_SHARK) || \
43 defined(CONFIG_ALPHA_EIGER)
44# define NR_IRQS 64
45
46#elif defined(CONFIG_ALPHA_TITAN)
47#define NR_IRQS 80
48
49#elif defined(CONFIG_ALPHA_RAWHIDE) || \
50 defined(CONFIG_ALPHA_TAKARA)
51# define NR_IRQS 128
52
53#elif defined(CONFIG_ALPHA_WILDFIRE)
54# define NR_IRQS 2048
55
56#elif defined(CONFIG_ALPHA_MARVEL)
57# define NR_IRQS (32768 + 16)
58
59#else
60# define NR_IRQS 16
61#endif
62
63static __inline__ int irq_canonicalize(int irq)
64{
65 return ((irq == 2) ? 9 : irq);
66}
67
68struct pt_regs;
69extern void (*perf_irq)(unsigned long, struct pt_regs *);
70
71#endif