mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 17:53:56 -06:00
coroutine-lock: add mutex argument to CoQueue APIs
All that CoQueue needs in order to become thread-safe is help from an external mutex. Add this to the API. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Fam Zheng <famz@redhat.com> Message-id: 20170213181244.16297-6-pbonzini@redhat.com Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
f8c6e1cbc3
commit
1ace7ceac5
9 changed files with 34 additions and 16 deletions
|
@ -2374,7 +2374,7 @@ static void coroutine_fn v9fs_flush(void *opaque)
|
|||
/*
|
||||
* Wait for pdu to complete.
|
||||
*/
|
||||
qemu_co_queue_wait(&cancel_pdu->complete);
|
||||
qemu_co_queue_wait(&cancel_pdu->complete, NULL);
|
||||
cancel_pdu->cancelled = 0;
|
||||
pdu_free(cancel_pdu);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue