diff options
author | Kevin Wolf <kwolf@redhat.com> | 2016-06-20 18:24:02 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2016-07-05 16:46:27 +0200 |
commit | cf2ab8fc345c34f8671fade9230746610e4fc340 (patch) | |
tree | 12cde9139b26e6ddc0f0e041bc48a81489246e8e /block/bochs.c | |
parent | 18d51c4bac9d96302035de0faa11e3df98358f45 (diff) |
block: Convert bdrv_pread(v) to BdrvChild
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'block/bochs.c')
-rw-r--r-- | block/bochs.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/block/bochs.c b/block/bochs.c index 6427ad4fa2..46f635f2e7 100644 --- a/block/bochs.c +++ b/block/bochs.c @@ -106,7 +106,7 @@ static int bochs_open(BlockDriverState *bs, QDict *options, int flags, bs->read_only = true; /* no write support yet */ - ret = bdrv_pread(bs->file->bs, 0, &bochs, sizeof(bochs)); + ret = bdrv_pread(bs->file, 0, &bochs, sizeof(bochs)); if (ret < 0) { return ret; } @@ -140,7 +140,7 @@ static int bochs_open(BlockDriverState *bs, QDict *options, int flags, return -ENOMEM; } - ret = bdrv_pread(bs->file->bs, le32_to_cpu(bochs.header), s->catalog_bitmap, + ret = bdrv_pread(bs->file, le32_to_cpu(bochs.header), s->catalog_bitmap, s->catalog_size * 4); if (ret < 0) { goto fail; @@ -214,7 +214,7 @@ static int64_t seek_to_sector(BlockDriverState *bs, int64_t sector_num) (s->extent_blocks + s->bitmap_blocks)); /* read in bitmap for current extent */ - ret = bdrv_pread(bs->file->bs, bitmap_offset + (extent_offset / 8), + ret = bdrv_pread(bs->file, bitmap_offset + (extent_offset / 8), &bitmap_entry, 1); if (ret < 0) { return ret; |