Home | History | Annotate | Line # | Download | only in arch
      1 // SPDX-FileCopyrightText: 2010 Paolo Bonzini <pbonzini (at) redhat.com>
      2 //
      3 // SPDX-License-Identifier: LGPL-2.1-or-later
      4 
      5 #ifndef _URCU_ARCH_ALPHA_H
      6 #define _URCU_ARCH_ALPHA_H
      7 
      8 /*
      9  * arch_alpha.h: trivial definitions for the Alpha architecture.
     10  */
     11 
     12 #include <urcu/compiler.h>
     13 #include <urcu/config.h>
     14 #include <urcu/syscall-compat.h>
     15 
     16 #ifdef __cplusplus
     17 extern "C" {
     18 #endif
     19 
     20 #define cmm_mb()			__asm__ __volatile__ ("mb":::"memory")
     21 #define cmm_wmb()			__asm__ __volatile__ ("wmb":::"memory")
     22 #define cmm_read_barrier_depends()	__asm__ __volatile__ ("mb":::"memory")
     23 
     24 /*
     25  * On Linux, define the membarrier system call number if not yet available in
     26  * the system headers.
     27  */
     28 #if (defined(__linux__) && !defined(__NR_membarrier))
     29 #define __NR_membarrier		517
     30 #endif
     31 
     32 #ifdef __cplusplus
     33 }
     34 #endif
     35 
     36 #include <urcu/arch/generic.h>
     37 
     38 #endif /* _URCU_ARCH_ALPHA_H */
     39