diff options
| author | Stephen Boyd <sboyd@codeaurora.org> | 2012-09-19 03:16:07 -0400 |
|---|---|---|
| committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-09-19 16:52:08 -0400 |
| commit | 559a593905e583fca23229b916c016e5211c6766 (patch) | |
| tree | 2d79655370beb472af387000d509613f59c96782 /arch/arm/kernel | |
| parent | 38ef2ad5f1d704f1a41599fc70488ca51eb56d3f (diff) | |
ARM: 7536/1: smp: Formalize an IPI for wakeup
Remove the offset from ipi_msg_type and assume that SGI0 is the
wakeup interrupt now that all WFI hotplug users call
gic_raise_softirq() with 0 instead of 1. This allows us to
track how many wakeup interrupts are sent and also removes the
unknown IPI printk message for WFI hotplug based systems.
Reviewed-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/kernel')
| -rw-r--r-- | arch/arm/kernel/smp.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c index ebd8ad274d76..d98c37e97d9d 100644 --- a/arch/arm/kernel/smp.c +++ b/arch/arm/kernel/smp.c | |||
| @@ -51,7 +51,8 @@ | |||
| 51 | struct secondary_data secondary_data; | 51 | struct secondary_data secondary_data; |
| 52 | 52 | ||
| 53 | enum ipi_msg_type { | 53 | enum ipi_msg_type { |
| 54 | IPI_TIMER = 2, | 54 | IPI_WAKEUP, |
| 55 | IPI_TIMER, | ||
| 55 | IPI_RESCHEDULE, | 56 | IPI_RESCHEDULE, |
| 56 | IPI_CALL_FUNC, | 57 | IPI_CALL_FUNC, |
| 57 | IPI_CALL_FUNC_SINGLE, | 58 | IPI_CALL_FUNC_SINGLE, |
| @@ -347,7 +348,8 @@ void arch_send_call_function_single_ipi(int cpu) | |||
| 347 | } | 348 | } |
| 348 | 349 | ||
| 349 | static const char *ipi_types[NR_IPI] = { | 350 | static const char *ipi_types[NR_IPI] = { |
| 350 | #define S(x,s) [x - IPI_TIMER] = s | 351 | #define S(x,s) [x] = s |
| 352 | S(IPI_WAKEUP, "CPU wakeup interrupts"), | ||
| 351 | S(IPI_TIMER, "Timer broadcast interrupts"), | 353 | S(IPI_TIMER, "Timer broadcast interrupts"), |
| 352 | S(IPI_RESCHEDULE, "Rescheduling interrupts"), | 354 | S(IPI_RESCHEDULE, "Rescheduling interrupts"), |
| 353 | S(IPI_CALL_FUNC, "Function call interrupts"), | 355 | S(IPI_CALL_FUNC, "Function call interrupts"), |
| @@ -500,10 +502,13 @@ void handle_IPI(int ipinr, struct pt_regs *regs) | |||
| 500 | unsigned int cpu = smp_processor_id(); | 502 | unsigned int cpu = smp_processor_id(); |
| 501 | struct pt_regs *old_regs = set_irq_regs(regs); | 503 | struct pt_regs *old_regs = set_irq_regs(regs); |
| 502 | 504 | ||
| 503 | if (ipinr >= IPI_TIMER && ipinr < IPI_TIMER + NR_IPI) | 505 | if (ipinr < NR_IPI) |
| 504 | __inc_irq_stat(cpu, ipi_irqs[ipinr - IPI_TIMER]); | 506 | __inc_irq_stat(cpu, ipi_irqs[ipinr]); |
| 505 | 507 | ||
| 506 | switch (ipinr) { | 508 | switch (ipinr) { |
| 509 | case IPI_WAKEUP: | ||
| 510 | break; | ||
| 511 | |||
| 507 | case IPI_TIMER: | 512 | case IPI_TIMER: |
| 508 | irq_enter(); | 513 | irq_enter(); |
| 509 | ipi_timer(); | 514 | ipi_timer(); |
