From e63e7fde24a3e88f1a4992d8f47b7a44ddcf14ff Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Tue, 10 Jul 2012 11:12:43 +0200 Subject: virtio-blk: qdev properties for disk geometry Geometry needs to be qdev properties, because it belongs to the disk's guest part. Maintain backward compatibility exactly like for serial: fall back to DriveInfo's geometry, set with -drive cyls=... Bonus: info qtree now shows the geometry. Signed-off-by: Markus Armbruster Signed-off-by: Kevin Wolf --- hw/virtio-pci.c | 1 + 1 file changed, 1 insertion(+) (limited to 'hw/virtio-pci.c') diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c index 9342eed070..557d1d3b13 100644 --- a/hw/virtio-pci.c +++ b/hw/virtio-pci.c @@ -936,6 +936,7 @@ static int virtio_balloon_exit_pci(PCIDevice *pci_dev) static Property virtio_blk_properties[] = { DEFINE_PROP_HEX32("class", VirtIOPCIProxy, class_code, 0), DEFINE_BLOCK_PROPERTIES(VirtIOPCIProxy, blk.conf), + DEFINE_BLOCK_CHS_PROPERTIES(VirtIOPCIProxy, blk.conf), DEFINE_PROP_STRING("serial", VirtIOPCIProxy, blk.serial), #ifdef __linux__ DEFINE_PROP_BIT("scsi", VirtIOPCIProxy, blk.scsi, 0, true), -- cgit 1.4.1