This commit was manufactured by cvs2svn to create branch 'vserver'.
[linux-2.6.git] / arch / i386 / mach-es7000 / setup.c
1 /*
2  *      Machine specific setup for es7000
3  */
4
5 #include <linux/config.h>
6 #include <linux/smp.h>
7 #include <linux/init.h>
8 #include <linux/irq.h>
9 #include <linux/interrupt.h>
10 #include <asm/acpi.h>
11 #include <asm/arch_hooks.h>
12
13 /**
14  * pre_intr_init_hook - initialisation prior to setting up interrupt vectors
15  *
16  * Description:
17  *      Perform any necessary interrupt initialisation prior to setting up
18  *      the "ordinary" interrupt call gates.  For legacy reasons, the ISA
19  *      interrupts should be initialised here if the machine emulates a PC
20  *      in any way.
21  **/void __init pre_intr_init_hook(void)
22 {
23         init_ISA_irqs();
24 }
25
26 /*
27  * IRQ2 is cascade interrupt to second interrupt controller
28  */
29 static struct irqaction irq2 = { no_action, 0, 0, "cascade", NULL, NULL};
30
31 /**
32  * intr_init_hook - post gate setup interrupt initialisation
33  *
34  * Description:
35  *      Fill in any interrupts that may have been left out by the general
36  *      init_IRQ() routine.  interrupts having to do with the machine rather
37  *      than the devices on the I/O bus (like APIC interrupts in intel MP
38  *      systems) are started here.
39  **/
40 void __init intr_init_hook(void)
41 {
42 #ifdef CONFIG_X86_LOCAL_APIC
43         apic_intr_init();
44 #endif
45
46         if (!acpi_ioapic)
47                 setup_irq(2, &irq2);
48 }
49
50 /**
51  * pre_setup_arch_hook - hook called prior to any setup_arch() execution
52  *
53  * Description:
54  *      generally used to activate any machine specific identification
55  *      routines that may be needed before setup_arch() runs.  On VISWS
56  *      this is used to get the board revision and type.
57  **/
58 void __init pre_setup_arch_hook(void)
59 {
60 }
61
62 /**
63  * trap_init_hook - initialise system specific traps
64  *
65  * Description:
66  *      Called as the final act of trap_init().  Used in VISWS to initialise
67  *      the various board specific APIC traps.
68  **/
69 void __init trap_init_hook(void)
70 {
71 }
72
73 static struct irqaction irq0  = { timer_interrupt, SA_INTERRUPT, 0, "timer", NULL, NULL};
74
75 /**
76  * time_init_hook - do any specific initialisations for the system timer.
77  *
78  * Description:
79  *      Must plug the system timer interrupt source at HZ into the IRQ listed
80  *      in irq_vectors.h:TIMER_IRQ
81  **/
82 void __init time_init_hook(void)
83 {
84         setup_irq(0, &irq0);
85 }
86
87 #ifdef CONFIG_MCA
88 /**
89  * mca_nmi_hook - hook into MCA specific NMI chain
90  *
91  * Description:
92  *      The MCA (Microchannel Arcitecture) has an NMI chain for NMI sources
93  *      along the MCA bus.  Use this to hook into that chain if you will need
94  *      it.
95  **/
96 void __init mca_nmi_hook(void)
97 {
98         /* If I recall correctly, there's a whole bunch of other things that
99          * we can do to check for NMI problems, but that's all I know about
100          * at the moment.
101          */
102
103         printk("NMI generated from unknown source!\n");
104 }
105
106 #endif