migration/dirty-bitmaps: change bitmap enumeration method
commit592203e7cfbd1ad261178431fcf390adfe8b16df
authorJohn Snow <jsnow@redhat.com>
Tue, 28 May 2019 23:33:31 +0000 (28 19:33 -0400)
committerJohn Snow <jsnow@redhat.com>
Tue, 28 May 2019 23:33:31 +0000 (28 19:33 -0400)
tree399fea7cd78ce912794f211e565453f5ace09d7d
parent8c1ecb590497b0349c550607db923972b37f6963
migration/dirty-bitmaps: change bitmap enumeration method

Shift from looking at every root BDS to *every* BDS. This will migrate
bitmaps that are attached to blockdev created nodes instead of just ones
attached to emulated storage devices.

Note that this will not migrate anonymous or internal-use bitmaps, as
those are defined as having no name.

This will also fix the Coverity issues Peter Maydell has been asking
about for the past several releases, as well as fixing a real bug.

Reported-by: Peter Maydell <peter.maydell@linaro.org>
Reported-by: Coverity 😅
Reported-by: aihua liang <aliang@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Signed-off-by: John Snow <jsnow@redhat.com>
Message-id: 20190514201926.10407-1-jsnow@redhat.com
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1652490
Fixes: Coverity CID 1390625
CC: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: John Snow <jsnow@redhat.com>
migration/block-dirty-bitmap.c