diff options
author | Stafford Horne <shorne@gmail.com> | 2017-03-24 07:13:03 +0900 |
---|---|---|
committer | Stafford Horne <shorne@gmail.com> | 2017-11-03 14:01:12 +0900 |
commit | b5f8217615bb197af33c0cc71b14783b194fed6e (patch) | |
tree | a93d94efbb158066244235d3c9aaabad05d33f0e /arch/openrisc/include/asm/spinlock.h | |
parent | 489e0f802db708c69004f64d92a3e1b70731614a (diff) | |
download | blackbird-obmc-linux-b5f8217615bb197af33c0cc71b14783b194fed6e.tar.gz blackbird-obmc-linux-b5f8217615bb197af33c0cc71b14783b194fed6e.zip |
openrisc: use qspinlocks and qrwlocks
Enable OpenRISC to use qspinlocks and qrwlocks for upcoming SMP support.
Signed-off-by: Stafford Horne <shorne@gmail.com>
Diffstat (limited to 'arch/openrisc/include/asm/spinlock.h')
-rw-r--r-- | arch/openrisc/include/asm/spinlock.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/arch/openrisc/include/asm/spinlock.h b/arch/openrisc/include/asm/spinlock.h index fd00a3a24123..9b761e0e22c3 100644 --- a/arch/openrisc/include/asm/spinlock.h +++ b/arch/openrisc/include/asm/spinlock.h @@ -19,6 +19,16 @@ #ifndef __ASM_OPENRISC_SPINLOCK_H #define __ASM_OPENRISC_SPINLOCK_H -#error "or32 doesn't do SMP yet" +#include <asm/qspinlock.h> + +#include <asm/qrwlock.h> + +#define arch_read_lock_flags(lock, flags) arch_read_lock(lock) +#define arch_write_lock_flags(lock, flags) arch_write_lock(lock) + +#define arch_spin_relax(lock) cpu_relax() +#define arch_read_relax(lock) cpu_relax() +#define arch_write_relax(lock) cpu_relax() + #endif |