diff options
Diffstat (limited to 'sys/mips/include/atomic.h')
-rw-r--r-- | sys/mips/include/atomic.h | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/sys/mips/include/atomic.h b/sys/mips/include/atomic.h index 9a0c557..b43cc61 100644 --- a/sys/mips/include/atomic.h +++ b/sys/mips/include/atomic.h @@ -44,20 +44,16 @@ * do not have atomic operations defined for them, but generally shouldn't * need atomic operations. */ +#ifndef __MIPS_PLATFORM_SYNC_NOPS +#define __MIPS_PLATFORM_SYNC_NOPS "" +#endif static __inline void mips_sync(void) { - __asm __volatile (".set noreorder\n\t" - "sync\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" - "nop\n\t" + __asm __volatile (".set noreorder\n" + "\tsync\n" + __MIPS_PLATFORM_SYNC_NOPS ".set reorder\n" : : : "memory"); } |