diff options
author | Madhavan Srinivasan <maddy@linux.vnet.ibm.com> | 2019-01-28 13:32:27 +0530 |
---|---|---|
committer | Ram Pai <linuxram@us.ibm.com> | 2020-11-02 18:38:09 -0500 |
commit | 1f9a2570acf9924b819aed44758303479da402c6 (patch) | |
tree | eb6541209b1c865a6589d87fd8be479279f23827 /hw/fsp/fsp.c | |
parent | 01d95d85fd56ca135e02e0b6d09d45b2c3e9497e (diff) | |
download | skiboot-1f9a2570acf9924b819aed44758303479da402c6.zip skiboot-1f9a2570acf9924b819aed44758303479da402c6.tar.gz skiboot-1f9a2570acf9924b819aed44758303479da402c6.tar.bz2 |
Add ultravisor support in OPAL
Ultravisor is the firmware which runs in the new privelege mode called
ultravisor mode, which was introduced in Power 9. Ultravisor enables
running of secure virtual machines on the host.
Protected execution facility in Power 9 uses special memory areas
designated as secure memory, which can be accessed only in the ultravisor
mode. This protection is provided by the hardware. These designated memory
areas are used by the guests running as secure virtual machines.
The secure memory ranges are provided by the hostboot through HDATA. Get
secure memory ranges from HDATA and add to device tree for ultravisor
firmware.
Ultravisor firmware is present as a lid file or as 'UVISOR' partition.
Use flash resource load helper to load ultravisor firmware into secure
memory area pointed by the hdata.
The ultravisor image after is start on each CPU after being loaded from
the flash/fsp. It is copied to secure memory and run.
Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
Signed-off-by: Santosh Sivaraj <santosh@fossix.org>
[ grimm: Add init_uv comments, logging, and logic cleanups ]
[ grimm: Increase UV image max size to 2MB ]
[ grimm: Redfine the OPAL UV shared data structure ]
[ grimm: Remove Hostboot regions from secure range 0 ]
[ grimm: SPDX licensing ]
[ grimm: clean up allocation and freeing ]
[ grimm: DT bindings fixups ]
[ grimm: Define load identifiers for ultra.lid.xz ]
[ grimm: Improve error logging ]
[ grimm: Fix secure-memory-ranges for multiple ranges ]
[ grimm: hdata: Dont ignore range if SMF is enbaled ]
[ grimm: use cleanup_addr on secure mem ranges ]
[ grimm: ret code checks, various cleanups for BML ]
Signed-off-by: Ryan Grimm <grimm@linux.ibm.com>
[ andmike: Split init and start of ultravisor ]
Signed-off-by: Michael Anderson <andmike@linux.ibm.com>
Diffstat (limited to 'hw/fsp/fsp.c')
-rw-r--r-- | hw/fsp/fsp.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/fsp/fsp.c b/hw/fsp/fsp.c index 6fa6534..829e56f 100644 --- a/hw/fsp/fsp.c +++ b/hw/fsp/fsp.c @@ -114,6 +114,7 @@ static u64 fsp_hir_timeout; #define KERNEL_LID_PHYP 0x80a00701 #define KERNEL_LID_OPAL 0x80f00101 #define INITRAMFS_LID_OPAL 0x80f00102 +#define ULTRA_LID_OPAL 0x80f00105 /* * We keep track on last logged values for some things to print only on @@ -2375,6 +2376,7 @@ static struct { } fsp_lid_map[] = { { RESOURCE_ID_KERNEL, RESOURCE_SUBID_NONE, KERNEL_LID_OPAL }, { RESOURCE_ID_INITRAMFS,RESOURCE_SUBID_NONE, INITRAMFS_LID_OPAL }, + { RESOURCE_ID_UV_IMAGE, RESOURCE_SUBID_NONE, ULTRA_LID_OPAL }, { RESOURCE_ID_IMA_CATALOG,IMA_CATALOG_NIMBUS, 0x80f00103 }, { RESOURCE_ID_CAPP, CAPP_IDX_MURANO_DD20, 0x80a02002 }, { RESOURCE_ID_CAPP, CAPP_IDX_MURANO_DD21, 0x80a02001 }, |