diff options
author | Alberto Garcia <berto@igalia.com> | 2016-07-05 17:28:58 +0300 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2016-07-13 13:26:02 +0200 |
commit | 70559d499c84b9c7b1874821f970a15d52460d64 (patch) | |
tree | 4d9a9b555f22598fe650e1fd6280d4c36913f5ec /include/block | |
parent | 71aa98678c2b5616de5453d55e12f8ea810fbefb (diff) |
backup: Add 'job-id' parameter to 'blockdev-backup' and 'drive-backup'
This patch adds a new optional 'job-id' parameter to 'blockdev-backup'
and 'drive-backup', allowing the user to specify the ID of the block
job to be created.
The HMP 'drive_backup' command remains unchanged.
Signed-off-by: Alberto Garcia <berto@igalia.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'include/block')
-rw-r--r-- | include/block/block_int.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/include/block/block_int.h b/include/block/block_int.h index ad44fb959e..a0b9f926b5 100644 --- a/include/block/block_int.h +++ b/include/block/block_int.h @@ -732,6 +732,8 @@ void mirror_start(const char *job_id, BlockDriverState *bs, /* * backup_start: + * @job_id: The id of the newly-created job, or %NULL to use the + * device name of @bs. * @bs: Block device to operate on. * @target: Block device to write to. * @speed: The maximum speed, in bytes per second, or 0 for unlimited. @@ -746,9 +748,9 @@ void mirror_start(const char *job_id, BlockDriverState *bs, * Start a backup operation on @bs. Clusters in @bs are written to @target * until the job is cancelled or manually completed. */ -void backup_start(BlockDriverState *bs, BlockDriverState *target, - int64_t speed, MirrorSyncMode sync_mode, - BdrvDirtyBitmap *sync_bitmap, +void backup_start(const char *job_id, BlockDriverState *bs, + BlockDriverState *target, int64_t speed, + MirrorSyncMode sync_mode, BdrvDirtyBitmap *sync_bitmap, BlockdevOnError on_source_error, BlockdevOnError on_target_error, BlockCompletionFunc *cb, void *opaque, |