diff options
author | Alexey Kardashevskiy <aik@ozlabs.ru> | 2017-10-04 15:06:36 +1100 |
---|---|---|
committer | Alexey Kardashevskiy <aik@ozlabs.ru> | 2017-11-06 13:28:49 +1100 |
commit | f8d999c7d9ab44eb86f32f4ada7f98d52364bbf1 (patch) | |
tree | 88b5caf836d4c7790d5417669b2b0607e25f7bec | |
parent | 608e416bb114ce964e742733ea6a4a5fc7c968c8 (diff) | |
download | SLOF-f8d999c7d9ab44eb86f32f4ada7f98d52364bbf1.zip SLOF-f8d999c7d9ab44eb86f32f4ada7f98d52364bbf1.tar.gz SLOF-f8d999c7d9ab44eb86f32f4ada7f98d52364bbf1.tar.bz2 |
rtas: Store RTAS address and entry in the device tree
At the moment we count on the guest kernel to update or create device
tree properties pointing to the instantiated RTAS copy which is not
very reliable.
This stores rtas-base and rtas-size in the DT at the instantiation
point so later on the H_UPDATE_DT hcall can supply QEMU with an updated
location of RTAS.
This superseeds f9a60de30 "Add private HCALL to inform updated
RTAS base and entry".
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
---
Changes:
v5:
* ditched rtas-entry, added rtas-size (which is always 20 bytes though)
-rw-r--r-- | board-qemu/slof/rtas.fs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/board-qemu/slof/rtas.fs b/board-qemu/slof/rtas.fs index f1a4abe..092f5b1 100644 --- a/board-qemu/slof/rtas.fs +++ b/board-qemu/slof/rtas.fs @@ -176,7 +176,14 @@ rtas-node set-node : open true ; : close ; +: store-rtas-loc ( adr ) + s" /rtas" find-node >r + encode-int s" slof,rtas-base" r@ set-property + rtas-size encode-int s" slof,rtas-size" r> set-property +; + : instantiate-rtas ( adr -- entry ) + dup store-rtas-loc dup rtas-base swap rtas-size move rtas-entry rtas-base - + ; |