mirror of
https://github.com/xemu-project/xemu.git
synced 2024-11-27 13:30:52 +00:00
ppc/pnv: move phb_regs_mr to PnvPHB4
After recent changes, this MemoryRegion can be migrated to PnvPHB4 without too much trouble. Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com> Reviewed-by: Cédric Le Goater <clg@kaod.org> Message-Id: <20220113192952.911188-11-danielhb413@gmail.com> Signed-off-by: Cédric Le Goater <clg@kaod.org>
This commit is contained in:
parent
867683d86e
commit
293a1d27e3
@ -1481,9 +1481,9 @@ static void pnv_phb4_xscom_realize(PnvPHB4 *phb)
|
||||
PHB4_PEC_PCI_STK_REGS_COUNT);
|
||||
|
||||
/* PHB pass-through */
|
||||
snprintf(name, sizeof(name), "xscom-pec-%d.%d-pci-stack-%d-phb",
|
||||
snprintf(name, sizeof(name), "xscom-pec-%d.%d-pci-phb-%d",
|
||||
pec->chip_id, pec->index, stack->stack_no);
|
||||
pnv_xscom_region_init(&stack->phb_regs_mr, OBJECT(phb),
|
||||
pnv_xscom_region_init(&phb->phb_regs_mr, OBJECT(phb),
|
||||
&pnv_phb4_xscom_ops, phb, name, 0x40);
|
||||
|
||||
pec_nest_base = pecc->xscom_nest_base(pec);
|
||||
@ -1499,7 +1499,7 @@ static void pnv_phb4_xscom_realize(PnvPHB4 *phb)
|
||||
pnv_xscom_add_subregion(pec->chip,
|
||||
pec_pci_base + PNV9_XSCOM_PEC_PCI_STK0 +
|
||||
0x40 * stack->stack_no,
|
||||
&stack->phb_regs_mr);
|
||||
&phb->phb_regs_mr);
|
||||
}
|
||||
|
||||
static void pnv_phb4_instance_init(Object *obj)
|
||||
|
@ -117,6 +117,9 @@ struct PnvPHB4 {
|
||||
uint64_t nest_regs[PHB4_PEC_NEST_STK_REGS_COUNT];
|
||||
MemoryRegion nest_regs_mr;
|
||||
|
||||
/* PHB pass-through XSCOM */
|
||||
MemoryRegion phb_regs_mr;
|
||||
|
||||
/* Memory windows from PowerBus to PHB */
|
||||
MemoryRegion phbbar;
|
||||
MemoryRegion intbar;
|
||||
@ -170,9 +173,6 @@ struct PnvPhb4PecStack {
|
||||
/* My own stack number */
|
||||
uint32_t stack_no;
|
||||
|
||||
/* PHB pass-through XSCOM */
|
||||
MemoryRegion phb_regs_mr;
|
||||
|
||||
/* The owner PEC */
|
||||
PnvPhb4PecState *pec;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user