mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
apb: remove pci_apb_init() and instantiate APB device using qdev
By making the special_base and mem_base values qdev properties, we can move the remaining parts of pci_apb_init() into the pbm init() and realize() functions. This finally allows us to instantiate the APB directly using standard qdev create/init functions in sun4u.c. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Reviewed-by: Artyom Tarasenko <atar4qemu@gmail.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
This commit is contained in:
parent
4272ad4018
commit
cacd05805e
3 changed files with 69 additions and 67 deletions
|
@ -62,6 +62,8 @@ typedef struct IOMMUState {
|
|||
typedef struct APBState {
|
||||
PCIHostState parent_obj;
|
||||
|
||||
hwaddr special_base;
|
||||
hwaddr mem_base;
|
||||
MemoryRegion apb_config;
|
||||
MemoryRegion pci_config;
|
||||
MemoryRegion pci_mmio;
|
||||
|
@ -93,6 +95,4 @@ typedef struct PBMPCIBridge {
|
|||
#define PBM_PCI_BRIDGE(obj) \
|
||||
OBJECT_CHECK(PBMPCIBridge, (obj), TYPE_PBM_PCI_BRIDGE)
|
||||
|
||||
APBState *pci_apb_init(hwaddr special_base,
|
||||
hwaddr mem_base);
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue