On 10/08/2015 17:26, fred.kon...@greensocs.com wrote:
+qemu_mutex_lock(cpu-work_mutex);
while ((wi = cpu-queued_work_first)) {
cpu-queued_work_first = wi-next;
+qemu_mutex_unlock(cpu-work_mutex);
wi-func(wi-data);
+
On 10/08/2015 17:59, Paolo Bonzini wrote:
On 10/08/2015 17:26, fred.kon...@greensocs.com wrote:
+qemu_mutex_lock(cpu-work_mutex);
while ((wi = cpu-queued_work_first)) {
cpu-queued_work_first = wi-next;
+qemu_mutex_unlock(cpu-work_mutex);
On 10/08/2015 18:04, Frederic Konrad wrote:
On 10/08/2015 17:59, Paolo Bonzini wrote:
On 10/08/2015 17:26, fred.kon...@greensocs.com wrote:
+qemu_mutex_lock(cpu-work_mutex);
while ((wi = cpu-queued_work_first)) {
cpu-queued_work_first = wi-next;
+
From: KONRAD Frederic fred.kon...@greensocs.com
This protects queued_work_* used by async_run_on_cpu, run_on_cpu and
flush_queued_work with a new lock (work_mutex) to prevent multiple (concurrent)
access.
Signed-off-by: KONRAD Frederic fred.kon...@greensocs.com
Reviewed-by: Alex Bennée