mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 10:13:56 -06:00
block: get rid of blk->guest_block_size
Commit1b7fd72955
("block: rename buffer_alignment to guest_block_size") noted: At this point, the field is set by the device emulation, but completely ignored by the block layer. The last time the value of buffer_alignment/guest_block_size was actually used was before commit339064d506
("block: Don't use guest sector size for qemu_blockalign()"). This value has not been used since 2013. Get rid of it. Cc: Xie Yongji <xieyongji@bytedance.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Message-Id: <20220518130945.2657905-1-stefanha@redhat.com> Reviewed-by: Paul Durrant <paul@xen.org> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Alberto Faria <afaria@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
3399848b7f
commit
1ab5096b3a
8 changed files with 0 additions and 17 deletions
|
@ -1228,7 +1228,6 @@ static void virtio_blk_device_realize(DeviceState *dev, Error **errp)
|
|||
|
||||
s->change = qemu_add_vm_change_state_handler(virtio_blk_dma_restart_cb, s);
|
||||
blk_set_dev_ops(s->blk, &virtio_block_ops, s);
|
||||
blk_set_guest_block_size(s->blk, s->conf.conf.logical_block_size);
|
||||
|
||||
blk_iostatus_enable(s->blk);
|
||||
|
||||
|
|
|
@ -243,7 +243,6 @@ static void xen_block_realize(XenDevice *xendev, Error **errp)
|
|||
}
|
||||
|
||||
blk_set_dev_ops(blk, &xen_block_dev_ops, blockdev);
|
||||
blk_set_guest_block_size(blk, conf->logical_block_size);
|
||||
|
||||
if (conf->discard_granularity == -1) {
|
||||
conf->discard_granularity = conf->physical_block_size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue