mirror of https://github.com/xemu-project/xemu.git
thread: add qemu_spin_destroy
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> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20200609200738.445-4-robert.foley@linaro.org> Message-Id: <20200612190237.30436-7-alex.bennee@linaro.org>
This commit is contained in:
parent
0c0fcc2052
commit
4384a70d01
|
@ -215,6 +215,9 @@ static inline void qemu_spin_init(QemuSpin *spin)
|
||||||
__sync_lock_release(&spin->value);
|
__sync_lock_release(&spin->value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline void qemu_spin_destroy(QemuSpin *spin)
|
||||||
|
{ }
|
||||||
|
|
||||||
static inline void qemu_spin_lock(QemuSpin *spin)
|
static inline void qemu_spin_lock(QemuSpin *spin)
|
||||||
{
|
{
|
||||||
while (unlikely(__sync_lock_test_and_set(&spin->value, true))) {
|
while (unlikely(__sync_lock_test_and_set(&spin->value, true))) {
|
||||||
|
|
Loading…
Reference in New Issue