From 41daed137d2f31ba125a1ada241755e42f36868c Mon Sep 17 00:00:00 2001 From: Dan Crowell Date: Thu, 31 May 2018 17:03:24 -0500 Subject: Write Hostboot HRMOR into core scratch reg 1 Hostboot code will write the current HRMOR value into core scratch reg 1 (scom=xx010A87, spr=0x08) at initial boot. This data is ORed into the memory size data that was already present. The bootloader code will do the same. Also updated the debug tools to key off of this data if it is available to avoid any HRMOR hardcoding. The purpose of this change is to provide a method for the FSP code to handle various memory remapping scenarios that are currently in plan without needing any explicit communication from Hostboot. Change-Id: Ia3c81980ebd780ae182956cddae785dd408fbed9 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/59699 Reviewed-by: Prachi Gupta Tested-by: Jenkins Server Tested-by: FSP CI Jenkins Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Reviewed-by: William G. Hoffa --- src/include/bootloader/bootloader.H | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/include/bootloader') diff --git a/src/include/bootloader/bootloader.H b/src/include/bootloader/bootloader.H index 8020311ba..55b148f6b 100644 --- a/src/include/bootloader/bootloader.H +++ b/src/include/bootloader/bootloader.H @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2015,2017 */ +/* Contributors Listed Below - COPYRIGHT 2015,2018 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -139,6 +139,11 @@ namespace Bootloader{ } + /**Core Scratch Register 1 which tells HRMOR and memsize. + This is passed into writeScratchReg to select which scratch + reg you are writing */ +#define MMIO_SCRATCH_MEMORY_STATE 0x08 + /**Core Scratch Register 3 which tells the state of hostboot. This is passed into writeScratchReg to select which scratch reg you are writing */ -- cgit v1.2.3