diff options
author | Sam Eiderman | 2019-10-16 18:41:42 +0200 |
---|---|---|
committer | John Snow | 2019-10-31 16:47:29 +0100 |
commit | 71f571a23d732711908a5af8c24c56b218a44256 (patch) | |
tree | 3a89efc41e551f16f98fec0f13a640f4b240397a /hw/ide | |
parent | scsi: Propagate unrealize() callback to scsi-hd (diff) | |
download | qemu-71f571a23d732711908a5af8c24c56b218a44256.tar.gz qemu-71f571a23d732711908a5af8c24c56b218a44256.tar.xz qemu-71f571a23d732711908a5af8c24c56b218a44256.zip |
bootdevice: Gather LCHS from all relevant devices
Relevant devices are:
* ide-hd (and ide-cd, ide-drive)
* scsi-hd (and scsi-cd, scsi-disk, scsi-block)
* virtio-blk-pci
We do not call del_boot_device_lchs() for ide-* since we don't need to -
IDE block devices do not support unplugging.
Reviewed-by: Karl Heubaum <karl.heubaum@oracle.com>
Reviewed-by: Arbel Moshe <arbel.moshe@oracle.com>
Signed-off-by: Sam Eiderman <shmuel.eiderman@oracle.com>
Signed-off-by: Sam Eiderman <sameid@google.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: John Snow <jsnow@redhat.com>
Diffstat (limited to 'hw/ide')
-rw-r--r-- | hw/ide/qdev.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/hw/ide/qdev.c b/hw/ide/qdev.c index 85cca6ec38..374a791a45 100644 --- a/hw/ide/qdev.c +++ b/hw/ide/qdev.c @@ -220,6 +220,11 @@ static void ide_dev_initfn(IDEDevice *dev, IDEDriveKind kind, Error **errp) add_boot_device_path(dev->conf.bootindex, &dev->qdev, dev->unit ? "/disk@1" : "/disk@0"); + + add_boot_device_lchs(&dev->qdev, dev->unit ? "/disk@1" : "/disk@0", + dev->conf.lcyls, + dev->conf.lheads, + dev->conf.lsecs); } static void ide_dev_get_bootindex(Object *obj, Visitor *v, const char *name, |