aboutsummaryrefslogtreecommitdiff
path: root/hw/spapr.h
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2011-04-05 15:12:10 +1000
committerAlexander Graf <agraf@suse.de>2011-04-08 11:32:21 +0200
commita3467baa88c5bbb58834952980d2f2206aab4445 (patch)
treed7b253cb8228c81343753cfa169fb702e6a025db /hw/spapr.h
parentc7a5c0c9280c2ddaa875e3cafb3df16a96af809c (diff)
downloadqemu-a3467baa88c5bbb58834952980d2f2206aab4445.zip
qemu-a3467baa88c5bbb58834952980d2f2206aab4445.tar.gz
qemu-a3467baa88c5bbb58834952980d2f2206aab4445.tar.bz2
Delay creation of pseries device tree until reset
At present, the 'pseries' machine creates a flattened device tree in the machine->init function to pass to either the guest kernel or to firmware. However, the machine->init function runs before processing of -device command line options, which means that the device tree so created will be (incorrectly) missing devices specified that way. Supplying a correct device tree is, in any case, part of the required platform entry conditions. Therefore, this patch moves the creation and loading of the device tree from machine->init to a reset callback. The setup of entry point address and initial register state moves with it, which leads to a slight cleanup. This is not, alas, quite enough to make a fully working reset for pseries. For that we would need to reload the firmware images, which on this machine are loaded into RAM. It's a step in the right direction, though. Signed-off-by: David Gibson <dwg@au1.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'hw/spapr.h')
-rw-r--r--hw/spapr.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/hw/spapr.h b/hw/spapr.h
index fae8e13..b52133a 100644
--- a/hw/spapr.h
+++ b/hw/spapr.h
@@ -7,6 +7,13 @@ struct icp_state;
typedef struct sPAPREnvironment {
struct VIOsPAPRBus *vio_bus;
struct icp_state *icp;
+
+ void *htab;
+ long htab_size;
+ target_phys_addr_t fdt_addr, rtas_addr;
+ long rtas_size;
+ void *fdt_skel;
+ target_ulong entry_point;
} sPAPREnvironment;
#define H_SUCCESS 0