Changeset View
Changeset View
Standalone View
Standalone View
sys/arm/include/atomic-v4.h
Show First 20 Lines • Show All 537 Lines • ▼ Show 20 Lines | |||||
static __inline void | static __inline void | ||||
atomic_subtract_long(volatile u_long *p, u_long v) | atomic_subtract_long(volatile u_long *p, u_long v) | ||||
{ | { | ||||
atomic_subtract_32((volatile uint32_t *)p, v); | atomic_subtract_32((volatile uint32_t *)p, v); | ||||
} | } | ||||
static __inline u_long | |||||
atomic_swap_long(volatile u_long *p, u_long v) | |||||
{ | |||||
return (atomic_swap_32((volatile uint32_t *)p, v)); | |||||
} | |||||
/* | /* | ||||
* ARMv5 does not support SMP. For both kernel and user modes, only a | * ARMv5 does not support SMP. For both kernel and user modes, only a | ||||
* compiler barrier is needed for fences, since CPU is always | * compiler barrier is needed for fences, since CPU is always | ||||
* self-consistent. | * self-consistent. | ||||
*/ | */ | ||||
static __inline void | static __inline void | ||||
atomic_thread_fence_acq(void) | atomic_thread_fence_acq(void) | ||||
{ | { | ||||
Show All 26 Lines |