virtio-scsi-test: Test attaching new overlay with iothreads
commitedbe36ad0f2fa8876b59bc77991ef00c969247a9
authorKevin Wolf <kwolf@redhat.com>
Wed, 8 May 2019 09:58:45 +0000 (8 11:58 +0200)
committerKevin Wolf <kwolf@redhat.com>
Tue, 4 Jun 2019 14:54:51 +0000 (4 16:54 +0200)
tree833d3820bf756f66b001be08c27b84f3453ce830
parentd0ee0204f400956ab429278f1b459d9af969c4a2
virtio-scsi-test: Test attaching new overlay with iothreads

This tests that blockdev-add can correctly add a qcow2 overlay to an
image used by a virtio-scsi disk in an iothread. The interesting point
here is whether the newly added node gets correctly moved into the
iothread AioContext.

If it isn't, we get an assertion failure in virtio-scsi while processing
the next request:

    virtio_scsi_ctx_check: Assertion `blk_get_aio_context(d->conf.blk) == s->ctx' failed.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
tests/libqtest.c
tests/libqtest.h
tests/virtio-scsi-test.c