You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
780 B

  1. --- a/src/atomicvar.h
  2. +++ b/src/atomicvar.h
  3. @@ -81,7 +81,7 @@
  4. #define ANNOTATE_HAPPENS_AFTER(v) ((void) v)
  5. #endif
  6. -#if !defined(__ATOMIC_VAR_FORCE_SYNC_MACROS) && defined(__STDC_VERSION__) && \
  7. +#if defined(CONFIG_EDAC_ATOMIC_SCRUB) && !defined(__ATOMIC_VAR_FORCE_SYNC_MACROS) && defined(__STDC_VERSION__) && \
  8. (__STDC_VERSION__ >= 201112L) && !defined(__STDC_NO_ATOMICS__)
  9. /* Use '_Atomic' keyword if the compiler supports. */
  10. #undef redisAtomic
  11. @@ -126,7 +126,7 @@
  12. __atomic_store_n(&var,value,__ATOMIC_SEQ_CST)
  13. #define REDIS_ATOMIC_API "atomic-builtin"
  14. -#elif defined(HAVE_ATOMIC)
  15. +#elif defined(CONFIG_EDAC_ATOMIC_SCRUB) && defined(HAVE_ATOMIC)
  16. /* Implementation using __sync macros. */
  17. #define atomicIncr(var,count) __sync_add_and_fetch(&var,(count))