]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/ppc/platforms/sandpoint.c
Merge git://git.infradead.org/battery-2.6
[linux-2.6-omap-h63xx.git] / arch / ppc / platforms / sandpoint.c
index 5232283c1974a554658998de11cbf02d3a309b3a..3352fae1c7225fad4efb7f56a8e6fbb4e951e3ae 100644 (file)
@@ -1,6 +1,4 @@
 /*
- * arch/ppc/platforms/sandpoint_setup.c
- *
  * Board setup routines for the Motorola SPS Sandpoint Test Platform.
  *
  * Author: Mark A. Greer
  *
  *
  * Motorola has finally released a version of DINK32 that correctly
- * (seemingly) initalizes the memory controller correctly, regardless
+ * (seemingly) initializes the memory controller correctly, regardless
  * of the amount of memory in the system.  Once a method of determining
  * what version of DINK initializes the system for us, if applicable, is
  * found, we can hopefully stop hardcoding 32MB of RAM.
  */
 
-#include <linux/config.h>
 #include <linux/stddef.h>
 #include <linux/kernel.h>
 #include <linux/init.h>
@@ -476,7 +473,7 @@ sandpoint_request_io(void)
 arch_initcall(sandpoint_request_io);
 
 /*
- * Interrupt setup and service.  Interrrupts on the Sandpoint come
+ * Interrupt setup and service.  Interrupts on the Sandpoint come
  * from the four PCI slots plus the 8259 in the Winbond Super I/O (SIO).
  * The 8259 is cascaded from EPIC IRQ0, IRQ1-4 map to PCI slots 1-4,
  * IDE is on EPIC 7 and 8.
@@ -493,28 +490,11 @@ sandpoint_init_IRQ(void)
        openpic_hookup_cascade(sandpoint_is_x2 ? 17 : NUM_8259_INTERRUPTS, "82c59 cascade",
                        i8259_irq);
 
-       /*
-        * openpic_init() has set up irq_desc[16-31] to be openpic
-        * interrupts.  We need to set irq_desc[0-15] to be i8259
-        * interrupts.
-        */
-       for(i=0; i < NUM_8259_INTERRUPTS; i++)
-               irq_desc[i].handler = &i8259_pic;
-
        /*
         * The EPIC allows for a read in the range of 0xFEF00000 ->
         * 0xFEFFFFFF to generate a PCI interrupt-acknowledge transaction.
         */
-       i8259_init(0xfef00000);
-}
-
-static u32
-sandpoint_irq_canonicalize(u32 irq)
-{
-       if (irq == 2)
-               return 9;
-       else
-               return irq;
+       i8259_init(0xfef00000, 0);
 }
 
 static unsigned long __init
@@ -525,7 +505,7 @@ sandpoint_find_end_of_memory(void)
        if (bp->bi_memsize)
                return bp->bi_memsize;
 
-       /* DINK32 13.0 correctly initalizes things, so iff you use
+       /* DINK32 13.0 correctly initializes things, so iff you use
         * this you _should_ be able to change this instead of a
         * hardcoded value. */
 #if 0
@@ -697,7 +677,7 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
         * are non-zero, then we should use the board info from the bd_t
         * structure and the cmdline pointed to by r6 instead of the
         * information from birecs, if any.  Otherwise, use the information
-        * from birecs as discovered by the preceeding call to
+        * from birecs as discovered by the preceding call to
         * parse_bootinfo().  This rule should work with both PPCBoot, which
         * uses a bd_t board info structure, and the kernel boot wrapper,
         * which uses birecs.
@@ -727,10 +707,10 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
        ISA_DMA_THRESHOLD = 0x00ffffff;
        DMA_MODE_READ = 0x44;
        DMA_MODE_WRITE = 0x48;
+       ppc_do_canonicalize_irqs = 1;
 
        ppc_md.setup_arch = sandpoint_setup_arch;
        ppc_md.show_cpuinfo = sandpoint_show_cpuinfo;
-       ppc_md.irq_canonicalize = sandpoint_irq_canonicalize;
        ppc_md.init_IRQ = sandpoint_init_IRQ;
        ppc_md.get_irq = openpic_get_irq;