]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-alpha/rwsem.h
[PATCH] add sem_is_read/write_locked()
[linux-2.6-omap-h63xx.git] / include / asm-alpha / rwsem.h
index 8e058a67c9a48fdd966877daa81021c54df866ba..fafdd4f7010a821155a86302b4262b091de286f2 100644 (file)
@@ -262,5 +262,10 @@ static inline long rwsem_atomic_update(long val, struct rw_semaphore *sem)
 #endif
 }
 
+static inline int rwsem_is_locked(struct rw_semaphore *sem)
+{
+       return (sem->count != 0);
+}
+
 #endif /* __KERNEL__ */
 #endif /* _ALPHA_RWSEM_H */