patch-2.1.121 linux/include/asm-arm/spinlock.h

Next file: linux/include/asm-arm/system.h
Previous file: linux/include/asm-arm/signal.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.120/linux/include/asm-arm/spinlock.h linux/include/asm-arm/spinlock.h
@@ -6,8 +6,13 @@
 /*
  * Your basic spinlocks, allowing only a single CPU anywhere
  */
-typedef struct { } spinlock_t;
-#define SPIN_LOCK_UNLOCKED { }
+#if (__GNUC__ > 2) || (__GNUC_MINOR__ >= 8)
+  typedef struct { } spinlock_t;
+# define SPIN_LOCK_UNLOCKED { }
+#else
+  typedef unsigned char spinlock_t;
+# define SPIN_LOCK_UNLOCKED 0
+#endif
 
 #define spin_lock_init(lock)	do { } while(0)
 #define spin_lock(lock)		do { } while(0)

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov