]> Pileus Git - ~andy/linux/blobdiff - include/asm-i386/spinlock.h
[PATCH] Pass struct dev pointer to dma_cache_sync()
[~andy/linux] / include / asm-i386 / spinlock.h
index 324329313af8db5b4ea9b235d191307f4e4d7ce2..c18b71fae6b38f6ec0a524509deb4a229de002ad 100644 (file)
@@ -7,6 +7,9 @@
 #include <asm/processor.h>
 #include <linux/compiler.h>
 
+#define CLI_STRING     "cli"
+#define STI_STRING     "sti"
+
 /*
  * Your basic SMP spinlocks, allowing only a single CPU anywhere
  *
@@ -55,12 +58,12 @@ static inline void __raw_spin_lock_flags(raw_spinlock_t *lock, unsigned long fla
                "2:\t"
                "testl $0x200, %1\n\t"
                "jz 4f\n\t"
-               "sti\n"
+               STI_STRING "\n"
                "3:\t"
                "rep;nop\n\t"
                "cmpb $0, %0\n\t"
                "jle 3b\n\t"
-               "cli\n\t"
+               CLI_STRING "\n\t"
                "jmp 1b\n"
                "4:\t"
                "rep;nop\n\t"
@@ -202,4 +205,8 @@ static inline void __raw_write_unlock(raw_rwlock_t *rw)
                                 : "+m" (rw->lock) : : "memory");
 }
 
+#define _raw_spin_relax(lock)  cpu_relax()
+#define _raw_read_relax(lock)  cpu_relax()
+#define _raw_write_relax(lock) cpu_relax()
+
 #endif /* __ASM_SPINLOCK_H */