aboutsummaryrefslogtreecommitdiff
path: root/include/qemu/rcu.h
diff options
context:
space:
mode:
authorDaniel Brodsky <dnbrdsky@gmail.com>2020-04-03 21:21:07 -0700
committerStefan Hajnoczi <stefanha@redhat.com>2020-05-04 16:07:43 +0100
commit56f21718b8767a1b523f2a14107d6307336ca51d (patch)
tree5b14e970adb370ca3b034e8678e8982329a0a9d1 /include/qemu/rcu.h
parent05509c8e6def8a23878b93eda3163b7b405a5d57 (diff)
downloadqemu-56f21718b8767a1b523f2a14107d6307336ca51d.zip
qemu-56f21718b8767a1b523f2a14107d6307336ca51d.tar.gz
qemu-56f21718b8767a1b523f2a14107d6307336ca51d.tar.bz2
lockable: fix __COUNTER__ macro to be referenced properly
- __COUNTER__ doesn't work with ## concat - replaced ## with glue() macro so __COUNTER__ is evaluated Fixes: 3284c3ddc4 Signed-off-by: Daniel Brodsky <dnbrdsky@gmail.com> Message-id: 20200404042108.389635-2-dnbrdsky@gmail.com Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'include/qemu/rcu.h')
-rw-r--r--include/qemu/rcu.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/qemu/rcu.h b/include/qemu/rcu.h
index 9c82683..570aa60 100644
--- a/include/qemu/rcu.h
+++ b/include/qemu/rcu.h
@@ -170,7 +170,7 @@ static inline void rcu_read_auto_unlock(RCUReadAuto *r)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(RCUReadAuto, rcu_read_auto_unlock)
#define WITH_RCU_READ_LOCK_GUARD() \
- WITH_RCU_READ_LOCK_GUARD_(_rcu_read_auto##__COUNTER__)
+ WITH_RCU_READ_LOCK_GUARD_(glue(_rcu_read_auto, __COUNTER__))
#define WITH_RCU_READ_LOCK_GUARD_(var) \
for (g_autoptr(RCUReadAuto) var = rcu_read_auto_lock(); \