Files
qemu/migration
Denis V. Lunev c59376b860 migration/block-dirty-bitmap: reject bitmap load onto ro node
dirty_bitmap_load_start() creates an incoming migrated bitmap with
bdrv_create_dirty_bitmap() and, if the source marked it persistent,
calls bdrv_dirty_bitmap_set_persistence() without checking whether
the destination node can be written to. Same gap as
qmp_block_dirty_bitmap_add(), reached via incoming migration: a
persistent bitmap for a read-only destination (e.g. a migrated
CD-ROM-class attachment with dirty-bitmaps migration enabled) ends
up writable in memory on a node that can never store it.

Reject it the same way, with one difference from the QMP path:
every destination node is BDRV_O_INACTIVE until migration completes,
so bdrv_is_writable() would reject every incoming persistent
bitmap, not just read-only ones. Check bdrv_is_read_only() alone.

Signed-off-by: Denis V. Lunev <den@openvz.org>
CC: Eric Blake <eblake@redhat.com>
CC: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
CC: John Snow <jsnow@redhat.com>
CC: Andrey Drobyshev <andrey.drobyshev@virtuozzo.com>
Message-ID: <20260716112242.3000035-3-den@openvz.org>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
(cherry picked from commit 3f3f5cdb92)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
2026-08-26 13:09:30 +03:00
..
2026-01-17 10:46:31 +11:00
2024-12-20 17:44:56 +01:00
2026-03-09 08:53:32 -03:00
2026-03-09 08:53:32 -03:00
2026-03-09 08:53:32 -03:00
2026-03-09 08:53:32 -03:00
2026-03-09 08:53:32 -03:00
2026-03-09 08:53:31 -03:00
2025-12-27 10:11:09 +01:00
2026-01-23 11:32:18 -03:00
2026-01-23 11:32:18 -03:00
2025-09-02 17:57:05 +02:00
2025-09-02 17:57:05 +02:00