X-Git-Url: https://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=urcu%2Farch%2Fppc.h;h=dbdfec8a58dd3f29414fbc99aa48e83fa701cff3;hp=1068b288027bda8a5c1f47ce0229e484de827fc6;hb=67ecffc0f530a7b5c4dd5111ea7dd3213da8eb91;hpb=1b85da854e5f034224ea208d96d6ed9d709e7976 diff --git a/urcu/arch/ppc.h b/urcu/arch/ppc.h index 1068b28..dbdfec8 100644 --- a/urcu/arch/ppc.h +++ b/urcu/arch/ppc.h @@ -24,10 +24,11 @@ #include #include +#include #ifdef __cplusplus extern "C" { -#endif +#endif /* Include size of POWER5+ L3 cache lines: 256 bytes */ #define CAA_CACHE_LINE_SIZE 256 @@ -81,6 +82,8 @@ extern "C" { rval; \ }) +#define HAS_CAA_GET_CYCLES + typedef unsigned long long cycles_t; #ifdef __powerpc64__ @@ -104,7 +107,15 @@ static inline cycles_t caa_get_cycles(void) } #endif -#ifdef __cplusplus +/* + * Define the membarrier system call number if not yet available in the + * system headers. + */ +#ifndef __NR_membarrier +#define __NR_membarrier 365 +#endif + +#ifdef __cplusplus } #endif