[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 01/36] hw/s390x/s390-pci-inst.c: Use device_cold_reset() to reset
From: |
Peter Maydell |
Subject: |
[PULL 01/36] hw/s390x/s390-pci-inst.c: Use device_cold_reset() to reset PCI devices |
Date: |
Fri, 16 Dec 2022 21:42:09 +0000 |
The semantic difference between the deprecated device_legacy_reset()
function and the newer device_cold_reset() function is that the new
function resets both the device itself and any qbuses it owns,
whereas the legacy function resets just the device itself and nothing
else.
In s390-pci-inst.c we use device_legacy_reset() to reset an
S390PCIBusDevice. This device doesn't have any child qbuses, so the
functions do the same thing and we can stop using the deprecated one.
Reviewed-by: Matthew Rosato <mjrosato@linux.ibm.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/s390x/s390-pci-inst.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/s390x/s390-pci-inst.c b/hw/s390x/s390-pci-inst.c
index 66e764f9016..9abe95130c5 100644
--- a/hw/s390x/s390-pci-inst.c
+++ b/hw/s390x/s390-pci-inst.c
@@ -272,7 +272,7 @@ int clp_service_call(S390CPU *cpu, uint8_t r2, uintptr_t ra)
stw_p(&ressetpci->hdr.rsp, CLP_RC_SETPCIFN_FHOP);
goto out;
}
- device_legacy_reset(DEVICE(pbdev));
+ device_cold_reset(DEVICE(pbdev));
pbdev->fh &= ~FH_MASK_ENABLE;
pbdev->state = ZPCI_FS_DISABLED;
stl_p(&ressetpci->fh, pbdev->fh);
--
2.25.1
- [PULL 00/36] reset refactoring patches, Peter Maydell, 2022/12/16
- [PULL 01/36] hw/s390x/s390-pci-inst.c: Use device_cold_reset() to reset PCI devices,
Peter Maydell <=
- [PULL 02/36] pci: Use device_cold_reset() and bus_cold_reset(), Peter Maydell, 2022/12/16
- [PULL 03/36] hw/hyperv/vmbus: Use device_cold_reset() and bus_cold_reset(), Peter Maydell, 2022/12/16
- [PULL 13/36] target/avr: Convert to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 20/36] target/mips: Convert to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 19/36] target/microblaze: Convert to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 22/36] target/openrisc: Convert to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 09/36] hw/misc/mos6522: Convert TYPE_MOS6522 to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 07/36] hw/input/ps2: Convert TYPE_PS2_DEVICE to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 12/36] target/arm: Convert to 3-phase reset, Peter Maydell, 2022/12/16
- [PULL 04/36] Replace use of qdev_reset_all() with device_cold_reset(), Peter Maydell, 2022/12/16