summaryrefslogtreecommitdiffstats
path: root/target-m68k
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2015-06-18 14:09:57 +0200
committerKevin Wolf <kwolf@redhat.com>2015-10-16 15:34:30 +0200
commitdd62f1ca433ea60b06590884642ad2c8f8e539f2 (patch)
treea1e53e2369d7b92f71e951d8c9bb23237642e39f /target-m68k
parentd42a8a935b8b2d567331fffa13a70918352668bb (diff)
downloadhqemu-dd62f1ca433ea60b06590884642ad2c8f8e539f2.zip
hqemu-dd62f1ca433ea60b06590884642ad2c8f8e539f2.tar.gz
block: Implement bdrv_append() without bdrv_swap()
Remember all parent nodes and just change the pointers there instead of swapping the contents of the BlockDriverState. Handling of snapshot=on must be moved further down in bdrv_open() because *pbs (which is the bs pointer in the BlockBackend) must already be set before bdrv_append() is called. Otherwise bdrv_append() changes the BB's pointer to the temporary snapshot, but bdrv_open() overwrites it with the read-only original image. We also need to be careful to update callers as the interface changes (becomes less insane): Previously, the meaning of the two parameters was inverted when bdrv_append() returns. Now any BDS pointers keep pointing to the same node. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Fam Zheng <famz@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'target-m68k')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud