]> git.sur5r.net Git - u-boot/blobdiff - cpu/mpc8260/interrupts.c
Phytec Phycore-i.MX31 support
[u-boot] / cpu / mpc8260 / interrupts.c
index b2e4d839245813d9b8a4759ff70578ed724eb10e..bf0d4d0d59f06a471f15c9ef347a0e044b411b23 100644 (file)
@@ -29,6 +29,8 @@
 #include <mpc8260_irq.h>
 #include <asm/processor.h>
 
+DECLARE_GLOBAL_DATA_PTR;
+
 /****************************************************************************/
 
 struct irq_action {
@@ -140,8 +142,6 @@ static int m8260_get_irq (struct pt_regs *regs)
 
 int interrupt_init_cpu (unsigned *decrementer_count)
 {
-       DECLARE_GLOBAL_DATA_PTR;
-
        volatile immap_t *immr = (immap_t *) CFG_IMMR;
 
        *decrementer_count = (gd->bus_clk / 4) / CFG_HZ;
@@ -246,7 +246,7 @@ void timer_interrupt_cpu (struct pt_regs *regs)
 
 /****************************************************************************/
 
-#if (CONFIG_COMMANDS & CFG_CMD_IRQ)
+#if defined(CONFIG_CMD_IRQ)
 
 /* ripped this out of ppc4xx/interrupts.c */
 
@@ -276,4 +276,4 @@ do_irqinfo (cmd_tbl_t * cmdtp, bd_t * bd, int flag, int argc, char *argv[])
                enable_interrupts ();
 }
 
-#endif                                                 /* CONFIG_COMMANDS & CFG_CMD_IRQ */
+#endif