qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 2/4] cpus: assert that the BQL is held in cpu_get_ti


From: Emilio G. Cota
Subject: [Qemu-devel] [PATCH 2/4] cpus: assert that the BQL is held in cpu_get_ticks
Date: Mon, 13 Aug 2018 21:37:59 -0400

Signed-off-by: Emilio G. Cota <address@hidden>
---
 cpus.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/cpus.c b/cpus.c
index b5844b7103..b23bf6fef7 100644
--- a/cpus.c
+++ b/cpus.c
@@ -308,6 +308,8 @@ int64_t cpu_get_ticks(void)
 {
     int64_t ticks;
 
+    g_assert(qemu_mutex_iothread_locked());
+
     if (use_icount) {
         return cpu_get_icount();
     }
-- 
2.17.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]