Skip to content

Commit 7067855

Browse files
author
Russell King
committed
ARM: actions: remove boot_lock and pen_release
The actions SMP implementation has several issues: 1. pen_release is only ever read and compared to -1, and is defined in arch/arm/kernel/smp.c to be -1. This test will always succeed. 2. we are already guaranteed to be single threaded while bringing up a CPU, so the spinlock makes no sense, remove it. 3. owl_secondary_startup() is not referenced nor defined, the prototype is redundant, remove it. Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
1 parent 0eb0379 commit 7067855

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

arch/arm/mach-actions/platsmp.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,6 @@ static void __iomem *sps_base_addr;
3939
static void __iomem *timer_base_addr;
4040
static int ncores;
4141

42-
static DEFINE_SPINLOCK(boot_lock);
43-
44-
void owl_secondary_startup(void);
45-
4642
static int s500_wakeup_secondary(unsigned int cpu)
4743
{
4844
int ret;
@@ -84,7 +80,6 @@ static int s500_wakeup_secondary(unsigned int cpu)
8480

8581
static int s500_smp_boot_secondary(unsigned int cpu, struct task_struct *idle)
8682
{
87-
unsigned long timeout;
8883
int ret;
8984

9085
ret = s500_wakeup_secondary(cpu);
@@ -93,21 +88,11 @@ static int s500_smp_boot_secondary(unsigned int cpu, struct task_struct *idle)
9388

9489
udelay(10);
9590

96-
spin_lock(&boot_lock);
97-
9891
smp_send_reschedule(cpu);
9992

100-
timeout = jiffies + (1 * HZ);
101-
while (time_before(jiffies, timeout)) {
102-
if (pen_release == -1)
103-
break;
104-
}
105-
10693
writel(0, timer_base_addr + OWL_CPU1_ADDR + (cpu - 1) * 4);
10794
writel(0, timer_base_addr + OWL_CPU1_FLAG + (cpu - 1) * 4);
10895

109-
spin_unlock(&boot_lock);
110-
11196
return 0;
11297
}
11398

0 commit comments

Comments
 (0)