Increase the size of seq_ctr_t to 32 bits (XCC)
authorBarret Rhoden <brho@cs.berkeley.edu>
Tue, 19 Apr 2016 20:33:56 +0000 (13:33 -0700)
committerBarret Rhoden <brho@cs.berkeley.edu>
Tue, 19 Apr 2016 20:37:29 +0000 (13:37 -0700)
8 bits was too small - we could have 256 writes that could be
interpreted as "nothing changed."

Reinstall your kernel headers.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/include/ros/atomic.h

index 1bf4c69..943c242 100644 (file)
@@ -17,7 +17,7 @@ typedef void* atomic_t;
  * after.  If the value has changed, the reader needs to re-read.  If the value
  * is odd, a write is in progress or it is otherwise invalid/locked. */
 
-typedef uint8_t seq_ctr_t;
+typedef uint32_t seq_ctr_t;
 #define SEQCTR_INITIALIZER 0
 
 static inline bool seq_is_locked(seq_ctr_t seq_ctr);