X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-i386%2Frwsem.h;h=be4ab859238ec3322e44c0e221deb17e339f3b2d;hb=43bc926fffd92024b46cafaf7350d669ba9ca884;hp=7625a675852f811b5aab15c240e803f122168d7f;hpb=cee37fe97739d85991964371c1f3a745c00dd236;p=linux-2.6.git diff --git a/include/asm-i386/rwsem.h b/include/asm-i386/rwsem.h index 7625a6758..be4ab8592 100644 --- a/include/asm-i386/rwsem.h +++ b/include/asm-i386/rwsem.h @@ -284,5 +284,10 @@ LOCK_PREFIX "xadd %0,(%2)" return tmp+delta; } +static inline int rwsem_is_locked(struct rw_semaphore *sem) +{ + return (sem->count != 0); +} + #endif /* __KERNEL__ */ #endif /* _I386_RWSEM_H */