aboutsummaryrefslogtreecommitdiff
path: root/arch/parisc/include/asm/spinlock_types.h
diff options
context:
space:
mode:
authorKyle McMartin <kyle@mcmartin.ca>2008-07-28 23:02:13 -0400
committerKyle McMartin <kyle@hera.kernel.org>2008-10-10 16:32:29 +0000
commitdeae26bf6a10e47983606f5df080b91e97650ead (patch)
tree84a8a68145d0f713d7c5a1f9e6b3b03be9b3a4c8 /arch/parisc/include/asm/spinlock_types.h
parent6c86cb8237bf08443806089130dc108051569a93 (diff)
parisc: move include/asm-parisc to arch/parisc/include/asm
Diffstat (limited to 'arch/parisc/include/asm/spinlock_types.h')
-rw-r--r--arch/parisc/include/asm/spinlock_types.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/parisc/include/asm/spinlock_types.h b/arch/parisc/include/asm/spinlock_types.h
new file mode 100644
index 00000000000..3f72f47cf4b
--- /dev/null
+++ b/arch/parisc/include/asm/spinlock_types.h
@@ -0,0 +1,21 @@
+#ifndef __ASM_SPINLOCK_TYPES_H
+#define __ASM_SPINLOCK_TYPES_H
+
+typedef struct {
+#ifdef CONFIG_PA20
+ volatile unsigned int slock;
+# define __RAW_SPIN_LOCK_UNLOCKED { 1 }
+#else
+ volatile unsigned int lock[4];
+# define __RAW_SPIN_LOCK_UNLOCKED { { 1, 1, 1, 1 } }
+#endif
+} raw_spinlock_t;
+
+typedef struct {
+ raw_spinlock_t lock;
+ volatile int counter;
+} raw_rwlock_t;
+
+#define __RAW_RW_LOCK_UNLOCKED { __RAW_SPIN_LOCK_UNLOCKED, 0 }
+
+#endif