mbox series

[0/3] block/graph-lock: Disable locking for now

Message ID 20230517152834.277483-1-kwolf@redhat.com (mailing list archive)
Headers show
Series block/graph-lock: Disable locking for now | expand

Message

Kevin Wolf May 17, 2023, 3:28 p.m. UTC
tl;dr is that graph locking introduced deadlocks in 8.0, and disabling
it for now fixes them again. See patch 1 for the details.

I still intend the fix this properly before we remove the AioContext
lock (which is when the deadlock would be automatically solved), but
it's not trivial enough for something that would be ready now and
backportable to stable versions. Let's try the real thing again in 8.1
and fix 8.0 with this stopgap solution.

Patch 2 is a prerequisite for the test case. Instead of reproducing the
deadlock problem (which it unfortunately doesn't do reliably anyway, the
timing seems hard to get right), I got NBD server crashes without it. I
actually made some more NBD changes to fix the crashes before this one,
but it seems to be stable with only this. Maybe the rest only fixed
symptoms of the same root cause, I'll have another look at them.

Kevin Wolf (3):
  graph-lock: Disable locking for now
  nbd/server: Fix drained_poll to wake coroutine in right AioContext
  iotests: Test commit with iothreads and ongoing I/O

 include/io/channel.h                          | 10 ++++
 block/graph-lock.c                            | 21 +++++++
 io/channel.c                                  | 33 +++++++++--
 nbd/server.c                                  |  3 +-
 tests/qemu-iotests/iotests.py                 |  4 ++
 .../qemu-iotests/tests/graph-changes-while-io | 56 +++++++++++++++++--
 .../tests/graph-changes-while-io.out          |  4 +-
 7 files changed, 117 insertions(+), 14 deletions(-)