summaryrefslogtreecommitdiffstats
path: root/hw/scsi
diff options
context:
space:
mode:
authorPeter Maydell2022-10-13 18:06:23 +0200
committerPaolo Bonzini2022-10-18 13:58:04 +0200
commit8b5335e381e7fd7554a65c6d591875ade1cea062 (patch)
tree38edb6696fc928ad997ea114af61c680f8eee6f3 /hw/scsi
parentscsi: Use device_cold_reset() and bus_cold_reset() (diff)
downloadqemu-8b5335e381e7fd7554a65c6d591875ade1cea062.tar.gz
qemu-8b5335e381e7fd7554a65c6d591875ade1cea062.tar.xz
qemu-8b5335e381e7fd7554a65c6d591875ade1cea062.zip
hw/scsi/vmw_pvscsi.c: Use device_cold_reset() to reset SCSI devices
Currently the vwm_pvscsi controller resets individual SCSI devices with the device_legacy_reset() function. The only difference between this and device_cold_reset() is that device_legacy_reset() resets the device but not any child qbuses it might have. In this case, no SCSI device has a child qbus, so the functions have the same behaviour. Switch to device_cold_reset() to move away from using the deprecated function, and bring this SCSI controller in to line with what all the others do. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-Id: <20221013160623.1296109-3-peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/scsi')
-rw-r--r--hw/scsi/vmw_pvscsi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/scsi/vmw_pvscsi.c b/hw/scsi/vmw_pvscsi.c
index 3ea2c8c9f2..fa76696855 100644
--- a/hw/scsi/vmw_pvscsi.c
+++ b/hw/scsi/vmw_pvscsi.c
@@ -880,7 +880,7 @@ pvscsi_on_cmd_reset_device(PVSCSIState *s)
if (sdev != NULL) {
s->resetting++;
- device_legacy_reset(&sdev->qdev);
+ device_cold_reset(&sdev->qdev);
s->resetting--;
return PVSCSI_COMMAND_PROCESSING_SUCCEEDED;
}