aboutsummaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2021-06-14 16:31:38 -0700
committerPaolo Bonzini <pbonzini@redhat.com>2021-06-16 15:03:26 +0200
commit5d63bd5aad0d80f9c3901c0948354ee3fb7da9bc (patch)
tree1343920242e8cf1560023906b43cec1fd57f68e2 /util
parent52a80715799122c0a31e68c66a10ca901f6454ab (diff)
util: Use real functions for thread-posix QemuRecMutex
Move the declarations from thread-win32.h into thread.h and remove the macro redirection from thread-posix.h. This will be required by following cleanups. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Thomas Huth <thuth@redhat.com> Message-Id: <20210614233143.1221879-4-richard.henderson@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'util')
-rw-r--r--util/qemu-thread-posix.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/util/qemu-thread-posix.c b/util/qemu-thread-posix.c
index dcff5e7c5d..8e2b6653f5 100644
--- a/util/qemu-thread-posix.c
+++ b/util/qemu-thread-posix.c
@@ -124,6 +124,26 @@ void qemu_rec_mutex_init(QemuRecMutex *mutex)
mutex->initialized = true;
}
+void qemu_rec_mutex_destroy(QemuRecMutex *mutex)
+{
+ qemu_mutex_destroy(mutex);
+}
+
+void qemu_rec_mutex_lock_impl(QemuRecMutex *mutex, const char *file, int line)
+{
+ qemu_mutex_lock_impl(mutex, file, line);
+}
+
+int qemu_rec_mutex_trylock_impl(QemuRecMutex *mutex, const char *file, int line)
+{
+ return qemu_mutex_trylock_impl(mutex, file, line);
+}
+
+void qemu_rec_mutex_unlock(QemuRecMutex *mutex)
+{
+ qemu_mutex_unlock(mutex);
+}
+
void qemu_cond_init(QemuCond *cond)
{
int err;