1*4882a593Smuzhiyun /* 2*4882a593Smuzhiyun * Copyright (C) 2014 Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> 3*4882a593Smuzhiyun * 4*4882a593Smuzhiyun * This file is licensed under the terms of the GNU General Public License 5*4882a593Smuzhiyun * version 2. This program is licensed "as is" without any warranty of any 6*4882a593Smuzhiyun * kind, whether express or implied. 7*4882a593Smuzhiyun */ 8*4882a593Smuzhiyun 9*4882a593Smuzhiyun #ifndef __ASM_OPENRISC_SMP_H 10*4882a593Smuzhiyun #define __ASM_OPENRISC_SMP_H 11*4882a593Smuzhiyun 12*4882a593Smuzhiyun #include <asm/spr.h> 13*4882a593Smuzhiyun #include <asm/spr_defs.h> 14*4882a593Smuzhiyun 15*4882a593Smuzhiyun #define raw_smp_processor_id() (current_thread_info()->cpu) 16*4882a593Smuzhiyun #define hard_smp_processor_id() mfspr(SPR_COREID) 17*4882a593Smuzhiyun 18*4882a593Smuzhiyun extern void smp_init_cpus(void); 19*4882a593Smuzhiyun 20*4882a593Smuzhiyun extern void arch_send_call_function_single_ipi(int cpu); 21*4882a593Smuzhiyun extern void arch_send_call_function_ipi_mask(const struct cpumask *mask); 22*4882a593Smuzhiyun 23*4882a593Smuzhiyun extern void set_smp_cross_call(void (*)(const struct cpumask *, unsigned int)); 24*4882a593Smuzhiyun extern void handle_IPI(unsigned int ipi_msg); 25*4882a593Smuzhiyun 26*4882a593Smuzhiyun #endif /* __ASM_OPENRISC_SMP_H */ 27