summaryrefslogtreecommitdiffstats
path: root/include/asm-mips/spinlock.h
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2001-03-28 01:35:12 +0000
committerRalf Baechle <ralf@linux-mips.org>2001-03-28 01:35:12 +0000
commit0b9049739779f6052eb8069f3dde7c3a7f14a591 (patch)
tree9630c1ea481dd1c429a2692067316237957d6e07 /include/asm-mips/spinlock.h
parent12e00f34ea0db712ce70bc3eed334c81b3d6a344 (diff)
SMP for 32-bit kernel, support for Sibyte SB1. Patch from Justin
with minor changes by me.
Diffstat (limited to 'include/asm-mips/spinlock.h')
-rw-r--r--include/asm-mips/spinlock.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/asm-mips/spinlock.h b/include/asm-mips/spinlock.h
index 4ac282bbc..61ebfa660 100644
--- a/include/asm-mips/spinlock.h
+++ b/include/asm-mips/spinlock.h
@@ -21,6 +21,9 @@ typedef struct {
#define spin_lock_init(x) do { (x)->lock = 0; } while(0);
+#define spin_is_locked(x) ((x)->lock != 0)
+#define spin_unlock_wait(x) ({ do { barrier(); } while ((x)->lock); })
+
/*
* Simple spin lock operations. There are two variants, one clears IRQ's
* on the local processor, one does not.