]> git.baikalelectronics.ru Git - kernel.git/commit
sparc64: Fix rwsem constant bug leading to hangs.
authorDavid S. Miller <davem@davemloft.net>
Wed, 18 Aug 2010 00:09:53 +0000 (17:09 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 18 Aug 2010 00:09:53 +0000 (17:09 -0700)
commita0cacac60f0077019a0d933bb6860ec4e7e1174b
tree08b1a29f9110325e335cebe6cb88fd4f46f038ad
parent12690cf9b32ae29fe1d7afb8a02c72406b4a3523
sparc64: Fix rwsem constant bug leading to hangs.

As noticed by Linus, it is critical that some of the
rwsem constants be signed.  Yet, hex constants are
unsigned unless explicitly casted or negated.

The most critical one is RWSEM_WAITING_BIAS.

This bug was exacerbated by commit
b841fed27271bdfa7ae0feaa7e9332f59b32d4bd ("rwsem: wake queued readers
when writer blocks on active read lock")

Signed-off-by: David S. Miller <davem@davemloft.net>
arch/sparc/include/asm/rwsem-const.h