diff options
Diffstat (limited to 'src/include/usr/fapi2')
| -rw-r--r-- | src/include/usr/fapi2/attribute_service.H | 27 | ||||
| -rw-r--r-- | src/include/usr/fapi2/hwpf_fapi2_reasoncodes.H | 8 |
2 files changed, 34 insertions, 1 deletions
diff --git a/src/include/usr/fapi2/attribute_service.H b/src/include/usr/fapi2/attribute_service.H index d02e29df7..d4c21af4a 100644 --- a/src/include/usr/fapi2/attribute_service.H +++ b/src/include/usr/fapi2/attribute_service.H @@ -236,6 +236,25 @@ ReturnCode platGetPoundVBucketData(const Target<TARGET_TYPE_ALL>& i_fapiTarget, ReturnCode platGetPoundWBucketData(const Target<TARGET_TYPE_ALL>& i_fapiTarget, uint8_t * o_poundWData); +/// +/// @brief This function is called by the FAPI_ATTR_GET macro when getting +/// ATTR_WOF_TABLE_DATA. It should not be called directly +/// +/// +/// @param[in] i_fapiTarget FAPI2 Target reference +/// Currently system target and unused, +/// Could change to proc target later. +/// Don't need to check the type here, get macro +/// does it for us, thus use the all type to +/// allow streamlined dump of ATTR +/// @param[out] o_pos Output WOF table data +/// @return ReturnCode Always FAPI2_RC_SUCCESS, this cannot fail +/// if a toplevel target cannot be found then +/// an assert triggers in the platform call +/// +ReturnCode platGetWOFTableData(const Target<TARGET_TYPE_ALL>& i_fapiTarget, + uint8_t * o_wofTableData); + // ----------------------------------------------------------------------------- // End TODO: End to be supported functions // ----------------------------------------------------------------------------- @@ -317,4 +336,12 @@ fapiToTargeting::ID, sizeof(VAL), &(VAL)) ? fapi2::ReturnCode() : \ fapi2::platAttrSvc::platGetPoundWBucketData(TARGET,VAL) +//------------------------------------------------------------------------------ +// MACRO to route ATTR_WOF_TABLE_DATA access to the correct HB function +//------------------------------------------------------------------------------ +#define ATTR_WOF_TABLE_DATA_GETMACRO(ID, TARGET, VAL) \ + AttrOverrideSync::getAttrOverrideFunc(ID, TARGET, &VAL)\ + ? fapi2::ReturnCode() : \ + fapi2::platAttrSvc::platGetWOFTableData(TARGET,VAL) + #endif // ATTRIBUTESERVICE_H_ diff --git a/src/include/usr/fapi2/hwpf_fapi2_reasoncodes.H b/src/include/usr/fapi2/hwpf_fapi2_reasoncodes.H index e095e126b..78101fe95 100644 --- a/src/include/usr/fapi2/hwpf_fapi2_reasoncodes.H +++ b/src/include/usr/fapi2/hwpf_fapi2_reasoncodes.H @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2015,2016 */ +/* Contributors Listed Below - COPYRIGHT 2015,2017 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -56,6 +56,7 @@ namespace fapi2 MOD_FAPI2_SET_TARGETING_ATTR = 0x0D, MOD_FAPI2_PLAT_GET_VPD = 0x0E, MOD_FAPI2_PIB_ERR_MASK = 0x0F, + MOD_FAPI2_PLAT_PARSE_WOF_TABLES = 0x10, }; /** @@ -113,6 +114,11 @@ namespace fapi2 RC_INVALID_TYPE = FAPI2_COMP_ID | 0x28, RC_RETURNED_VPD_TOO_SMALL = FAPI2_COMP_ID | 0x29, RC_INVALID_ATTRIBUTE = FAPI2_COMP_ID | 0x2A, + RC_WOF_IMAGE_MAGIC_MISMATCH = FAPI2_COMP_ID | 0x2B, + RC_WOF_TABLES_MAGIC_MISMATCH = FAPI2_COMP_ID | 0x2C, + RC_WOF_TABLE_NOT_FOUND = FAPI2_COMP_ID | 0x2D, + RC_WOF_IMAGE_VERSION_MISMATCH = FAPI2_COMP_ID | 0x2E, + RC_WOF_TABLES_VERSION_MISMATCH = FAPI2_COMP_ID | 0x2F, // HWP generated errors RC_HWP_GENERATED_ERROR = HWPF_COMP_ID | 0x0f, |

