[PATCH 6/8] ia64: add support for remotely triggering the block softirq

From: Jens Axboe
Date: Thu Feb 07 2008 - 04:22:27 EST


Signed-off-by: Jens Axboe <jens.axboe@xxxxxxxxxx>
---
arch/ia64/kernel/smp.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/arch/ia64/kernel/smp.c b/arch/ia64/kernel/smp.c
index 4e446aa..96f8ffa 100644
--- a/arch/ia64/kernel/smp.c
+++ b/arch/ia64/kernel/smp.c
@@ -80,6 +80,7 @@ static volatile struct call_data_struct *call_data;
#define IPI_CALL_FUNC 0
#define IPI_CPU_STOP 1
#define IPI_KDUMP_CPU_STOP 3
+#define IPI_BLOCK_SOFTIRQ 4

/* This needs to be cacheline aligned because it is written to by *other* CPUs. */
static DEFINE_PER_CPU_SHARED_ALIGNED(u64, ipi_operation);
@@ -174,6 +175,14 @@ handle_IPI (int irq, void *dev_id)
unw_init_running(kdump_cpu_freeze, NULL);
break;
#endif
+ case IPI_BLOCK_SOFTIRQ: {
+ unsigned long flags;
+
+ local_irq_save(flags);
+ raise_softirq_irqoff(BLOCK_SOFTIRQ);
+ local_irq_restore(flags);
+ break;
+ }
default:
printk(KERN_CRIT "Unknown IPI on CPU %d: %lu\n", this_cpu, which);
break;
@@ -461,6 +470,11 @@ smp_call_function (void (*func) (void *info), void *info, int nonatomic, int wai
}
EXPORT_SYMBOL(smp_call_function);

+void arch_raise_softirq_on_cpu(int cpuid)
+{
+ send_IPI_single(cpuid, IPI_BLOCK_SOFTIRQ);
+}
+
/*
* this function calls the 'stop' function on all other CPUs in the system.
*/
--
1.5.4.22.g7a20

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/