From ac15fd763d3ef2968adcb4140f1f930f29ba6ecb Mon Sep 17 00:00:00 2001 From: Christian Geddes Date: Mon, 7 Jan 2019 16:06:41 -0600 Subject: Add new pnorLayoutAxone.xml w/ new EECACHE section This commit introduces a new pnor layout which will be used when the simics_axone.config file is used. (Note: axone.config was renamed to simics_axone.config). This new layout introduces the EECACHE section which will be used to store copies of the various EEPROMS in the system. The eventual goal is to be able to remove the MVPD/DJVPD sections in PNOR and only use this EECACHE section Change-Id: Ifae610c4dd7f3aa9c87a5ca911cc4faa1ba2a98a Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70172 Tested-by: Jenkins Server Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Tested-by: FSP CI Jenkins Reviewed-by: Matt Derksen Reviewed-by: Roland Veloz Reviewed-by: Daniel M. Crowell --- makefile | 10 +- src/build/buildpnor/pnorLayoutAxone.xml | 336 ++++++++++++++++++++++++++++++++ src/build/configs/axone.config | 1 - src/build/configs/simics_axone.config | 1 + src/build/mkrules/dist.targets.mk | 1 + src/build/mkrules/hbfw/img/makefile | 19 +- src/build/tools/hbDistribute | 11 +- src/include/usr/pnor/pnor_const.H | 3 +- src/usr/pnor/pnor_utils.C | 3 +- 9 files changed, 371 insertions(+), 14 deletions(-) create mode 100644 src/build/buildpnor/pnorLayoutAxone.xml delete mode 100644 src/build/configs/axone.config create mode 100644 src/build/configs/simics_axone.config diff --git a/makefile b/makefile index cfd8c9d58..16217fd5d 100644 --- a/makefile +++ b/makefile @@ -5,7 +5,7 @@ # # OpenPOWER HostBoot Project # -# Contributors Listed Below - COPYRIGHT 2010,2017 +# Contributors Listed Below - COPYRIGHT 2010,2019 # [+] International Business Machines Corp. # # @@ -36,8 +36,9 @@ SKIP_CONFIG_FILE_LOAD = 1 IMAGE_PASS_POST += $(GENDIR)/hwp_id.html CLEAN_TARGETS += $(GENDIR)/hwp_id.html -# Name of file to indicate if hostboot is building an fsp release. +# Name of file to indicate which release Hostboot is building for HB_FSP_RELEASE = $(GENDIR)/hb_fsp_release +HB_AXONE_RELEASE = $(GENDIR)/hb_simics_axone_release ifndef BUILD_MINIMAL IMAGE_PASS_POST += cscope ctags @@ -74,6 +75,7 @@ check_istep_modules: $(OBJS) GENCONFIG_TOOL = src/build/tools/hbGenConfig # At end of rule, create HB_FSP_RELEASE file if compiling with fsprelease.config +# or create HB_AXONE_RELEASE if compiling with simics_axone.config $(GENDIR)/.$(notdir $(CONFIG_FILE)).config: \ $(shell find -name HBconfig) \ $(filter-out $(GENDIR)/.$(notdir $(CONFIG_FILE)).config,\ @@ -88,6 +90,10 @@ $(GENDIR)/.$(notdir $(CONFIG_FILE)).config: \ @rm -f $(wildcard $(GENDIR)/.*.config) @touch $@ @rm -f $(HB_FSP_RELEASE) + @rm -f $(HB_AXONE_RELEASE) ifneq (,$(findstring fsprelease.config, $(strip $(CONFIG_FILE)))) @touch $(HB_FSP_RELEASE) endif + ifneq (,$(findstring simics_axone.config, $(strip $(CONFIG_FILE)))) + @touch $(HB_AXONE_RELEASE) + endif diff --git a/src/build/buildpnor/pnorLayoutAxone.xml b/src/build/buildpnor/pnorLayoutAxone.xml new file mode 100644 index 000000000..f34256482 --- /dev/null +++ b/src/build/buildpnor/pnorLayoutAxone.xml @@ -0,0 +1,336 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0x4000000 + 0x4000000 + 0x1000 + 0x8000 + + 0x3FF7000 + 0x0 + A-D-B + + B + + +
+ Hostboot Error Logs (144K) + HBEL + 0x8000 + 0x24000 + sideless + +
+
+ Guard Data (20K) + GUARD + 0x2C000 + 0x5000 + sideless + +
+
+ DIMM JEDEC (288K) + DJVPD + + 0x31000 + 0x48000 + sideless + +
+
+ Module VPD (576K) + MVPD + + 0x79000 + 0x90000 + sideless + +
+
+ Centaur VPD (288K) + CVPD + + 0x109000 + 0x48000 + sideless + +
+
+ Hostboot Base (1MB) + HBB + 0x151000 + 0x100000 + sideless + + +
+
+ Hostboot Data (2MB) + HBD + 0x251000 + 0x200000 + + sideless + +
+
+ Hostboot Extended image (12MB w/o ECC) + HBI + 0x451000 + 0xD80000 + + sideless + +
+
+ SBE-IPL (Staging Area) (752K) + SBE + 0x11D1000 + 0xBC000 + + + sideless + +
+
+ HCODE Ref Image (1.125MB) + HCODE + 0x128D000 + 0x120000 + + sideless + +
+
+ Hostboot Runtime Services for Sapphire (7.0MB) + HBRT + 0x13AD000 + 0x700000 + + sideless + +
+
+ Payload (21.375MB) + PAYLOAD + 0x1AAD000 + 0x1560000 + + sideless + +
+
+ Special PNOR Test Space (36K) + TEST + 0x300D000 + 0x9000 + + sideless + +
+
+ + Special PNOR Test Space with Header (36K) + TESTRO + 0x3016000 + 0x9000 + sideless + + + + +
+
+ Hostboot Bootloader (28K) + HBBL + 0x301F000 + + + 0x7000 + sideless + + +
+
+ Global Data (36K) + GLOBAL + 0x3026000 + 0x9000 + sideless + +
+
+ Ref Image Ring Overrides (20K) + RINGOVD + 0x302F000 + 0x5000 + sideless + +
+
+ SecureBoot Key Transition Partition (16K) + SBKT + 0x3034000 + 0x4000 + sideless + +
+
+ OCC Lid (1.125M) + OCC + 0x3038000 + 0x120000 + + sideless + +
+
+ VFRT data for WOF (12MB) + + WOFDATA + 0x3158000 + 0xC00000 + sideless + + +
+
+ FIRDATA (12K) + FIRDATA + 0x3D58000 + 0x3000 + sideless + +
+
+ Memory Data (128K) + MEMD + 0x3D5B000 + 0x20000 + sideless + + +
+
+ Secureboot Test Load (12K) + TESTLOAD + 0x3D7B000 + 0x3000 + sideless + + +
+
+ Centaur Hw Ref Image (12K) + CENHWIMG + 0x3D7E000 + 0x3000 + + sideless + +
+
+ Secure Boot (144K) + SECBOOT + 0x3D81000 + 0x24000 + sideless + + +
+
+ Open CAPI Memory Buffer (OCMB) Firmware (300K) + OCMBFW + 0x3DA5000 + 0x4B000 + sideless + + + +
+
+ HDAT Data (16K) + HDAT + 0x3DF0000 + 0x4000 + sideless + + +
+
+ Eeprom Cache(512K) + EECACHE + 0x3E14000 + 0x80000 + sideless + + +
+
diff --git a/src/build/configs/axone.config b/src/build/configs/axone.config deleted file mode 100644 index 965b1dc60..000000000 --- a/src/build/configs/axone.config +++ /dev/null @@ -1 +0,0 @@ -set DJVPD_READ_FROM_HW diff --git a/src/build/configs/simics_axone.config b/src/build/configs/simics_axone.config new file mode 100644 index 000000000..965b1dc60 --- /dev/null +++ b/src/build/configs/simics_axone.config @@ -0,0 +1 @@ +set DJVPD_READ_FROM_HW diff --git a/src/build/mkrules/dist.targets.mk b/src/build/mkrules/dist.targets.mk index 2ab00d9d7..d2302f3ba 100755 --- a/src/build/mkrules/dist.targets.mk +++ b/src/build/mkrules/dist.targets.mk @@ -305,6 +305,7 @@ fsp.tar_CONTENTS = \ src/build/buildpnor/imprintHwKeyHash \ src/build/buildpnor/defaultPnorLayout.xml \ src/build/buildpnor/pnorLayoutFSP.xml \ + src/build/buildpnor/pnorLayoutAxone.xml \ $(if $(FAKEPNOR), src/build/buildpnor/pnorLayoutFake.xml, ) \ $(if $(FAKEPNOR), img/vbu_NIMBUS_targeting.bin, ) \ $(if $(FAKEPNOR), img/vbu_NIMBUS_targeting.bin.protected, ) \ diff --git a/src/build/mkrules/hbfw/img/makefile b/src/build/mkrules/hbfw/img/makefile index 4f5a72219..1bfb01cea 100755 --- a/src/build/mkrules/hbfw/img/makefile +++ b/src/build/mkrules/hbfw/img/makefile @@ -5,7 +5,7 @@ # # OpenPOWER HostBoot Project # -# Contributors Listed Below - COPYRIGHT 2012,2018 +# Contributors Listed Below - COPYRIGHT 2012,2019 # [+] International Business Machines Corp. # # @@ -180,13 +180,18 @@ Secure Boot Signing Config:\n\ Libs to preload [${SIGNING_LIBS}]\n\ Path [${PATH}]\n\n" -# Default to using FSP layout for common file purposes and use existing hb -# techniques to enable default layout when appropriate. +# Use FSP layout for any FSP based system +# Use Default layout for standalone simics +# Use Axone layout for Axone simics PNOR_LAYOUT = ${pnorLayoutFSP.xml:P} -.if (${DEFAULT_PNOR} == 1) +.if (${PNOR_LAYOUT_SELECTED} == 1) PNOR_LAYOUT = ${defaultPnorLayout.xml:P} .endif +.if (${PNOR_LAYOUT_SELECTED} == 2) + PNOR_LAYOUT = ${pnorLayoutAxone.xml:P} +.endif + # Since this makefile is only ever used for an FSP signing environment, then # we can just specify that we want an fspbuild here without any condition. BUILD_TYPE_PARAMS = --build-type fspbuild @@ -201,7 +206,7 @@ BUILD_TYPE_PARAMS = --build-type fspbuild # Decide which PNOR to build .if (${FAKEPNOR} == "") # Parameters passed into GEN_PNOR_IMAGE_SCRIPT. - .if (${DEFAULT_PNOR} == 1) + .if (${PNOR_LAYOUT_SELECTED} == 1) GEN_DEFAULT_BIN_FILES = HBBL=${HBBL_IMG},HBB=${HBB_IMG},HBI=${HBI_IMG},HBRT=${HBRT_IMG},TEST=EMPTY,TESTRO=EMPTY,TESTLOAD=EMPTY,HBEL=EMPTY,GUARD=EMPTY,GLOBAL=EMPTY,PAYLOAD=EMPTY,CVPD=EMPTY,MVPD=EMPTY,DJVPD=EMPTY,RINGOVD=EMPTY,SBKT=EMPTY,FIRDATA=EMPTY,MEMD=${${ZZ_MEMD_IMG}:P} .else GEN_DEFAULT_BIN_FILES = HBBL=${HBBL_IMG},HBB=${HBB_IMG},HBI=${HBI_IMG},HBRT=${HBRT_IMG},HBEL=EMPTY,GUARD=EMPTY,GLOBAL=EMPTY,CVPD=EMPTY,MVPD=EMPTY,DJVPD=EMPTY,RINGOVD=EMPTY,SBKT=EMPTY,MEMD=${${ZZ_MEMD_IMG}:P} @@ -406,7 +411,7 @@ ZZ2U_HBD_FINAL_IMG = ZZ-2U.HBD.bin # Decide which PNOR to build .if (${FAKEPNOR} == "") # Paramemters passed into GEN_PNOR_IMAGE_SCRIPT. - .if (${DEFAULT_PNOR} == 1) + .if (${PNOR_LAYOUT_SELECTED} == 1) GEN_NIMBUS_BIN_FILES = NIMBUS:SBE=${${NIMBUS_SBE_IMG}:P},HCODE=${${NIMBUS_HCODE_IMG}:P},OCC=${${NIMBUS_OCC_IMG}:P},HBD=${${NIMBUS_HBD_IMG}:P},CENHWIMG=${NIMBUS_CENHWIMG_IMG} GEN_CUMULUS_BIN_FILES = CUMULUS:SBE=${${CUMULUS_SBE_IMG}:P},HCODE=${${CUMULUS_HCODE_IMG}:P},OCC=${${CUMULUS_OCC_IMG}:P},HBD=${${CUMULUS_HBD_IMG}:P},CENHWIMG=${${CUMULUS_CENHWIMG_IMG}:P} GEN_CUMULUS_CDIMM_BIN_FILES = CUMULUS_CDIMM:SBE=${${CUMULUS_SBE_IMG}:P},HCODE=${${CUMULUS_HCODE_IMG}:P},OCC=${${CUMULUS_OCC_IMG}:P},HBD=${${CUMULUS_CDIMM_HBD_IMG}:P},CENHWIMG=${${CUMULUS_CENHWIMG_IMG}:P} @@ -463,7 +468,7 @@ gen_system_specific_images_bypass_cache : dump-secureboot-config gen_system_specific_images: build_sbe_partitions .PMAKE @${MAKE:T:R} gen_system_specific_images_bypass_cache -.if (${DEFAULT_PNOR} == 1) +.if (${PNOR_LAYOUT_SELECTED} == 1) HOSTBOOT_DEFAULT_SECTIONS = HBBL=${HBBL_FINAL_IMG},HBB=${HBB_FINAL_IMG},HBI=${HBI_FINAL_IMG},HBRT=${HBRT_FINAL_IMG},TEST=${TEST_FINAL_IMG},TESTRO=${TESTRO_FINAL_IMG},TESTLOAD=${TESTLOAD_FINAL_IMG},HBEL=${HBEL_FINAL_IMG},GUARD=${GUARD_FINAL_IMG},GLOBAL=${GLOBAL_FINAL_IMG},PAYLOAD=${PAYLOAD_FINAL_IMG},CVPD=${CVPD_FINAL_IMG},MVPD=${MVPD_FINAL_IMG},DJVPD=${DJVPD_FINAL_IMG},RINGOVD=${RINGOVD_FINAL_IMG},SBKT=${SBKT_FINAL_IMG},FIRDATA=${FIRDATA_FINAL_IMG} NIMBUS_SECT = HBD=${NIMBUS_HBD_FINAL_IMG},SBE=${NIMBUS_SBE_FINAL_IMG},HCODE=${NIMBUS_HCODE_FINAL_IMG},OCC=${NIMBUS_OCC_FINAL_IMG},WOFDATA=${ZZ_WOFDATA_FINAL_IMG},CENHWIMG=${NIMBUS_CENHWIMG_FINAL_IMG},MEMD=${ZZ_MEMD_FINAL_IMG} CUMULUS_SECT = HBD=${CUMULUS_HBD_FINAL_IMG},SBE=${CUMULUS_SBE_FINAL_IMG},HCODE=${CUMULUS_HCODE_FINAL_IMG},OCC=${CUMULUS_OCC_FINAL_IMG},WOFDATA=${ZEPPELIN_WOFDATA_FINAL_IMG},CENHWIMG=${CUMULUS_CENHWIMG_FINAL_IMG},MEMD=${ZEPPELIN_MEMD_FINAL_IMG} diff --git a/src/build/tools/hbDistribute b/src/build/tools/hbDistribute index 8c501ad97..94816df8d 100755 --- a/src/build/tools/hbDistribute +++ b/src/build/tools/hbDistribute @@ -6,7 +6,7 @@ # # OpenPOWER HostBoot Project # -# Contributors Listed Below - COPYRIGHT 2012,2018 +# Contributors Listed Below - COPYRIGHT 2012,2019 # [+] International Business Machines Corp. # # @@ -210,9 +210,16 @@ fi # Note this file is generated in the hb config file rule in top level makefile if [[ -f ${PROJECT_ROOT}/obj/genfiles/hb_fsp_release ]]; then echo "FSP build, using fsp pnor xml layout" + # PNOR_LAYOUT_SELECTED == 0 is FSP XML + export PNOR_LAYOUT_SELECTED=0 +elif [[ -f ${PROJECT_ROOT}/obj/genfiles/hb_simics_axone_release ]]; then + echo "Axone build, using axone pnor xml layout" + # PNOR_LAYOUT_SELECTED == 2 is AXONE XML + export PNOR_LAYOUT_SELECTED=2 else + # PNOR_LAYOUT_SELECTED == 1 is DEFAULT XML echo "Non FSP build, using default pnor xml layout" - export DEFAULT_PNOR=1 + export PNOR_LAYOUT_SELECTED=1 fi # Clean up preivous rand files. Should only be needed if a previous call failed. diff --git a/src/include/usr/pnor/pnor_const.H b/src/include/usr/pnor/pnor_const.H index e8716c12c..d2515b70f 100644 --- a/src/include/usr/pnor/pnor_const.H +++ b/src/include/usr/pnor/pnor_const.H @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2015,2018 */ +/* Contributors Listed Below - COPYRIGHT 2015,2019 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -75,6 +75,7 @@ enum SectionId TESTLOAD, /**< Secureboot test load */ CENTAUR_HW_IMG, /**< Centaur HCODE Reference image */ HDAT, /**< HDAT data */ + EECACHE, #endif NUM_SECTIONS, /**< Number of defined sections */ diff --git a/src/usr/pnor/pnor_utils.C b/src/usr/pnor/pnor_utils.C index 44a4bd03d..68df913e0 100644 --- a/src/usr/pnor/pnor_utils.C +++ b/src/usr/pnor/pnor_utils.C @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2011,2018 */ +/* Contributors Listed Below - COPYRIGHT 2011,2019 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -449,6 +449,7 @@ const char * PNOR::SectionIdToString( uint32_t i_secIdIndex ) "TESTLOAD", /**< PNOR::TESTLOAD : Secureboot Test Load */ "CENHWIMG", /**< PNOR::CENTAUR_HW_IMG : Centaur HCODE ref image */ "HDAT", /**< PNOR::HDAT : Hdat Data */ + "EECACHE", /**< PNOR::EECACHE : Cached data from various EEPROMs */ #endif }; -- cgit v1.2.3