mirror of https://github.com/xemu-project/xemu.git
vt82c686: Rename VT82C686B to VT82C686B_ISA
This is really the ISA bridge part so name the type accordingly. Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <78db2ced4b41a8a775dbc6c97a90db683952c2cb.1609584216.git.balaton@eik.bme.hu> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
This commit is contained in:
parent
e634050544
commit
0f79846147
|
@ -43,14 +43,14 @@ typedef struct SuperIOConfig {
|
||||||
uint8_t data;
|
uint8_t data;
|
||||||
} SuperIOConfig;
|
} SuperIOConfig;
|
||||||
|
|
||||||
struct VT82C686BState {
|
struct VT82C686BISAState {
|
||||||
PCIDevice dev;
|
PCIDevice dev;
|
||||||
MemoryRegion superio;
|
MemoryRegion superio;
|
||||||
SuperIOConfig superio_conf;
|
SuperIOConfig superio_conf;
|
||||||
};
|
};
|
||||||
|
|
||||||
#define TYPE_VT82C686B "VT82C686B"
|
#define TYPE_VT82C686B_ISA "vt82c686b-isa"
|
||||||
OBJECT_DECLARE_SIMPLE_TYPE(VT82C686BState, VT82C686B)
|
OBJECT_DECLARE_SIMPLE_TYPE(VT82C686BISAState, VT82C686B_ISA)
|
||||||
|
|
||||||
static void superio_ioport_writeb(void *opaque, hwaddr addr, uint64_t data,
|
static void superio_ioport_writeb(void *opaque, hwaddr addr, uint64_t data,
|
||||||
unsigned size)
|
unsigned size)
|
||||||
|
@ -117,7 +117,7 @@ static const MemoryRegionOps superio_ops = {
|
||||||
|
|
||||||
static void vt82c686b_isa_reset(DeviceState *dev)
|
static void vt82c686b_isa_reset(DeviceState *dev)
|
||||||
{
|
{
|
||||||
VT82C686BState *vt82c = VT82C686B(dev);
|
VT82C686BISAState *vt82c = VT82C686B_ISA(dev);
|
||||||
uint8_t *pci_conf = vt82c->dev.config;
|
uint8_t *pci_conf = vt82c->dev.config;
|
||||||
|
|
||||||
pci_set_long(pci_conf + PCI_CAPABILITY_LIST, 0x000000c0);
|
pci_set_long(pci_conf + PCI_CAPABILITY_LIST, 0x000000c0);
|
||||||
|
@ -146,7 +146,7 @@ static void vt82c686b_isa_reset(DeviceState *dev)
|
||||||
static void vt82c686b_write_config(PCIDevice *d, uint32_t address,
|
static void vt82c686b_write_config(PCIDevice *d, uint32_t address,
|
||||||
uint32_t val, int len)
|
uint32_t val, int len)
|
||||||
{
|
{
|
||||||
VT82C686BState *vt686 = VT82C686B(d);
|
VT82C686BISAState *vt686 = VT82C686B_ISA(d);
|
||||||
|
|
||||||
DPRINTF("vt82c686b_write_config address 0x%x val 0x%x len 0x%x\n",
|
DPRINTF("vt82c686b_write_config address 0x%x val 0x%x len 0x%x\n",
|
||||||
address, val, len);
|
address, val, len);
|
||||||
|
@ -434,7 +434,7 @@ static const VMStateDescription vmstate_via = {
|
||||||
.version_id = 1,
|
.version_id = 1,
|
||||||
.minimum_version_id = 1,
|
.minimum_version_id = 1,
|
||||||
.fields = (VMStateField[]) {
|
.fields = (VMStateField[]) {
|
||||||
VMSTATE_PCI_DEVICE(dev, VT82C686BState),
|
VMSTATE_PCI_DEVICE(dev, VT82C686BISAState),
|
||||||
VMSTATE_END_OF_LIST()
|
VMSTATE_END_OF_LIST()
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -442,7 +442,7 @@ static const VMStateDescription vmstate_via = {
|
||||||
/* init the PCI-to-ISA bridge */
|
/* init the PCI-to-ISA bridge */
|
||||||
static void vt82c686b_realize(PCIDevice *d, Error **errp)
|
static void vt82c686b_realize(PCIDevice *d, Error **errp)
|
||||||
{
|
{
|
||||||
VT82C686BState *vt82c = VT82C686B(d);
|
VT82C686BISAState *vt82c = VT82C686B_ISA(d);
|
||||||
uint8_t *pci_conf;
|
uint8_t *pci_conf;
|
||||||
ISABus *isa_bus;
|
ISABus *isa_bus;
|
||||||
uint8_t *wmask;
|
uint8_t *wmask;
|
||||||
|
@ -479,7 +479,7 @@ ISABus *vt82c686b_isa_init(PCIBus *bus, int devfn)
|
||||||
{
|
{
|
||||||
PCIDevice *d;
|
PCIDevice *d;
|
||||||
|
|
||||||
d = pci_create_simple_multifunction(bus, devfn, true, TYPE_VT82C686B);
|
d = pci_create_simple_multifunction(bus, devfn, true, TYPE_VT82C686B_ISA);
|
||||||
return ISA_BUS(qdev_get_child_bus(DEVICE(d), "isa.0"));
|
return ISA_BUS(qdev_get_child_bus(DEVICE(d), "isa.0"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -505,9 +505,9 @@ static void via_class_init(ObjectClass *klass, void *data)
|
||||||
}
|
}
|
||||||
|
|
||||||
static const TypeInfo via_info = {
|
static const TypeInfo via_info = {
|
||||||
.name = TYPE_VT82C686B,
|
.name = TYPE_VT82C686B_ISA,
|
||||||
.parent = TYPE_PCI_DEVICE,
|
.parent = TYPE_PCI_DEVICE,
|
||||||
.instance_size = sizeof(VT82C686BState),
|
.instance_size = sizeof(VT82C686BISAState),
|
||||||
.class_init = via_class_init,
|
.class_init = via_class_init,
|
||||||
.interfaces = (InterfaceInfo[]) {
|
.interfaces = (InterfaceInfo[]) {
|
||||||
{ INTERFACE_CONVENTIONAL_PCI_DEVICE },
|
{ INTERFACE_CONVENTIONAL_PCI_DEVICE },
|
||||||
|
|
Loading…
Reference in New Issue