diff options
| author | Stephen Cprek <smcprek@us.ibm.com> | 2014-11-14 14:39:53 -0600 |
|---|---|---|
| committer | A. Patrick Williams III <iawillia@us.ibm.com> | 2015-02-02 13:37:42 -0600 |
| commit | 67c5a1ebe73f81bca1bb6608bbb8f204f0f37fa8 (patch) | |
| tree | 2770690ea72f29f51ff7db676178474a25b9ced0 /src/include/usr/pnor | |
| parent | f0d809efddca10be40e2e5b7a60e8c5106522c31 (diff) | |
| download | blackbird-hostboot-67c5a1ebe73f81bca1bb6608bbb8f204f0f37fa8.tar.gz blackbird-hostboot-67c5a1ebe73f81bca1bb6608bbb8f204f0f37fa8.zip | |
Support for Redundant Copy of HB code in PNOR
- 2 TOC's per side
- side, sideless, preserved, and readOnly tags
- Determine which SEEPROM side HB booted from
- Modify gaurd code to not run when gaurd section DNE
Change-Id: I62dd27c9aa79c3111d27e647f1b66a7c938ad6e8
RTC:109398
Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/14629
Tested-by: Jenkins Server
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/include/usr/pnor')
| -rw-r--r-- | src/include/usr/pnor/pnor_reasoncodes.H | 2 | ||||
| -rw-r--r-- | src/include/usr/pnor/pnorif.H | 39 |
2 files changed, 38 insertions, 3 deletions
diff --git a/src/include/usr/pnor/pnor_reasoncodes.H b/src/include/usr/pnor/pnor_reasoncodes.H index a9854a4bc..4857c1b2c 100644 --- a/src/include/usr/pnor/pnor_reasoncodes.H +++ b/src/include/usr/pnor/pnor_reasoncodes.H @@ -136,6 +136,8 @@ namespace PNOR RC_PNOR_READ_NOT_SUPPORTED = PNOR_COMP_ID | 0x1F, RC_PNOR_WRITE_NOT_SUPPORTED = PNOR_COMP_ID | 0x20, RC_NON_ECC_PROTECTED_SECTION = PNOR_COMP_ID | 0x21, + RC_WRITABLE_PERM_FAIL = PNOR_COMP_ID | 0x22, + RC_WRITE_TRACKED_PERM_FAIL = PNOR_COMP_ID | 0x23, }; enum UserDetailsTypes diff --git a/src/include/usr/pnor/pnorif.H b/src/include/usr/pnor/pnorif.H index a9856f814..26890771a 100644 --- a/src/include/usr/pnor/pnorif.H +++ b/src/include/usr/pnor/pnorif.H @@ -29,6 +29,7 @@ #include <stdint.h> #include <builtins.h> #include <errl/errlentry.H> +#include <utility> namespace PNOR { @@ -61,6 +62,7 @@ enum SectionId ATTR_PERM, /**< Permanent Attribute Override */ CAPP, /**< CAPP lid */ TEST, /**< Scratch space for PNOR test cases */ + TESTRO, /**< Scratch space for PNOR ReadOnly test cases */ NUM_SECTIONS, /**< Number of defined sections */ @@ -82,7 +84,8 @@ struct SectionInfo_t uint64_t size; /**< Size of partition in bytes */ bool eccProtected; /**< Section is ECC protected */ bool sha512Version; /**< Version Checking */ - bool sha512perEC; /**< Version Checking perEC */ + bool sha512perEC; /**< Version Checking perEC */ + bool readOnly; /**< Section is read only */ }; /** @@ -121,6 +124,7 @@ errlHndl_t fixECC (SectionId i_section); * true = PNOR DD is using L3 Cache for fake PNOR * false = PNOR DD not using L3 Cache for fake PNOR */ + bool usingL3Cache(); /** * @brief Clears the specified PNOR section with all FF's (w/ good ECC) @@ -131,8 +135,6 @@ errlHndl_t fixECC (SectionId i_section); */ errlHndl_t clearSection(PNOR::SectionId i_section); -bool usingL3Cache(); - /** * @brief Validate the Alternative Master Processor's LPC * Connection to PNOR @@ -141,6 +143,14 @@ bool usingL3Cache(); */ errlHndl_t validateAltMaster( void ); +//@ TODO RTC: 120061 add golden info +//@ TODO RTC: 109703 make golden changes for informing OPAL +struct TocInfo_t +{ + std::pair<uint64_t, uint64_t> activeTocOffsets; + std::pair<uint64_t, uint64_t> altTocOffsets; +}; + /** @brief PNOR::TEST section offsets for test cases to prevent * concurrency problems */ @@ -150,6 +160,29 @@ enum TestSectionOffset{ pnorTestSec_rt_readwrite_offset = 0x6000, }; +//////////////////////////////////////////////////////////////////////////////// +// SBE functionality that lives in PNOR + +// Used to keep track of perm/temp, and cur/alt +enum sbeSeepromSide_t +{ + SBE_SEEPROM0 = 0x00, // corresponds to EEPROM::SBE_PRIMARY + SBE_SEEPROM1 = 0x01, // corresponts to EEPROM::SBE_BACKUP + SBE_SEEPROM_INVALID = 0xFF, +}; + +/** + * @brief Determines which Seeprom was used to boot the SBE + * + * @param[in] i_target Target processor to customize + * + * @param[out] o_bootSide The Seeprom the SBE booted from + * + * @return errlHndl_t Error log handle on failure. + */ +errlHndl_t getSbeBootSeeprom(TARGETING::Target* i_target, + sbeSeepromSide_t& o_bootSide); + } #endif |

