summaryrefslogtreecommitdiffstats
path: root/include/asm-ppc
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-10-30 20:37:44 -0500
committerJeff Garzik <jgarzik@pobox.com>2005-10-30 20:37:44 -0500
commit9e0cb06b17be7e562cbdaba2768649f025826dc6 (patch)
treeaaf5ef8c6cd11764d222df9c446ad9af17e0020e /include/asm-ppc
parent23da0c20ef1c1f0432f373e0e2233a6b6ab2678f (diff)
parent6e9d6b8ee4e0c37d3952256e6472c57490d6780d (diff)
downloadkernel-crypto-9e0cb06b17be7e562cbdaba2768649f025826dc6.tar.gz
kernel-crypto-9e0cb06b17be7e562cbdaba2768649f025826dc6.tar.xz
kernel-crypto-9e0cb06b17be7e562cbdaba2768649f025826dc6.zip
Merge branch 'master'
Diffstat (limited to 'include/asm-ppc')
-rw-r--r--include/asm-ppc/rwsem.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/asm-ppc/rwsem.h b/include/asm-ppc/rwsem.h
index 3e738f483c1..3501ea72f88 100644
--- a/include/asm-ppc/rwsem.h
+++ b/include/asm-ppc/rwsem.h
@@ -168,5 +168,10 @@ static inline int rwsem_atomic_update(int delta, struct rw_semaphore *sem)
return atomic_add_return(delta, (atomic_t *)(&sem->count));
}
+static inline int rwsem_is_locked(struct rw_semaphore *sem)
+{
+ return (sem->count != 0);
+}
+
#endif /* __KERNEL__ */
#endif /* _PPC_RWSEM_XADD_H */