]>
Commit | Line | Data |
---|---|---|
1d0c6dfc DM |
1 | /* |
2 | * QEMU backup related definitions | |
3 | * | |
4 | * Copyright (C) 2013 Proxmox Server Solutions | |
5 | * | |
6 | * Authors: | |
7 | * Dietmar Maurer (dietmar@proxmox.com) | |
8 | * | |
9 | * This work is licensed under the terms of the GNU GPL, version 2 or later. | |
10 | * See the COPYING file in the top-level directory. | |
11 | * | |
12 | */ | |
13 | ||
14 | #ifndef QEMU_BACKUP_H | |
15 | #define QEMU_BACKUP_H | |
16 | ||
17 | #define BACKUP_CLUSTER_BITS 16 | |
18 | #define BACKUP_CLUSTER_SIZE (1<<BACKUP_CLUSTER_BITS) | |
19 | #define BACKUP_BLOCKS_PER_CLUSTER (BACKUP_CLUSTER_SIZE/BDRV_SECTOR_SIZE) | |
20 | ||
21 | typedef int BackupDumpFunc(void *opaque, BlockDriverState *bs, | |
22 | int64_t cluster_num, unsigned char *buf); | |
23 | ||
24 | void backup_job_start(BlockDriverState *bs, bool cancel); | |
25 | ||
26 | int backup_job_create(BlockDriverState *bs, BackupDumpFunc *backup_dump_cb, | |
27 | BlockDriverCompletionFunc *backup_complete_cb, | |
28 | void *opaque, int64_t speed); | |
29 | ||
30 | #endif /* QEMU_BACKUP_H */ |