mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] make spin_is_locked use an explicit signed char case
@ 2002-07-15 13:10 Christoph Hellwig
  0 siblings, 0 replies; only message in thread
From: Christoph Hellwig @ 2002-07-15 13:10 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel

This is a trivial patch from the XFS tree and allows to use spinlock
debugging with code that is compiled with -funsigned-char.  XFS itself
shouldn't need -funsigned-char anymore, but doing the right thing in
spinlock.h doesn't cost anything.


--- linux/include/asm-i386/spinlock.h~	Sun Jun 23 21:38:01 2002
+++ linux/include/asm-i386/spinlock.h	Tue Jun 18 15:10:28 2002
@@ -39,7 +39,7 @@
  * We make no fairness assumptions. They have a cost.
  */
 
-#define spin_is_locked(x)	(*(volatile char *)(&(x)->lock) <= 0)
+#define spin_is_locked(x)	(*(volatile signed char *)(&(x)->lock) <= 0)
 #define spin_unlock_wait(x)	do { barrier(); } while(spin_is_locked(x))
 
 #define spin_lock_string \

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-07-15 13:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-15 13:10 [PATCH] make spin_is_locked use an explicit signed char case Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®