diff options
author | Paul Mackerras <paulus@samba.org> | 2005-10-20 17:09:51 +1000 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-10-20 17:09:51 +1000 |
commit | a9c59264690aea9d0df2d2d76683bc39ec6b7288 (patch) | |
tree | 5cf1bc1181caacf93abe91585ab6e989542527e1 /arch/powerpc/sysdev | |
parent | d8699e65c6bc0a81b5e679ca5b135bfe3c3fb483 (diff) | |
download | talos-op-linux-a9c59264690aea9d0df2d2d76683bc39ec6b7288.tar.gz talos-op-linux-a9c59264690aea9d0df2d2d76683bc39ec6b7288.zip |
powerpc: Move smp_mpic_message_pass into mpic.c
Having it here rather than in arch/ppc64/kernel/smp.c means that
we can use it on 32-bit SMP systems easily with ARCH=powerpc.
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/sysdev')
-rw-r--r-- | arch/powerpc/sysdev/mpic.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c index 02b4d2488bfd..3948e759d41a 100644 --- a/arch/powerpc/sysdev/mpic.c +++ b/arch/powerpc/sysdev/mpic.c @@ -904,4 +904,25 @@ void mpic_request_ipis(void) printk("IPIs requested... \n"); } + +void smp_mpic_message_pass(int target, int msg) +{ + /* make sure we're sending something that translates to an IPI */ + if ((unsigned int)msg > 3) { + printk("SMP %d: smp_message_pass: unknown msg %d\n", + smp_processor_id(), msg); + return; + } + switch (target) { + case MSG_ALL: + mpic_send_ipi(msg, 0xffffffff); + break; + case MSG_ALL_BUT_SELF: + mpic_send_ipi(msg, 0xffffffff & ~(1 << smp_processor_id())); + break; + default: + mpic_send_ipi(msg, 1 << target); + break; + } +} #endif /* CONFIG_SMP */ |