qemu-e2k/tests
Kevin Wolf 6bc0bcc89f block: Fix deadlocks in bdrv_graph_wrunlock()
bdrv_graph_wrunlock() calls aio_poll(), which may run callbacks that
have a nested event loop. Nested event loops can depend on other
iothreads making progress, so in order to allow them to make progress it
must not hold the AioContext lock of another thread while calling
aio_poll().

This introduces a @bs parameter to bdrv_graph_wrunlock() whose
AioContext is temporarily dropped (which matches bdrv_graph_wrlock()),
and a bdrv_graph_wrunlock_ctx() that can be used if the BlockDriverState
doesn't necessarily exist any more when unlocking.

This also requires a change to bdrv_schedule_unref(), which was relying
on the incorrectly taken lock. It needs to take the lock itself now.
While this is a separate bug, it can't be fixed a separate patch because
otherwise the intermediate state would either deadlock or try to release
a lock that we don't even hold.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-ID: <20231115172012.112727-3-kwolf@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
[kwolf: Fixed up bdrv_schedule_unref()]
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2023-11-21 12:45:21 +01:00
..
avocado tests/avocado: Enable reverse_debugging.py tests in gitlab CI 2023-11-16 14:22:56 +01:00
bench migration/xbzrle: Use i386 host/cpuinfo.h 2023-05-23 16:51:18 -07:00
data tests/data/qobject/qdict.txt: Avoid non-inclusive words 2023-11-15 11:09:17 +03:00
decode tests/: spelling fixes 2023-09-08 13:08:52 +03:00
docker tests/docker: upgrade debian-all-test-cross to bookworm 2023-10-31 14:10:21 +00:00
fp tests: fp: remove unused submodules 2023-06-07 11:05:09 +02:00
guest-debug tests/tcg: clean-up gdb confirm/pagination settings 2023-08-30 14:57:50 +01:00
image-fuzzer
include
keys
lcitool tests/lcitool: add swtpm to the package list 2023-10-11 08:46:23 +01:00
migration tests/migration: Introduce dirty-limit into guestperf 2023-11-03 07:48:25 +01:00
multiboot
perf/block/qcow2
plugin plugins: make test/example plugins work on windows 2023-11-08 15:15:23 +00:00
qapi-schema tests/qapi-schema: Tidy up pylint warnings and advice 2023-11-13 10:36:51 +01:00
qemu-iotests Block layer patches 2023-11-01 06:58:11 +09:00
qtest tests/qtest/ufs-test.c: spelling fix: tranfer 2023-11-15 12:06:05 +03:00
rocker
tcg Revert "tests/tcg/nios2: Re-enable linux-user tests" 2023-11-08 15:15:23 +00:00
tsan tests/tsan: Rename the file with the entries that should be ignored 2023-11-13 11:35:47 +01:00
uefi-test-tools tests/: spelling fixes 2023-09-08 13:08:52 +03:00
unit block: Fix deadlocks in bdrv_graph_wrunlock() 2023-11-21 12:45:21 +01:00
vm tests/vm/netbsd: Use Python v3.11 2023-11-13 11:35:47 +01:00
vmstate-static-checker-data
dbus-vmstate-daemon.sh
Makefile.include Makefile: build plugins before running TCG tests 2023-10-02 18:04:39 +02:00
meson.build Makefile: build plugins before running TCG tests 2023-10-02 18:04:39 +02:00
test-qht-par.c
vhost-user-bridge.c