mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
hw/char/serial-{isa, pci}: Alias QDEV properties from generic serial object
Instead of overwritting the properties of the generic 'state' object, alias them. Note we can now propagate the "baudbase" property. Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20200907015535.827885-7-f4bug@amsat.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
1fa2c0eb6c
commit
b7dd40d40b
2 changed files with 4 additions and 3 deletions
|
@ -82,7 +82,6 @@ static const VMStateDescription vmstate_pci_serial = {
|
|||
};
|
||||
|
||||
static Property serial_pci_properties[] = {
|
||||
DEFINE_PROP_CHR("chardev", PCISerialState, state.chr),
|
||||
DEFINE_PROP_UINT8("prog_if", PCISerialState, prog_if, 0x02),
|
||||
DEFINE_PROP_END_OF_LIST(),
|
||||
};
|
||||
|
@ -107,6 +106,8 @@ static void serial_pci_init(Object *o)
|
|||
PCISerialState *ps = PCI_SERIAL(o);
|
||||
|
||||
object_initialize_child(o, "serial", &ps->state, TYPE_SERIAL);
|
||||
|
||||
qdev_alias_all_properties(DEVICE(&ps->state), o);
|
||||
}
|
||||
|
||||
static const TypeInfo serial_pci_info = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue