[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL v2 36/50] raw: Assign bs to file in raw_co_get_block_
From: |
Max Reitz |
Subject: |
[Qemu-devel] [PULL v2 36/50] raw: Assign bs to file in raw_co_get_block_status |
Date: |
Tue, 2 Feb 2016 18:35:29 +0100 |
From: Fam Zheng <address@hidden>
Signed-off-by: Fam Zheng <address@hidden>
Message-id: address@hidden
Reviewed-by: Max Reitz <address@hidden>
Signed-off-by: Max Reitz <address@hidden>
---
block/raw-posix.c | 1 +
block/raw_bsd.c | 1 +
2 files changed, 2 insertions(+)
diff --git a/block/raw-posix.c b/block/raw-posix.c
index 3ef9b25..8866121 100644
--- a/block/raw-posix.c
+++ b/block/raw-posix.c
@@ -1861,6 +1861,7 @@ static int64_t coroutine_fn
raw_co_get_block_status(BlockDriverState *bs,
*pnum = MIN(nb_sectors, (data - start) / BDRV_SECTOR_SIZE);
ret = BDRV_BLOCK_ZERO;
}
+ *file = bs;
return ret | BDRV_BLOCK_OFFSET_VALID | start;
}
diff --git a/block/raw_bsd.c b/block/raw_bsd.c
index 9a8933b..ea16a23 100644
--- a/block/raw_bsd.c
+++ b/block/raw_bsd.c
@@ -119,6 +119,7 @@ static int64_t coroutine_fn
raw_co_get_block_status(BlockDriverState *bs,
BlockDriverState **file)
{
*pnum = nb_sectors;
+ *file = bs->file->bs;
return BDRV_BLOCK_RAW | BDRV_BLOCK_OFFSET_VALID | BDRV_BLOCK_DATA |
(sector_num << BDRV_SECTOR_BITS);
}
--
2.7.0
- [Qemu-devel] [PULL v2 25/50] block: Make bdrv_close() static, (continued)
- [Qemu-devel] [PULL v2 25/50] block: Make bdrv_close() static, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 29/50] block: Rewrite bdrv_close_all(), Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 28/50] block: Add blk_remove_all_bs(), Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 27/50] blockdev: Keep track of monitor-owned BDS, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 30/50] iotests: Add test for multiple BB on BDS tree, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 32/50] block: acquire in bdrv_query_image_info, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 31/50] iotests: Add test for block jobs and BDS ejection, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 34/50] qcow: Assign bs->file->bs to file in qcow_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 35/50] qcow2: Assign bs->file->bs to file in qcow2_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 33/50] block: Add "file" output parameter to block status query functions, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 36/50] raw: Assign bs to file in raw_co_get_block_status,
Max Reitz <=
- [Qemu-devel] [PULL v2 38/50] parallels: Assign bs->file->bs to file in parallels_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 37/50] iscsi: Assign bs to file in iscsi_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 40/50] sheepdog: Assign bs to file in sd_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 41/50] vdi: Assign bs->file->bs to file in vdi_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 39/50] qed: Assign bs->file->bs to file in bdrv_qed_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 42/50] vpc: Assign bs->file->bs to file in vpc_co_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 43/50] vmdk: Fix calculation of block status's offset, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 44/50] vmdk: Return extent's file in bdrv_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 46/50] qemu-img: In "map", use the returned "file" from bdrv_get_block_status, Max Reitz, 2016/02/02
- [Qemu-devel] [PULL v2 45/50] block: Use returned *file in bdrv_co_get_block_status, Max Reitz, 2016/02/02