[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 02/15] hw/isa/pc87312: Consolidate the use of device_class_set_par
From: |
Michael Tokarev |
Subject: |
[PULL 02/15] hw/isa/pc87312: Consolidate the use of device_class_set_parent_realize() |
Date: |
Tue, 13 Feb 2024 11:01:38 +0300 |
From: Zhao Liu <zhao1.liu@intel.com>
Use device_class_set_parent_realize() to set parent realize() directly.
Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
---
hw/isa/pc87312.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/isa/pc87312.c b/hw/isa/pc87312.c
index ee23f3e164..64dd17b537 100644
--- a/hw/isa/pc87312.c
+++ b/hw/isa/pc87312.c
@@ -338,10 +338,10 @@ static void pc87312_class_init(ObjectClass *klass, void
*data)
DeviceClass *dc = DEVICE_CLASS(klass);
ISASuperIOClass *sc = ISA_SUPERIO_CLASS(klass);
- sc->parent_realize = dc->realize;
- dc->realize = pc87312_realize;
dc->reset = pc87312_reset;
dc->vmsd = &vmstate_pc87312;
+ device_class_set_parent_realize(dc, pc87312_realize,
+ &sc->parent_realize);
device_class_set_props(dc, pc87312_properties);
sc->parallel = (ISASuperIOFuncs){
--
2.39.2
- [PULL 00/15] Trivial patches for 2024-02-13, Michael Tokarev, 2024/02/13
- [PULL 01/15] hw/isa/vt82c686: Consolidate the use of device_class_set_parent_realize(), Michael Tokarev, 2024/02/13
- [PULL 02/15] hw/isa/pc87312: Consolidate the use of device_class_set_parent_realize(),
Michael Tokarev <=
- [PULL 07/15] MAINTAINERS: Cover qapi/cxl.json, Michael Tokarev, 2024/02/13
- [PULL 09/15] qemu-nbd: mention --tls-hostname option in qemu-nbd --help, Michael Tokarev, 2024/02/13
- [PULL 04/15] hw/arm/smmuv3: Consolidate the use of device_class_set_parent_realize(), Michael Tokarev, 2024/02/13
- [PULL 05/15] hw/smbios: Fix OEM strings table option validation, Michael Tokarev, 2024/02/13
- [PULL 06/15] hw/smbios: Fix port connector option validation, Michael Tokarev, 2024/02/13
- [PULL 03/15] hw/intc/s390_flic: Consolidate the use of device_class_set_parent_realize(), Michael Tokarev, 2024/02/13
- [PULL 08/15] MAINTAINERS: Cover qapi/stats.json, Michael Tokarev, 2024/02/13
- [PULL 10/15] iothread: Simplify expression in qemu_in_iothread(), Michael Tokarev, 2024/02/13
- [PULL 12/15] qemu-options.hx: Add zoom-to-fit to option summary for gtk, Michael Tokarev, 2024/02/13
- [PULL 11/15] qemu-options.hx: document that tftp=dir is readonly, Michael Tokarev, 2024/02/13