From: Michael Jeanson Date: Tue, 1 Mar 2022 20:41:53 +0000 (-0500) Subject: alpha: allocate membarrier system call number X-Git-Tag: v0.14.0~35 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=192ea849f267a236eef52e649846560f95d4d41c;p=urcu.git alpha: allocate membarrier system call number The membarrier syscall has been allocated in Linux 4.13, allocate its number in our architecture header if the system headers don't allocate it. Change-Id: Iebb77b94bf803a7a8b7ebd9f4124219f386334ae Signed-off-by: Michael Jeanson Signed-off-by: Mathieu Desnoyers --- diff --git a/include/urcu/arch/alpha.h b/include/urcu/arch/alpha.h index e61f82c..dc33e28 100644 --- a/include/urcu/arch/alpha.h +++ b/include/urcu/arch/alpha.h @@ -33,6 +33,14 @@ extern "C" { #define cmm_wmb() __asm__ __volatile__ ("wmb":::"memory") #define cmm_read_barrier_depends() __asm__ __volatile__ ("mb":::"memory") +/* + * On Linux, define the membarrier system call number if not yet available in + * the system headers. + */ +#if (defined(__linux__) && !defined(__NR_membarrier)) +#define __NR_membarrier 517 +#endif + #ifdef __cplusplus } #endif