[SPARC32]: clean include/asm-sparc/irq.h
[linux-2.6] / include / asm-sparc / irq.h
1 /* $Id: irq.h,v 1.32 2000/08/26 02:42:28 anton Exp $
2  * irq.h: IRQ registers on the Sparc.
3  *
4  * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu)
5  */
6
7 #ifndef _SPARC_IRQ_H
8 #define _SPARC_IRQ_H
9
10 #include <linux/linkage.h>
11 #include <linux/threads.h>     /* For NR_CPUS */
12 #include <linux/interrupt.h>
13
14 #include <asm/system.h>     /* For SUN4M_NCPUS */
15 #include <asm/btfixup.h>
16
17 #define NR_IRQS    16
18
19 #define irq_canonicalize(irq)   (irq)
20
21 /* Dave Redman (djhr@tadpole.co.uk)
22  * changed these to function pointers.. it saves cycles and will allow
23  * the irq dependencies to be split into different files at a later date
24  * sun4c_irq.c, sun4m_irq.c etc so we could reduce the kernel size.
25  * Jakub Jelinek (jj@sunsite.mff.cuni.cz)
26  * Changed these to btfixup entities... It saves cycles :)
27  */
28 BTFIXUPDEF_CALL(void, disable_irq, unsigned int)
29 BTFIXUPDEF_CALL(void, enable_irq, unsigned int)
30
31 static inline void disable_irq_nosync(unsigned int irq)
32 {
33         BTFIXUP_CALL(disable_irq)(irq);
34 }
35
36 static inline void disable_irq(unsigned int irq)
37 {
38         BTFIXUP_CALL(disable_irq)(irq);
39 }
40
41 static inline void enable_irq(unsigned int irq)
42 {
43         BTFIXUP_CALL(enable_irq)(irq);
44 }
45
46 extern int request_fast_irq(unsigned int irq, irq_handler_t handler, unsigned long flags, __const__ char *devname);
47
48 #endif