aboutsummaryrefslogtreecommitdiffstats
path: root/tools/blktap2/vhd
diff options
context:
space:
mode:
authorIan Campbell <ian.campbell@citrix.com>2011-03-17 19:13:53 +0000
committerIan Campbell <ian.campbell@citrix.com>2011-03-17 19:13:53 +0000
commit05dbcc741d966ea8596e1c07735c653f391d27ef (patch)
tree0605d7c13d61a8094e37770887b07b2a0c414949 /tools/blktap2/vhd
parentf9c1de946c4e283777fc7115f266ea668baa7438 (diff)
downloadxen-05dbcc741d966ea8596e1c07735c653f391d27ef.tar.gz
xen-05dbcc741d966ea8596e1c07735c653f391d27ef.tar.bz2
xen-05dbcc741d966ea8596e1c07735c653f391d27ef.zip
tools/blktap2: push uuid wrapper functions down into libvhd.
Nothing else uses them. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/blktap2/vhd')
-rw-r--r--tools/blktap2/vhd/lib/libvhd-journal.c2
-rw-r--r--tools/blktap2/vhd/lib/libvhd.c8
-rw-r--r--tools/blktap2/vhd/lib/vhd-util-check.c4
-rw-r--r--tools/blktap2/vhd/lib/vhd-util-read.c4
4 files changed, 9 insertions, 9 deletions
diff --git a/tools/blktap2/vhd/lib/libvhd-journal.c b/tools/blktap2/vhd/lib/libvhd-journal.c
index 24383ff62b..7edd182dc3 100644
--- a/tools/blktap2/vhd/lib/libvhd-journal.c
+++ b/tools/blktap2/vhd/lib/libvhd-journal.c
@@ -237,7 +237,7 @@ vhd_journal_add_journal_header(vhd_journal_t *j)
if (err)
return err;
- blk_uuid_copy(&j->header.uuid, &vhd->footer.uuid);
+ vhd_uuid_copy(&j->header.uuid, &vhd->footer.uuid);
memcpy(j->header.cookie,
VHD_JOURNAL_HEADER_COOKIE, sizeof(j->header.cookie));
j->header.vhd_footer_offset = off - sizeof(vhd_footer_t);
diff --git a/tools/blktap2/vhd/lib/libvhd.c b/tools/blktap2/vhd/lib/libvhd.c
index bc9649a639..3511cb4f80 100644
--- a/tools/blktap2/vhd/lib/libvhd.c
+++ b/tools/blktap2/vhd/lib/libvhd.c
@@ -2454,7 +2454,7 @@ vhd_initialize_footer(vhd_context_t *ctx, int type, uint64_t size)
ctx->footer.saved = 0;
ctx->footer.data_offset = 0xFFFFFFFFFFFFFFFF;
strcpy(ctx->footer.crtr_app, "tap");
- blk_uuid_generate(&ctx->footer.uuid);
+ vhd_uuid_generate(&ctx->footer.uuid);
}
static int
@@ -2569,7 +2569,7 @@ vhd_initialize_header(vhd_context_t *ctx, const char *parent_path,
return err;
ctx->header.prt_ts = vhd_time(stats.st_mtime);
- blk_uuid_copy(&ctx->header.prt_uuid, &parent.footer.uuid);
+ vhd_uuid_copy(&ctx->header.prt_uuid, &parent.footer.uuid);
if (!size)
size = parent.footer.curr_size;
vhd_close(&parent);
@@ -2651,7 +2651,7 @@ vhd_change_parent(vhd_context_t *child, char *parent_path, int raw)
}
if (raw) {
- blk_uuid_clear(&child->header.prt_uuid);
+ vhd_uuid_clear(&child->header.prt_uuid);
} else {
err = vhd_open(&parent, ppath, VHD_OPEN_RDONLY);
if (err) {
@@ -2659,7 +2659,7 @@ vhd_change_parent(vhd_context_t *child, char *parent_path, int raw)
ppath, child->file, err);
goto out;
}
- blk_uuid_copy(&child->header.prt_uuid, &parent.footer.uuid);
+ vhd_uuid_copy(&child->header.prt_uuid, &parent.footer.uuid);
vhd_close(&parent);
}
diff --git a/tools/blktap2/vhd/lib/vhd-util-check.c b/tools/blktap2/vhd/lib/vhd-util-check.c
index 59a1a47329..af07426d5b 100644
--- a/tools/blktap2/vhd/lib/vhd-util-check.c
+++ b/tools/blktap2/vhd/lib/vhd-util-check.c
@@ -218,7 +218,7 @@ vhd_util_check_validate_differencing_header(vhd_context_t *vhd)
if (vhd_util_check_zeros(header->loc, sizeof(header->loc)))
return "invalid non-null parent locators";
- if (!blk_uuid_is_nil(&header->prt_uuid))
+ if (!vhd_uuid_is_nil(&header->prt_uuid))
return "invalid non-null parent uuid";
if (header->prt_ts)
@@ -320,7 +320,7 @@ vhd_util_check_validate_parent(vhd_context_t *vhd, const char *ppath)
VHD_OPEN_RDONLY | VHD_OPEN_IGNORE_DISABLED))
return "error opening parent";
- if (blk_uuid_compare(&vhd->header.prt_uuid, &parent.footer.uuid)) {
+ if (vhd_uuid_compare(&vhd->header.prt_uuid, &parent.footer.uuid)) {
msg = "invalid parent uuid";
goto out;
}
diff --git a/tools/blktap2/vhd/lib/vhd-util-read.c b/tools/blktap2/vhd/lib/vhd-util-read.c
index 2e8dc8b786..ac4d833cbc 100644
--- a/tools/blktap2/vhd/lib/vhd-util-read.c
+++ b/tools/blktap2/vhd/lib/vhd-util-read.c
@@ -78,7 +78,7 @@ vhd_print_header(vhd_context_t *vhd, vhd_header_t *h, int hex)
(err ? "failed to read name" : name));
free(name);
- blk_uuid_to_string(&h->prt_uuid, uuid, sizeof(uuid));
+ vhd_uuid_to_string(&h->prt_uuid, uuid, sizeof(uuid));
printf("Parent UUID : %s\n", uuid);
vhd_time_to_string(h->prt_ts, time_str);
@@ -153,7 +153,7 @@ vhd_print_footer(vhd_footer_t *f, int hex)
printf("Checksum : 0x%x|0x%x (%s)\n", f->checksum, cksm,
f->checksum == cksm ? "Good!" : "Bad!");
- blk_uuid_to_string(&f->uuid, uuid, sizeof(uuid));
+ vhd_uuid_to_string(&f->uuid, uuid, sizeof(uuid));
printf("UUID : %s\n", uuid);
printf("Saved state : %s\n", f->saved == 0 ? "No" : "Yes");