atomic.h File Reference

Go to the source code of this file.

Data Structures

struct  atomic_t

Defines

#define ATOMIC_INIT(i)   { (i) }
#define atomic_read(v)   ((v)->counter)
 atomic_read - read atomic variable : pointer of type atomic_t
#define atomic_set(v, i)   (((v)->counter) = (i))
 atomic_set - set atomic variable : pointer of type atomic_t : required value

Functions

static __inline__ __attribute__ ((always_inline)) void atomic_inc(atomic_t *v)
 atomic_inc - increment atomic variable : pointer of type atomic_t


Define Documentation

#define ATOMIC_INIT (  )     { (i) }

Definition at line 11 of file atomic.h.

#define atomic_read (  )     ((v)->counter)

atomic_read - read atomic variable : pointer of type atomic_t

Atomically reads the value of . Note that the guaranteed useful range of an atomic_t is only 24 bits.

Definition at line 25 of file atomic.h.

#define atomic_set ( v,
 )     (((v)->counter) = (i))

atomic_set - set atomic variable : pointer of type atomic_t : required value

Atomically sets the value of to . Note that the guaranteed useful range of an atomic_t is only 24 bits.

Definition at line 35 of file atomic.h.


Function Documentation

static __inline__ __attribute__ ( (always_inline)   )  [static]

atomic_inc - increment atomic variable : pointer of type atomic_t

atomic_dec - decrement atomic variable : pointer of type atomic_t

Atomically increments by 1. Note that the guaranteed useful range of an atomic_t is only 24 bits.

Atomically decrements by 1. Note that the guaranteed useful range of an atomic_t is only 24 bits.

Definition at line 44 of file atomic.h.

References __asm__().

Here is the call graph for this function:


Generated on Mon Dec 29 10:55:10 2008 for coreboot by  doxygen 1.5.5