diff mbox series

[v1,03/12] thread: add qemu_spin_destroy

Message ID 20200529132341.755-3-robert.foley@linaro.org (mailing list archive)
State New, archived
Headers show
Series Add Thread Sanitizer support to QEMU | expand

Commit Message

Robert Foley May 29, 2020, 1:23 p.m. UTC
From: "Emilio G. Cota" <cota@braap.org>

It will be used for TSAN annotations.

Signed-off-by: Emilio G. Cota <cota@braap.org>
Signed-off-by: Robert Foley <robert.foley@linaro.org>
---
 include/qemu/thread.h | 3 +++
 1 file changed, 3 insertions(+)

Comments

Alex Bennée June 2, 2020, 7:23 p.m. UTC | #1
Robert Foley <robert.foley@linaro.org> writes:

> From: "Emilio G. Cota" <cota@braap.org>
>
> It will be used for TSAN annotations.
>
> Signed-off-by: Emilio G. Cota <cota@braap.org>
> Signed-off-by: Robert Foley <robert.foley@linaro.org>

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>

> ---
>  include/qemu/thread.h | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/include/qemu/thread.h b/include/qemu/thread.h
> index d22848138e..e50a073889 100644
> --- a/include/qemu/thread.h
> +++ b/include/qemu/thread.h
> @@ -215,6 +215,9 @@ static inline void qemu_spin_init(QemuSpin *spin)
>      __sync_lock_release(&spin->value);
>  }
>  
> +static inline void qemu_spin_destroy(QemuSpin *spin)
> +{ }
> +
>  static inline void qemu_spin_lock(QemuSpin *spin)
>  {
>      while (unlikely(__sync_lock_test_and_set(&spin->value, true))) {
diff mbox series

Patch

diff --git a/include/qemu/thread.h b/include/qemu/thread.h
index d22848138e..e50a073889 100644
--- a/include/qemu/thread.h
+++ b/include/qemu/thread.h
@@ -215,6 +215,9 @@  static inline void qemu_spin_init(QemuSpin *spin)
     __sync_lock_release(&spin->value);
 }
 
+static inline void qemu_spin_destroy(QemuSpin *spin)
+{ }
+
 static inline void qemu_spin_lock(QemuSpin *spin)
 {
     while (unlikely(__sync_lock_test_and_set(&spin->value, true))) {