diff options
author | Max Filippov <jcmvbkbc@gmail.com> | 2019-01-01 14:08:32 -0800 |
---|---|---|
committer | Max Filippov <jcmvbkbc@gmail.com> | 2019-02-07 12:24:20 -0800 |
commit | 579afe866f52adcd921272a224ab36733051059c (patch) | |
tree | 52e253ca6b73e447d269df4e11b07a0836b7cdd2 /arch/xtensa/include/asm/spinlock_types.h | |
parent | af3d890b4303cfc9df4b785c852246d4c7013436 (diff) | |
download | linux-579afe866f52adcd921272a224ab36733051059c.tar.bz2 |
xtensa: use generic spinlock/rwlock implementation
Drop custom spinlock/rwlock code and use ones from asm-generic. This way
there is less code duplication (atomic primitives are reused).
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Diffstat (limited to 'arch/xtensa/include/asm/spinlock_types.h')
-rw-r--r-- | arch/xtensa/include/asm/spinlock_types.h | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/arch/xtensa/include/asm/spinlock_types.h b/arch/xtensa/include/asm/spinlock_types.h index bb1fe6c1816e..64c9389254f1 100644 --- a/arch/xtensa/include/asm/spinlock_types.h +++ b/arch/xtensa/include/asm/spinlock_types.h @@ -2,20 +2,11 @@ #ifndef __ASM_SPINLOCK_TYPES_H #define __ASM_SPINLOCK_TYPES_H -#ifndef __LINUX_SPINLOCK_TYPES_H +#if !defined(__LINUX_SPINLOCK_TYPES_H) && !defined(__ASM_SPINLOCK_H) # error "please don't include this file directly" #endif -typedef struct { - volatile unsigned int slock; -} arch_spinlock_t; - -#define __ARCH_SPIN_LOCK_UNLOCKED { 0 } - -typedef struct { - volatile unsigned int lock; -} arch_rwlock_t; - -#define __ARCH_RW_LOCK_UNLOCKED { 0 } +#include <asm-generic/qspinlock_types.h> +#include <asm-generic/qrwlock_types.h> #endif |