ppc/pnv: fix LPC HC firmware address space
PATCH 1/1 ppc/pnv: fix LPC HC firmware address space
A specific MemoryRegion is required for the LPC HC Firmware address space.
Signed-off-by Cédric Le Goater <[email protected]>
--- include/hw/ppc/pnv_lpc.h | 1 + hw/ppc/pnv_lpc.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-)
include/hw/ppc/pnv_lpc.h +1 -0
@@ -38,6 +38,7 @@ typedef struct PnvLpcController {/* ISA IO and Memory space */ MemoryRegion isa_io;MemoryRegion isa_mem; +MemoryRegion isa_fw;/* Windows from OPB to ISA (aliases) */ MemoryRegion opb_isa_io;
hw/ppc/pnv_lpc.c +3 -1
@@ -79,6 +79,7 @@ enum {#define ISA_IO_SIZE 0x00010000#define ISA_MEM_SIZE 0x10000000 +#define ISA_FW_SIZE 0x10000000#define LPC_IO_OPB_ADDR 0xd0010000#define LPC_IO_OPB_SIZE 0x00010000#define LPC_MEM_OPB_ADDR 0xe0010000
@@ -437,6 +438,7 @@ static void pnv_lpc_realize(DeviceState *dev, Error **errp)*/ memory_region_init (&lpc->isa_io,OBJECT (dev),"isa-io" ,ISA_IO_SIZE );memory_region_init (&lpc->isa_mem,OBJECT (dev),"isa-mem" ,ISA_MEM_SIZE ); +memory_region_init (&lpc->isa_fw,OBJECT (dev),"isa-fw" ,ISA_FW_SIZE );/* Create windows from the OPB space to the ISA space */ memory_region_init_alias(&lpc->opb_isa_io, OBJECT(dev), "lpc-isa-io",
@@ -448,7 +450,7 @@ static void pnv_lpc_realize(DeviceState *dev, Error **errp)memory_region_add_subregion (&lpc->opb_mr,LPC_MEM_OPB_ADDR , &lpc->opb_isa_mem);memory_region_init_alias (&lpc->opb_isa_fw,OBJECT (dev),"lpc-isa-fw" , - &lpc->isa_mem,0 ,LPC_FW_OPB_SIZE ); + &lpc->isa_fw,0 ,LPC_FW_OPB_SIZE );memory_region_add_subregion (&lpc->opb_mr,LPC_FW_OPB_ADDR , &lpc->opb_isa_fw);
Signature · 1 line
2.13.6
David Gibson
AppliedQuoted 4 lines · Cédric Le Goater
A specific MemoryRegion is required for the LPC HC Firmware address space.
Signed-off-by Cédric Le Goater <[email protected]>
Applied to ppc-for-3.0, thanks.
Quoted 46 lines
--- include/hw/ppc/pnv_lpc.h | 1 + hw/ppc/pnv_lpc.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-)include/hw/ppc/pnv_lpc.h +1
-0@@ -38,6 +38,7 @@ typedef struct PnvLpcController {/* ISA IO and Memory space */ MemoryRegion isa_io;MemoryRegion isa_mem; +MemoryRegion isa_fw;/* Windows from OPB to ISA (aliases) */ MemoryRegion opb_isa_io;hw/ppc/pnv_lpc.c +3
-1@@ -79,6 +79,7 @@ enum {#define ISA_IO_SIZE 0x00010000#define ISA_MEM_SIZE 0x10000000 +#define ISA_FW_SIZE 0x10000000#define LPC_IO_OPB_ADDR 0xd0010000#define LPC_IO_OPB_SIZE 0x00010000#define LPC_MEM_OPB_ADDR 0xe0010000@@ -437,6 +438,7 @@ static void pnv_lpc_realize(DeviceState *dev, Error **errp)*/ memory_region_init (&lpc->isa_io,OBJECT (dev),"isa-io" ,ISA_IO_SIZE );memory_region_init (&lpc->isa_mem,OBJECT (dev),"isa-mem" ,ISA_MEM_SIZE ); +memory_region_init (&lpc->isa_fw,OBJECT (dev),"isa-fw" ,ISA_FW_SIZE );/* Create windows from the OPB space to the ISA space */ memory_region_init_alias(&lpc->opb_isa_io, OBJECT(dev), "lpc-isa-io",@@ -448,7 +450,7 @@ static void pnv_lpc_realize(DeviceState *dev, Error **errp)memory_region_add_subregion (&lpc->opb_mr,LPC_MEM_OPB_ADDR , &lpc->opb_isa_mem);memory_region_init_alias (&lpc->opb_isa_fw,OBJECT (dev),"lpc-isa-fw" , - &lpc->isa_mem,0 ,LPC_FW_OPB_SIZE ); + &lpc->isa_fw,0 ,LPC_FW_OPB_SIZE );memory_region_add_subregion (&lpc->opb_mr,LPC_FW_OPB_ADDR , &lpc->opb_isa_fw);
Signature · 4 lines
David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson