Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
hw/isa/piix3: Resolve redundant k->config_write assignments
The previous patch unified handling of piix3_write_config() accross the
PIIX3 device models which allows for assigning k->config_write once in the
base class.

Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>
Tested-by: Chuck Zmudzinski <brchuckz@aol.com>
Message-Id: <20230312120221.99183-6-shentey@gmail.com>
Message-Id: <20230403074124.3925-7-shentey@gmail.com>
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
  • Loading branch information
shentok authored and anthonyper-ctx committed Jun 7, 2023
1 parent 89965db commit 0f3e02a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions hw/isa/piix3.c
Expand Up @@ -322,6 +322,7 @@ static void pci_piix3_class_init(ObjectClass *klass, void *data)
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);
AcpiDevAmlIfClass *adevc = ACPI_DEV_AML_IF_CLASS(klass);

k->config_write = piix3_write_config;
dc->reset = piix3_reset;
dc->desc = "ISA bridge";
dc->vmsd = &vmstate_piix3;
Expand Down Expand Up @@ -371,7 +372,6 @@ static void piix3_class_init(ObjectClass *klass, void *data)
{
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);

k->config_write = piix3_write_config;
k->realize = piix3_realize;
}

Expand All @@ -385,7 +385,6 @@ static void piix3_xen_class_init(ObjectClass *klass, void *data)
{
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);

k->config_write = piix3_write_config;
k->realize = piix3_realize;
}

Expand Down

0 comments on commit 0f3e02a

Please sign in to comment.