Home | History | Annotate | Line # | Download | only in include
      1 /* $NetBSD: lock.h,v 1.5 2022/07/24 20:28:32 riastradh Exp $ */
      2 
      3 #ifndef	_AARCH64_LOCK_H_
      4 #define	_AARCH64_LOCK_H_
      5 
      6 #include <sys/param.h>
      7 
      8 #ifdef __aarch64__
      9 # ifdef _HARDKERNEL
     10 #  ifdef SPINLOCK_BACKOFF_HOOK
     11 #   undef SPINLOCK_BACKOFF_HOOK
     12 #  endif
     13 #  define SPINLOCK_BACKOFF_HOOK		asm volatile("yield" ::: "memory")
     14 # endif
     15 # include <sys/common_lock.h>
     16 #elif defined(__arm__)
     17 # include <arm/lock.h>
     18 #endif
     19 
     20 #endif	/* _AARCH64_LOCK_H_ */
     21