mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
qapi: Add burst length fields to BlockDeviceInfo
This patch adds the new bps_*_max_length and iops_*_max_length parameters to the BlockDeviceInfo struct. Signed-off-by: Alberto Garcia <berto@igalia.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
dce13204a0
commit
398befdf50
2 changed files with 53 additions and 6 deletions
20
block/qapi.c
20
block/qapi.c
|
@ -92,6 +92,26 @@ BlockDeviceInfo *bdrv_block_device_info(BlockDriverState *bs, Error **errp)
|
|||
info->has_iops_wr_max = cfg.buckets[THROTTLE_OPS_WRITE].max;
|
||||
info->iops_wr_max = cfg.buckets[THROTTLE_OPS_WRITE].max;
|
||||
|
||||
info->has_bps_max_length = info->has_bps_max;
|
||||
info->bps_max_length =
|
||||
cfg.buckets[THROTTLE_BPS_TOTAL].burst_length;
|
||||
info->has_bps_rd_max_length = info->has_bps_rd_max;
|
||||
info->bps_rd_max_length =
|
||||
cfg.buckets[THROTTLE_BPS_READ].burst_length;
|
||||
info->has_bps_wr_max_length = info->has_bps_wr_max;
|
||||
info->bps_wr_max_length =
|
||||
cfg.buckets[THROTTLE_BPS_WRITE].burst_length;
|
||||
|
||||
info->has_iops_max_length = info->has_iops_max;
|
||||
info->iops_max_length =
|
||||
cfg.buckets[THROTTLE_OPS_TOTAL].burst_length;
|
||||
info->has_iops_rd_max_length = info->has_iops_rd_max;
|
||||
info->iops_rd_max_length =
|
||||
cfg.buckets[THROTTLE_OPS_READ].burst_length;
|
||||
info->has_iops_wr_max_length = info->has_iops_wr_max;
|
||||
info->iops_wr_max_length =
|
||||
cfg.buckets[THROTTLE_OPS_WRITE].burst_length;
|
||||
|
||||
info->has_iops_size = cfg.op_size;
|
||||
info->iops_size = cfg.op_size;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue