|
|
9ae3a8 |
From 746c0b5934008a7e6a31c5de8ee5e799f88da9d9 Mon Sep 17 00:00:00 2001
|
|
|
9ae3a8 |
From: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
Date: Tue, 25 Mar 2014 14:23:40 +0100
|
|
|
9ae3a8 |
Subject: [PATCH 33/49] dmg: coding style and indentation cleanup
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
RH-Author: Kevin Wolf <kwolf@redhat.com>
|
|
|
9ae3a8 |
Message-id: <1395753835-7591-34-git-send-email-kwolf@redhat.com>
|
|
|
9ae3a8 |
Patchwork-id: n/a
|
|
|
9ae3a8 |
O-Subject: [virt-devel] [EMBARGOED RHEL-7.0 qemu-kvm PATCH 33/48] dmg: coding style and indentation cleanup
|
|
|
9ae3a8 |
Bugzilla: 1066691
|
|
|
9ae3a8 |
RH-Acked-by: Jeff Cody <jcody@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
From: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1066691
|
|
|
9ae3a8 |
Upstream status: Series embargoed
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Clean up the mix of tabs and spaces, as well as the coding style
|
|
|
9ae3a8 |
violations in block/dmg.c. There are no semantic changes since this
|
|
|
9ae3a8 |
patch simply reformats the code.
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
This patch is necessary before we can make meaningful changes to this
|
|
|
9ae3a8 |
file, due to the inconsistent formatting and confusing indentation.
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
|
9ae3a8 |
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
block/dmg.c | 224 +++++++++++++++++++++++++++++++---------------------------
|
|
|
9ae3a8 |
1 files changed, 120 insertions(+), 104 deletions(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/block/dmg.c b/block/dmg.c
|
|
|
9ae3a8 |
index d5e9b1f..be2f26e 100644
|
|
|
9ae3a8 |
--- a/block/dmg.c
|
|
|
9ae3a8 |
+++ b/block/dmg.c
|
|
|
9ae3a8 |
@@ -96,9 +96,9 @@ static int dmg_open(BlockDriverState *bs, QDict *options, int flags,
|
|
|
9ae3a8 |
Error **errp)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
BDRVDMGState *s = bs->opaque;
|
|
|
9ae3a8 |
- uint64_t info_begin,info_end,last_in_offset,last_out_offset;
|
|
|
9ae3a8 |
+ uint64_t info_begin, info_end, last_in_offset, last_out_offset;
|
|
|
9ae3a8 |
uint32_t count, tmp;
|
|
|
9ae3a8 |
- uint32_t max_compressed_size=1,max_sectors_per_chunk=1,i;
|
|
|
9ae3a8 |
+ uint32_t max_compressed_size = 1, max_sectors_per_chunk = 1, i;
|
|
|
9ae3a8 |
int64_t offset;
|
|
|
9ae3a8 |
int ret;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
@@ -160,37 +160,39 @@ static int dmg_open(BlockDriverState *bs, QDict *options, int flags,
|
|
|
9ae3a8 |
goto fail;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if (type == 0x6d697368 && count >= 244) {
|
|
|
9ae3a8 |
- int new_size, chunk_count;
|
|
|
9ae3a8 |
+ if (type == 0x6d697368 && count >= 244) {
|
|
|
9ae3a8 |
+ int new_size, chunk_count;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
offset += 4;
|
|
|
9ae3a8 |
offset += 200;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- chunk_count = (count-204)/40;
|
|
|
9ae3a8 |
- new_size = sizeof(uint64_t) * (s->n_chunks + chunk_count);
|
|
|
9ae3a8 |
- s->types = g_realloc(s->types, new_size/2);
|
|
|
9ae3a8 |
- s->offsets = g_realloc(s->offsets, new_size);
|
|
|
9ae3a8 |
- s->lengths = g_realloc(s->lengths, new_size);
|
|
|
9ae3a8 |
- s->sectors = g_realloc(s->sectors, new_size);
|
|
|
9ae3a8 |
- s->sectorcounts = g_realloc(s->sectorcounts, new_size);
|
|
|
9ae3a8 |
+ chunk_count = (count - 204) / 40;
|
|
|
9ae3a8 |
+ new_size = sizeof(uint64_t) * (s->n_chunks + chunk_count);
|
|
|
9ae3a8 |
+ s->types = g_realloc(s->types, new_size / 2);
|
|
|
9ae3a8 |
+ s->offsets = g_realloc(s->offsets, new_size);
|
|
|
9ae3a8 |
+ s->lengths = g_realloc(s->lengths, new_size);
|
|
|
9ae3a8 |
+ s->sectors = g_realloc(s->sectors, new_size);
|
|
|
9ae3a8 |
+ s->sectorcounts = g_realloc(s->sectorcounts, new_size);
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
for (i = s->n_chunks; i < s->n_chunks + chunk_count; i++) {
|
|
|
9ae3a8 |
ret = read_uint32(bs, offset, &s->types[i]);
|
|
|
9ae3a8 |
if (ret < 0) {
|
|
|
9ae3a8 |
goto fail;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
- offset += 4;
|
|
|
9ae3a8 |
- if(s->types[i]!=0x80000005 && s->types[i]!=1 && s->types[i]!=2) {
|
|
|
9ae3a8 |
- if(s->types[i]==0xffffffff) {
|
|
|
9ae3a8 |
- last_in_offset = s->offsets[i-1]+s->lengths[i-1];
|
|
|
9ae3a8 |
- last_out_offset = s->sectors[i-1]+s->sectorcounts[i-1];
|
|
|
9ae3a8 |
- }
|
|
|
9ae3a8 |
- chunk_count--;
|
|
|
9ae3a8 |
- i--;
|
|
|
9ae3a8 |
- offset += 36;
|
|
|
9ae3a8 |
- continue;
|
|
|
9ae3a8 |
- }
|
|
|
9ae3a8 |
- offset += 4;
|
|
|
9ae3a8 |
+ offset += 4;
|
|
|
9ae3a8 |
+ if (s->types[i] != 0x80000005 && s->types[i] != 1 &&
|
|
|
9ae3a8 |
+ s->types[i] != 2) {
|
|
|
9ae3a8 |
+ if (s->types[i] == 0xffffffff) {
|
|
|
9ae3a8 |
+ last_in_offset = s->offsets[i - 1] + s->lengths[i - 1];
|
|
|
9ae3a8 |
+ last_out_offset = s->sectors[i - 1] +
|
|
|
9ae3a8 |
+ s->sectorcounts[i - 1];
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ chunk_count--;
|
|
|
9ae3a8 |
+ i--;
|
|
|
9ae3a8 |
+ offset += 36;
|
|
|
9ae3a8 |
+ continue;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ offset += 4;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
ret = read_uint64(bs, offset, &s->sectors[i]);
|
|
|
9ae3a8 |
if (ret < 0) {
|
|
|
9ae3a8 |
@@ -218,19 +220,21 @@ static int dmg_open(BlockDriverState *bs, QDict *options, int flags,
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
offset += 8;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if(s->lengths[i]>max_compressed_size)
|
|
|
9ae3a8 |
- max_compressed_size = s->lengths[i];
|
|
|
9ae3a8 |
- if(s->sectorcounts[i]>max_sectors_per_chunk)
|
|
|
9ae3a8 |
- max_sectors_per_chunk = s->sectorcounts[i];
|
|
|
9ae3a8 |
- }
|
|
|
9ae3a8 |
- s->n_chunks+=chunk_count;
|
|
|
9ae3a8 |
- }
|
|
|
9ae3a8 |
+ if (s->lengths[i] > max_compressed_size) {
|
|
|
9ae3a8 |
+ max_compressed_size = s->lengths[i];
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ if (s->sectorcounts[i] > max_sectors_per_chunk) {
|
|
|
9ae3a8 |
+ max_sectors_per_chunk = s->sectorcounts[i];
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ s->n_chunks += chunk_count;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
/* initialize zlib engine */
|
|
|
9ae3a8 |
- s->compressed_chunk = g_malloc(max_compressed_size+1);
|
|
|
9ae3a8 |
- s->uncompressed_chunk = g_malloc(512*max_sectors_per_chunk);
|
|
|
9ae3a8 |
- if(inflateInit(&s->zstream) != Z_OK) {
|
|
|
9ae3a8 |
+ s->compressed_chunk = g_malloc(max_compressed_size + 1);
|
|
|
9ae3a8 |
+ s->uncompressed_chunk = g_malloc(512 * max_sectors_per_chunk);
|
|
|
9ae3a8 |
+ if (inflateInit(&s->zstream) != Z_OK) {
|
|
|
9ae3a8 |
ret = -EINVAL;
|
|
|
9ae3a8 |
goto fail;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
@@ -252,27 +256,29 @@ fail:
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
static inline int is_sector_in_chunk(BDRVDMGState* s,
|
|
|
9ae3a8 |
- uint32_t chunk_num,int sector_num)
|
|
|
9ae3a8 |
+ uint32_t chunk_num, int sector_num)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
- if(chunk_num>=s->n_chunks || s->sectors[chunk_num]>sector_num ||
|
|
|
9ae3a8 |
- s->sectors[chunk_num]+s->sectorcounts[chunk_num]<=sector_num)
|
|
|
9ae3a8 |
- return 0;
|
|
|
9ae3a8 |
- else
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
+ if (chunk_num >= s->n_chunks || s->sectors[chunk_num] > sector_num ||
|
|
|
9ae3a8 |
+ s->sectors[chunk_num] + s->sectorcounts[chunk_num] <= sector_num) {
|
|
|
9ae3a8 |
+ return 0;
|
|
|
9ae3a8 |
+ } else {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
-static inline uint32_t search_chunk(BDRVDMGState* s,int sector_num)
|
|
|
9ae3a8 |
+static inline uint32_t search_chunk(BDRVDMGState *s, int sector_num)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
/* binary search */
|
|
|
9ae3a8 |
- uint32_t chunk1=0,chunk2=s->n_chunks,chunk3;
|
|
|
9ae3a8 |
- while(chunk1!=chunk2) {
|
|
|
9ae3a8 |
- chunk3 = (chunk1+chunk2)/2;
|
|
|
9ae3a8 |
- if(s->sectors[chunk3]>sector_num)
|
|
|
9ae3a8 |
- chunk2 = chunk3;
|
|
|
9ae3a8 |
- else if(s->sectors[chunk3]+s->sectorcounts[chunk3]>sector_num)
|
|
|
9ae3a8 |
- return chunk3;
|
|
|
9ae3a8 |
- else
|
|
|
9ae3a8 |
- chunk1 = chunk3;
|
|
|
9ae3a8 |
+ uint32_t chunk1 = 0, chunk2 = s->n_chunks, chunk3;
|
|
|
9ae3a8 |
+ while (chunk1 != chunk2) {
|
|
|
9ae3a8 |
+ chunk3 = (chunk1 + chunk2) / 2;
|
|
|
9ae3a8 |
+ if (s->sectors[chunk3] > sector_num) {
|
|
|
9ae3a8 |
+ chunk2 = chunk3;
|
|
|
9ae3a8 |
+ } else if (s->sectors[chunk3] + s->sectorcounts[chunk3] > sector_num) {
|
|
|
9ae3a8 |
+ return chunk3;
|
|
|
9ae3a8 |
+ } else {
|
|
|
9ae3a8 |
+ chunk1 = chunk3;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
return s->n_chunks; /* error */
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
@@ -281,54 +287,62 @@ static inline int dmg_read_chunk(BlockDriverState *bs, int sector_num)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
BDRVDMGState *s = bs->opaque;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if(!is_sector_in_chunk(s,s->current_chunk,sector_num)) {
|
|
|
9ae3a8 |
- int ret;
|
|
|
9ae3a8 |
- uint32_t chunk = search_chunk(s,sector_num);
|
|
|
9ae3a8 |
+ if (!is_sector_in_chunk(s, s->current_chunk, sector_num)) {
|
|
|
9ae3a8 |
+ int ret;
|
|
|
9ae3a8 |
+ uint32_t chunk = search_chunk(s, sector_num);
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- if(chunk>=s->n_chunks)
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
+ if (chunk >= s->n_chunks) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- s->current_chunk = s->n_chunks;
|
|
|
9ae3a8 |
- switch(s->types[chunk]) {
|
|
|
9ae3a8 |
- case 0x80000005: { /* zlib compressed */
|
|
|
9ae3a8 |
- int i;
|
|
|
9ae3a8 |
+ s->current_chunk = s->n_chunks;
|
|
|
9ae3a8 |
+ switch (s->types[chunk]) {
|
|
|
9ae3a8 |
+ case 0x80000005: { /* zlib compressed */
|
|
|
9ae3a8 |
+ int i;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- /* we need to buffer, because only the chunk as whole can be
|
|
|
9ae3a8 |
- * inflated. */
|
|
|
9ae3a8 |
- i=0;
|
|
|
9ae3a8 |
- do {
|
|
|
9ae3a8 |
+ /* we need to buffer, because only the chunk as whole can be
|
|
|
9ae3a8 |
+ * inflated. */
|
|
|
9ae3a8 |
+ i = 0;
|
|
|
9ae3a8 |
+ do {
|
|
|
9ae3a8 |
ret = bdrv_pread(bs->file, s->offsets[chunk] + i,
|
|
|
9ae3a8 |
- s->compressed_chunk+i, s->lengths[chunk]-i);
|
|
|
9ae3a8 |
- if(ret<0 && errno==EINTR)
|
|
|
9ae3a8 |
- ret=0;
|
|
|
9ae3a8 |
- i+=ret;
|
|
|
9ae3a8 |
- } while(ret>=0 && ret+i<s->lengths[chunk]);
|
|
|
9ae3a8 |
-
|
|
|
9ae3a8 |
- if (ret != s->lengths[chunk])
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
-
|
|
|
9ae3a8 |
- s->zstream.next_in = s->compressed_chunk;
|
|
|
9ae3a8 |
- s->zstream.avail_in = s->lengths[chunk];
|
|
|
9ae3a8 |
- s->zstream.next_out = s->uncompressed_chunk;
|
|
|
9ae3a8 |
- s->zstream.avail_out = 512*s->sectorcounts[chunk];
|
|
|
9ae3a8 |
- ret = inflateReset(&s->zstream);
|
|
|
9ae3a8 |
- if(ret != Z_OK)
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
- ret = inflate(&s->zstream, Z_FINISH);
|
|
|
9ae3a8 |
- if(ret != Z_STREAM_END || s->zstream.total_out != 512*s->sectorcounts[chunk])
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
- break; }
|
|
|
9ae3a8 |
- case 1: /* copy */
|
|
|
9ae3a8 |
- ret = bdrv_pread(bs->file, s->offsets[chunk],
|
|
|
9ae3a8 |
+ s->compressed_chunk + i,
|
|
|
9ae3a8 |
+ s->lengths[chunk] - i);
|
|
|
9ae3a8 |
+ if (ret < 0 && errno == EINTR) {
|
|
|
9ae3a8 |
+ ret = 0;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ i += ret;
|
|
|
9ae3a8 |
+ } while (ret >= 0 && ret + i < s->lengths[chunk]);
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
+ if (ret != s->lengths[chunk]) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
+ s->zstream.next_in = s->compressed_chunk;
|
|
|
9ae3a8 |
+ s->zstream.avail_in = s->lengths[chunk];
|
|
|
9ae3a8 |
+ s->zstream.next_out = s->uncompressed_chunk;
|
|
|
9ae3a8 |
+ s->zstream.avail_out = 512 * s->sectorcounts[chunk];
|
|
|
9ae3a8 |
+ ret = inflateReset(&s->zstream);
|
|
|
9ae3a8 |
+ if (ret != Z_OK) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ ret = inflate(&s->zstream, Z_FINISH);
|
|
|
9ae3a8 |
+ if (ret != Z_STREAM_END ||
|
|
|
9ae3a8 |
+ s->zstream.total_out != 512 * s->sectorcounts[chunk]) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ break; }
|
|
|
9ae3a8 |
+ case 1: /* copy */
|
|
|
9ae3a8 |
+ ret = bdrv_pread(bs->file, s->offsets[chunk],
|
|
|
9ae3a8 |
s->uncompressed_chunk, s->lengths[chunk]);
|
|
|
9ae3a8 |
- if (ret != s->lengths[chunk])
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
- break;
|
|
|
9ae3a8 |
- case 2: /* zero */
|
|
|
9ae3a8 |
- memset(s->uncompressed_chunk, 0, 512*s->sectorcounts[chunk]);
|
|
|
9ae3a8 |
- break;
|
|
|
9ae3a8 |
- }
|
|
|
9ae3a8 |
- s->current_chunk = chunk;
|
|
|
9ae3a8 |
+ if (ret != s->lengths[chunk]) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ break;
|
|
|
9ae3a8 |
+ case 2: /* zero */
|
|
|
9ae3a8 |
+ memset(s->uncompressed_chunk, 0, 512 * s->sectorcounts[chunk]);
|
|
|
9ae3a8 |
+ break;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ s->current_chunk = chunk;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
return 0;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
@@ -339,12 +353,14 @@ static int dmg_read(BlockDriverState *bs, int64_t sector_num,
|
|
|
9ae3a8 |
BDRVDMGState *s = bs->opaque;
|
|
|
9ae3a8 |
int i;
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
- for(i=0;i
|
|
|
9ae3a8 |
- uint32_t sector_offset_in_chunk;
|
|
|
9ae3a8 |
- if(dmg_read_chunk(bs, sector_num+i) != 0)
|
|
|
9ae3a8 |
- return -1;
|
|
|
9ae3a8 |
- sector_offset_in_chunk = sector_num+i-s->sectors[s->current_chunk];
|
|
|
9ae3a8 |
- memcpy(buf+i*512,s->uncompressed_chunk+sector_offset_in_chunk*512,512);
|
|
|
9ae3a8 |
+ for (i = 0; i < nb_sectors; i++) {
|
|
|
9ae3a8 |
+ uint32_t sector_offset_in_chunk;
|
|
|
9ae3a8 |
+ if (dmg_read_chunk(bs, sector_num + i) != 0) {
|
|
|
9ae3a8 |
+ return -1;
|
|
|
9ae3a8 |
+ }
|
|
|
9ae3a8 |
+ sector_offset_in_chunk = sector_num + i - s->sectors[s->current_chunk];
|
|
|
9ae3a8 |
+ memcpy(buf + i * 512,
|
|
|
9ae3a8 |
+ s->uncompressed_chunk + sector_offset_in_chunk * 512, 512);
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
return 0;
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
@@ -376,12 +392,12 @@ static void dmg_close(BlockDriverState *bs)
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
static BlockDriver bdrv_dmg = {
|
|
|
9ae3a8 |
- .format_name = "dmg",
|
|
|
9ae3a8 |
- .instance_size = sizeof(BDRVDMGState),
|
|
|
9ae3a8 |
- .bdrv_probe = dmg_probe,
|
|
|
9ae3a8 |
- .bdrv_open = dmg_open,
|
|
|
9ae3a8 |
- .bdrv_read = dmg_co_read,
|
|
|
9ae3a8 |
- .bdrv_close = dmg_close,
|
|
|
9ae3a8 |
+ .format_name = "dmg",
|
|
|
9ae3a8 |
+ .instance_size = sizeof(BDRVDMGState),
|
|
|
9ae3a8 |
+ .bdrv_probe = dmg_probe,
|
|
|
9ae3a8 |
+ .bdrv_open = dmg_open,
|
|
|
9ae3a8 |
+ .bdrv_read = dmg_co_read,
|
|
|
9ae3a8 |
+ .bdrv_close = dmg_close,
|
|
|
9ae3a8 |
};
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
static void bdrv_dmg_init(void)
|
|
|
9ae3a8 |
--
|
|
|
9ae3a8 |
1.7.1
|
|
|
9ae3a8 |
|