ARC: [SMP] ISS SMP extension bitrot
authorVineet Gupta <vgupta@synopsys.com>
Fri, 28 Feb 2014 08:13:44 +0000 (16:13 +0800)
committerVineet Gupta <vgupta@synopsys.com>
Mon, 5 May 2014 08:52:12 +0000 (14:22 +0530)
* Move extension specific code out of common SMP code
* Don't enable it by default for SMP

Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
arch/arc/include/asm/irq.h
arch/arc/kernel/irq.c
arch/arc/plat-arcfpga/Makefile
arch/arc/plat-arcfpga/platform.c
arch/arc/plat-arcfpga/smp.c

index 291a70db68b8b0fa0d262a79d80d7e9be9681c0e..781f57f25bd8d10ff0d85dfb6a18ca5d396117f9 100644 (file)
@@ -19,8 +19,6 @@
 #include <asm-generic/irq.h>
 
 extern void arc_init_IRQ(void);
-extern int get_hw_config_num_irq(void);
-
 void arc_local_timer_setup(unsigned int cpu);
 
 #endif
index a4b141ee9a6a19c9e6e4001583fc7b6637b3f1f4..7d653c0d077390fa31bc70a6e6e67cbf78ad33a8 100644 (file)
@@ -150,24 +150,6 @@ void arch_do_IRQ(unsigned int irq, struct pt_regs *regs)
        set_irq_regs(old_regs);
 }
 
-int get_hw_config_num_irq(void)
-{
-       uint32_t val = read_aux_reg(ARC_REG_VECBASE_BCR);
-
-       switch (val & 0x03) {
-       case 0:
-               return 16;
-       case 1:
-               return 32;
-       case 2:
-               return 8;
-       default:
-               return 0;
-       }
-
-       return 0;
-}
-
 /*
  * arch_local_irq_enable - Enable interrupts.
  *
index a44e22ebc1b77786ae14a39d1f5794c110df0b6b..4d1bddc34b5b531076ef05ea89206a6b75c4ef86 100644 (file)
@@ -9,4 +9,4 @@
 KBUILD_CFLAGS  += -Iarch/arc/plat-arcfpga/include
 
 obj-y := platform.o irq.o
-obj-$(CONFIG_SMP)              += smp.o
+obj-$(CONFIG_ISS_SMP_EXTN)             += smp.o
index 19b76b61f44bfc2b1b560a240347aa435fcb87ff..213394a15cd234144f367e357e1a4d2e88080be3 100644 (file)
@@ -169,7 +169,7 @@ static void __init plat_fpga_early_init(void)
 
        arc_fpga_serial_init();
 
-#ifdef CONFIG_SMP
+#ifdef CONFIG_ISS_SMP_EXTN
        iss_model_init_early_smp();
 #endif
 }
@@ -211,7 +211,7 @@ MACHINE_START(ANGEL4, "angel4")
        .init_early     = plat_fpga_early_init,
        .init_machine   = plat_fpga_populate_dev,
        .init_irq       = plat_fpga_init_IRQ,
-#ifdef CONFIG_SMP
+#ifdef CONFIG_ISS_SMP_EXTN
        .init_smp       = iss_model_init_smp,
 #endif
 MACHINE_END
index 8a12741f5f7ab79668212259036fe0c2872bb037..92bad9122077dc00b22fc82c6e22be8f5219787b 100644 (file)
@@ -42,6 +42,24 @@ static void iss_model_smp_wakeup_cpu(int cpu, unsigned long pc)
 
 }
 
+static inline int get_hw_config_num_irq(void)
+{
+       uint32_t val = read_aux_reg(ARC_REG_VECBASE_BCR);
+
+       switch (val & 0x03) {
+       case 0:
+               return 16;
+       case 1:
+               return 32;
+       case 2:
+               return 8;
+       default:
+               return 0;
+       }
+
+       return 0;
+}
+
 /*
  * Any SMP specific init any CPU does when it comes up.
  * Here we setup the CPU to enable Inter-Processor-Interrupts