vserver 1.9.5.x5
[linux-2.6.git] / include / asm-alpha / spinlock.h
index b5f3554..5e35c5d 100644 (file)
@@ -23,6 +23,9 @@ typedef struct {
        struct task_struct * task;
        const char *base_file;
 #endif
+#ifdef CONFIG_PREEMPT
+       unsigned int break_lock;
+#endif
 } spinlock_t;
 
 #ifdef CONFIG_DEBUG_SPINLOCK
@@ -96,12 +99,14 @@ static inline int _raw_spin_trylock(spinlock_t *lock)
 
 typedef struct {
        volatile unsigned int write_lock:1, read_counter:31;
+#ifdef CONFIG_PREEMPT
+       unsigned int break_lock;
+#endif
 } /*__attribute__((aligned(32)))*/ rwlock_t;
 
 #define RW_LOCK_UNLOCKED (rwlock_t) { 0, 0 }
 
 #define rwlock_init(x) do { *(x) = RW_LOCK_UNLOCKED; } while(0)
-#define rwlock_is_locked(x)    (*(volatile int *)(x) != 0)
 
 #ifdef CONFIG_DEBUG_RWLOCK
 extern void _raw_write_lock(rwlock_t * lock);