On 21.11.19 14:57, Sergio Lopez wrote:
> Issuing a drive-backup from qmp_drive_backup takes a slightly
> different path than when it's issued from a transaction. In the code,
> this is manifested as some redundancy between do_drive_backup() and
> drive_backup_prepare().
> 
> This change unifies both paths, merging do_drive_backup() and
> drive_backup_prepare(), and changing qmp_drive_backup() to create a
> transaction instead of calling do_backup_common() direcly.
> 
> As a side-effect, now qmp_drive_backup() is executed inside a drained
> section, as it happens when creating a drive-backup transaction. This
> change is visible from the user's perspective, as the job gets paused
> and immediately resumed before starting the actual work.
> 
> Signed-off-by: Sergio Lopez <s...@redhat.com>
> ---
>  blockdev.c | 224 ++++++++++++++++++++++++-----------------------------
>  1 file changed, 100 insertions(+), 124 deletions(-)

Looks good to me, although it needs to keep the tests passing that now
break.

Max

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to