Skip to contentSkip to conversation

fix typo __atomic_op_fence

kernel-hardening Colin Vidal 2 participants 2 messages Oct 25, 2016 – Oct 26, 2016 Atomic infrastructure

lore
Share & tools
lore
#0 lore raw

Hi Hans,

can you apply this little fix on the
commit b5cafefa6ec2dd549174edc8fbd678c06fcb0472 you have just pushed on Elena's hardened_atomic_on_next ?

Otherwise, any build that use atomic_xchg_relaxed and atomic_cmpxchg_relaxed is broken.

Thanks :)

Colin

include/linux/atomic.h +0 -0
index 4e9972d..ffd2e33 100644
@@ -427,7 +427,7 @@


 #ifndef atomic_xchg_wrap
 #define  atomic_xchg_wrap(...)                         \
-       _atomic_op_fence(atomic_xchg_wrap, __VA_ARGS__) +       __atomic_op_fence(atomic_xchg_wrap, __VA_ARGS__) #endif
 #endif /* atomic_xchg_relaxed */

@@ -456,7 +456,7 @@

 #ifndef atomic_cmpxchg_wrap
 #define  atomic_cmpxchg_wrap(...)                              \
-       _atomic_op_fence(atomic_cmpxchg_wrap, __VA_ARGS__) +       __atomic_op_fence(atomic_cmpxchg_wrap, __VA_ARGS__) #endif
 #endif /* atomic_cmpxchg_relaxed */

#1 lore raw

Hi Colin,

Sorry for the trouble. I have just applied the fix and pushed the update to the repo.

Best Regards,
Elena.

-----Original Message-----
From: Colin Vidal [mailto:[email protected]]
Sent: Tuesday, October 25, 2016 10:36 PM
To: Reshetova, Elena <[email protected]>; Hans Liljestrand <[email protected]>
Cc: [email protected]
Subject: fix typo __atomic_op_fence

Hi Hans,

can you apply this little fix on the
commit b5cafefa6ec2dd549174edc8fbd678c06fcb0472 you have just pushed on Elena's hardened_atomic_on_next ?

Otherwise, any build that use atomic_xchg_relaxed and atomic_cmpxchg_relaxed is broken.

Thanks :)

Colin

include/linux/atomic.h +0 -0
@@ -427,7 +427,7 @@


 #ifndef atomic_xchg_wrap
 #define  atomic_xchg_wrap(...)                         \
-       _atomic_op_fence(atomic_xchg_wrap, __VA_ARGS__) +       __atomic_op_fence(atomic_xchg_wrap, __VA_ARGS__) #endif
 #endif /* atomic_xchg_relaxed */

@@ -456,7 +456,7 @@

 #ifndef atomic_cmpxchg_wrap
 #define  atomic_cmpxchg_wrap(...)                              \
-       _atomic_op_fence(atomic_cmpxchg_wrap, __VA_ARGS__) +       __atomic_op_fence(atomic_cmpxchg_wrap, __VA_ARGS__) #endif
 #endif /* atomic_cmpxchg_relaxed */