aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorCédric Le Goater <clg@redhat.com>2024-03-12 13:04:31 +0100
committerMichael Tokarev <mjt@tls.msk.ru>2024-03-19 19:23:00 +0300
commite1e9d74f5703faa96472f24c5b1354522f8d6f7e (patch)
treeb9923b855994e6a933a66c5e6e536ca6473b8ee9 /tests
parent04b3d34d5c4204501a3cc10ad13bc24aaf9a5afb (diff)
migration: Skip only empty block devices
The block .save_setup() handler calls a helper routine init_blk_migration() which builds a list of block devices to take into account for migration. When one device is found to be empty (sectors == 0), the loop exits and all the remaining devices are ignored. This is a regression introduced when bdrv_iterate() was removed. Change that by skipping only empty devices. Cc: Markus Armbruster <armbru@redhat.com> Cc: qemu-stable <qemu-stable@nongnu.org> Suggested-by: Kevin Wolf <kwolf@redhat.com> Fixes: fea68bb6e9fa ("block: Eliminate bdrv_iterate(), use bdrv_next()") Signed-off-by: Cédric Le Goater <clg@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Kevin Wolf <kwolf@redhat.com> Link: https://lore.kernel.org/r/20240312120431.550054-1-clg@redhat.com [peterx: fix "Suggested-by:"] Signed-off-by: Peter Xu <peterx@redhat.com> (cherry picked from commit 2e128776dc56f502c2ee41750afe83938f389528) Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions