diff options
Diffstat (limited to 'sys/arch/sparc')
-rw-r--r-- | sys/arch/sparc/include/atomic.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/sys/arch/sparc/include/atomic.h b/sys/arch/sparc/include/atomic.h new file mode 100644 index 00000000000..9f4e454b806 --- /dev/null +++ b/sys/arch/sparc/include/atomic.h @@ -0,0 +1,20 @@ +/* $OpenBSD: atomic.h,v 1.1 2007/02/06 17:13:33 art Exp $ */ + +/* Public Domain */ + +#ifndef __SPARC_ATOMIC_H__ +#define __SPARC_ATOMIC_H__ + +static __inline void +atomic_setbits_int(__volatile unsigned int *uip, unsigned int v) +{ + *uip |= v; +} + +static __inline void +atomic_clearbits_int(__volatile unsigned int *uip, unsigned int v) +{ + *uip &= ~v; +} + +#endif |