All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH qemu 0/4] block/qemu-img convert: better handle failing flush
@ 2026-09-30 13:19 Fiona Ebner
  2026-09-30 13:19 ` [PATCH qemu 1/4] iotests: add test cases for failing flush after qemu-img convert Fiona Ebner
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Fiona Ebner @ 2026-09-30 13:19 UTC (permalink / raw)
  To: qemu-devel; +Cc: qemu-block, hreitz, kwolf, qemu-stable

Flush during bdrv_close() was introduced back in 2012 in commit
80ccf93b88 ("qemu-img: let 'qemu-img convert' flush data"). However, a
failing flush was quietly ignored. Report the error instead, since
this could mean that the image contents are not as expected. See patch
3/4 for details.

With 'qemu-img convert', when using a cache mode with 'cache.no-flush
= off', the expectation is that the data is flushed to the disk, which
happens since commit 80ccf93b88 ("qemu-img: let 'qemu-img convert'
flush data"). This expectation also encompasses that failure to do so
is properly reported, so ensure that 'qemu-img convert' exits with a
non-zero status code when the target image cannot be flushed. See
patch 4/4 for details.

qemu:

Fiona Ebner (4):
  iotests: add test cases for failing flush after qemu-img convert
  iotests.py: add filter_qemu()
  block: report flush error during bdrv_close()
  qemu-img: convert: flush target image after copying

 block.c                                    | 13 +++-
 qemu-img.c                                 |  8 ++-
 tests/qemu-iotests/026                     | 10 +--
 tests/qemu-iotests/026.out                 | 84 ++++++++++++++++++++++
 tests/qemu-iotests/071                     |  2 +-
 tests/qemu-iotests/071.out                 |  2 +
 tests/qemu-iotests/080.out                 |  2 +
 tests/qemu-iotests/098.out                 |  4 ++
 tests/qemu-iotests/122                     | 33 +++++++++
 tests/qemu-iotests/122.out                 | 17 +++++
 tests/qemu-iotests/244                     |  2 +-
 tests/qemu-iotests/244.out                 |  1 +
 tests/qemu-iotests/iotests.py              |  4 ++
 tests/qemu-iotests/tests/file-io-error     |  2 +-
 tests/qemu-iotests/tests/file-io-error.out |  2 +
 tests/qemu-iotests/tests/qsd-migrate       |  5 +-
 tests/qemu-iotests/tests/qsd-migrate.out   |  1 +
 17 files changed, 180 insertions(+), 12 deletions(-)


Summary over all repositories:
  17 files changed, 180 insertions(+), 12 deletions(-)

-- 
Generated by git-murpp 0.5.0



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2026-10-07  9:27 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-30 13:19 [PATCH qemu 0/4] block/qemu-img convert: better handle failing flush Fiona Ebner
2026-09-30 13:19 ` [PATCH qemu 1/4] iotests: add test cases for failing flush after qemu-img convert Fiona Ebner
2026-10-06 14:07   ` Eric Blake
2026-09-30 13:19 ` [PATCH qemu 2/4] iotests.py: add filter_qemu() Fiona Ebner
2026-10-06 14:08   ` Eric Blake
2026-09-30 13:19 ` [PATCH qemu 3/4] block: report flush error during bdrv_close() Fiona Ebner
2026-10-06 14:18   ` Eric Blake
2026-09-30 13:19 ` [PATCH qemu 4/4] qemu-img: convert: flush target image after copying Fiona Ebner
2026-10-06 14:29   ` Eric Blake

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.