patch-2.4.22 linux-2.4.22/include/asm-arm/bitops.h

Next file: linux-2.4.22/include/asm-arm/cpu-multi32.h
Previous file: linux-2.4.22/include/asm-arm/atomic.h
Back to the patch index
Back to the overall index

diff -urN linux-2.4.21/include/asm-arm/bitops.h linux-2.4.22/include/asm-arm/bitops.h
@@ -88,7 +88,7 @@
  */
 static inline int test_bit(int nr, const void * addr)
 {
-    return ((unsigned char *) addr)[nr >> 3] & (1U << (nr & 7));
+    return (((unsigned char *) addr)[nr >> 3] >> (nr & 7)) & 1;
 }	
 
 /*

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)