libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.
sync.c File Reference
Include dependency graph for sync.c:

Go to the source code of this file.

Functions

void __dmb ()
 
uint32_t __ldrex (volatile uint32_t *addr)
 
uint32_t __strex (uint32_t val, volatile uint32_t *addr)
 
void mutex_lock (mutex_t *m)
 
uint32_t mutex_trylock (mutex_t *m)
 
void mutex_unlock (mutex_t *m)
 

Function Documentation

◆ __dmb()

void __dmb ( void  )

Definition at line 23 of file sync.c.

Referenced by mutex_trylock(), and mutex_unlock().

Here is the caller graph for this function:

◆ __ldrex()

uint32_t __ldrex ( volatile uint32_t *  addr)

Definition at line 31 of file sync.c.

Referenced by mutex_trylock().

Here is the caller graph for this function:

◆ __strex()

uint32_t __strex ( uint32_t  val,
volatile uint32_t *  addr 
)

Definition at line 38 of file sync.c.

Referenced by mutex_trylock().

Here is the caller graph for this function:

◆ mutex_lock()

void mutex_lock ( mutex_t m)

Definition at line 46 of file sync.c.

References mutex_trylock().

Here is the call graph for this function:

◆ mutex_trylock()

uint32_t mutex_trylock ( mutex_t m)

Definition at line 52 of file sync.c.

References __dmb(), __ldrex(), __strex(), MUTEX_LOCKED, and MUTEX_UNLOCKED.

Referenced by mutex_lock().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mutex_unlock()

void mutex_unlock ( mutex_t m)

Definition at line 70 of file sync.c.

References __dmb(), and MUTEX_UNLOCKED.

Here is the call graph for this function: