sh: r7780rp: Kill off unneded ifdefs for irq setup.
authorPaul Mundt <lethal@linux-sh.org>
Fri, 25 Apr 2008 08:58:21 +0000 (17:58 +0900)
committerPaul Mundt <lethal@linux-sh.org>
Thu, 8 May 2008 10:51:44 +0000 (19:51 +0900)
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
arch/sh/boards/renesas/r7780rp/irq-r7780mp.c
arch/sh/boards/renesas/r7780rp/irq-r7780rp.c
arch/sh/boards/renesas/r7780rp/irq-r7785rp.c
arch/sh/boards/renesas/r7780rp/setup.c
include/asm-sh/r7780rp.h

index 68f0ad1b637dd3335243e7e101761fe34cd08688..ae1cfcb297008f76f8cb003872cf2ba87c6a8aa0 100644 (file)
@@ -62,7 +62,7 @@ static unsigned char irl2irq[HL_NR_IRL] __initdata = {
 static DECLARE_INTC_DESC(intc_desc, "r7780mp", vectors,
                         NULL, mask_registers, NULL, NULL);
 
-unsigned char * __init highlander_init_irq_r7780mp(void)
+unsigned char * __init highlander_plat_irq_setup(void)
 {
        if ((ctrl_inw(0xa4000700) & 0xf000) == 0x2000) {
                printk(KERN_INFO "Using r7780mp interrupt controller.\n");
index bd34048ed0e1f95c6b042a77d7a17486d13663e0..9d3921fe27c0b4506322ad5a3a0837c652a63c02 100644 (file)
@@ -55,7 +55,7 @@ static unsigned char irl2irq[HL_NR_IRL] __initdata = {
 static DECLARE_INTC_DESC(intc_desc, "r7780rp", vectors,
                         NULL, mask_registers, NULL, NULL);
 
-unsigned char * __init highlander_init_irq_r7780rp(void)
+unsigned char * __init highlander_plat_irq_setup(void)
 {
        if (ctrl_inw(0xa5000600)) {
                printk(KERN_INFO "Using r7780rp interrupt controller.\n");
index bf7ec107fbc63b4515e871a7858e6dfb7086e176..896c045aa39d63ab66ebc4eceed0b38f00911b59 100644 (file)
@@ -64,7 +64,7 @@ static unsigned char irl2irq[HL_NR_IRL] __initdata = {
 static DECLARE_INTC_DESC(intc_desc, "r7785rp", vectors,
                         NULL, mask_registers, NULL, NULL);
 
-unsigned char * __init highlander_init_irq_r7785rp(void)
+unsigned char * __init highlander_plat_irq_setup(void)
 {
        if ((ctrl_inw(0xa4000158) & 0xf000) != 0x1000)
                return NULL;
index ac0a96522e45e3f9387ae578149fe9ec05e34578..bc79afb6fc4c04c7c13335b9ae03e4938ec51939 100644 (file)
@@ -316,7 +316,7 @@ static void __init highlander_setup(char **cmdline_p)
 
 static unsigned char irl2irq[HL_NR_IRL];
 
-int highlander_irq_demux(int irq)
+static int highlander_irq_demux(int irq)
 {
        if (irq >= HL_NR_IRL || !irl2irq[irq])
                return irq;
@@ -324,27 +324,9 @@ int highlander_irq_demux(int irq)
        return irl2irq[irq];
 }
 
-void __init highlander_init_irq(void)
+static void __init highlander_init_irq(void)
 {
-       unsigned char *ucp = NULL;
-
-       do {
-#ifdef CONFIG_SH_R7780MP
-               ucp = highlander_init_irq_r7780mp();
-               if (ucp)
-                       break;
-#endif
-#ifdef CONFIG_SH_R7785RP
-               ucp = highlander_init_irq_r7785rp();
-               if (ucp)
-                       break;
-#endif
-#ifdef CONFIG_SH_R7780RP
-               ucp = highlander_init_irq_r7780rp();
-               if (ucp)
-                       break;
-#endif
-       } while (0);
+       unsigned char *ucp = highlander_plat_irq_setup();
 
        if (ucp) {
                plat_irq_setup_pins(IRQ_MODE_IRL3210);
index a33838f23a6d879b1b443554f66c36b1d6e685a8..306f7359f7d4c345a9cb8b19b7556d79720a3969 100644 (file)
 #define IRQ_SCIF0              (HL_FPGA_IRQ_BASE + 15)
 #define IRQ_SCIF1              (HL_FPGA_IRQ_BASE + 16)
 
-unsigned char *highlander_init_irq_r7780mp(void);
-unsigned char *highlander_init_irq_r7780rp(void);
-unsigned char *highlander_init_irq_r7785rp(void);
+unsigned char *highlander_plat_irq_setup(void);
 
 #endif  /* __ASM_SH_RENESAS_R7780RP */