diff options
Diffstat (limited to 'src/import/chips/p9')
5 files changed, 118 insertions, 13 deletions
diff --git a/src/import/chips/p9/procedures/hwp/customize/p9_xip_customize.C b/src/import/chips/p9/procedures/hwp/customize/p9_xip_customize.C index 2fdb46607..bfc425dca 100644 --- a/src/import/chips/p9/procedures/hwp/customize/p9_xip_customize.C +++ b/src/import/chips/p9/procedures/hwp/customize/p9_xip_customize.C @@ -73,6 +73,8 @@ enum ChipPosIdentifier EC_POSITION = 0x00800000 }; +const uint8_t MAX_FILTER_PLL_BUCKETS = 4; + typedef struct { //Read as:0000 0000 000X 000X 000X 000X 000X 000X (binary;X=[0,1]) EQ:[0:05] @@ -166,32 +168,27 @@ fapi2::ReturnCode writeMboxRegs ( // for backwards compatiblity with images that don't contain // the OB/MC PLL bucket attributes, ensure that the item exists // prior to attempting an update which would otherwise fail - if (p9_xip_find(i_image, "ATTR_OB0_PLL_BUCKET", &l_item) != - P9_XIP_ITEM_NOT_FOUND) + if (!p9_xip_find(i_image, "ATTR_OB0_PLL_BUCKET", &l_item)) { MBOX_ATTR_WRITE(ATTR_OB0_PLL_BUCKET, i_procTarget, i_image); } - if (p9_xip_find(i_image, "ATTR_OB1_PLL_BUCKET", &l_item) != - P9_XIP_ITEM_NOT_FOUND) + if (!p9_xip_find(i_image, "ATTR_OB1_PLL_BUCKET", &l_item)) { MBOX_ATTR_WRITE(ATTR_OB1_PLL_BUCKET, i_procTarget, i_image); } - if (p9_xip_find(i_image, "ATTR_OB2_PLL_BUCKET", &l_item) != - P9_XIP_ITEM_NOT_FOUND) + if (!p9_xip_find(i_image, "ATTR_OB2_PLL_BUCKET", &l_item)) { MBOX_ATTR_WRITE(ATTR_OB2_PLL_BUCKET, i_procTarget, i_image); } - if (p9_xip_find(i_image, "ATTR_OB3_PLL_BUCKET", &l_item) != - P9_XIP_ITEM_NOT_FOUND) + if (!p9_xip_find(i_image, "ATTR_OB3_PLL_BUCKET", &l_item)) { MBOX_ATTR_WRITE(ATTR_OB3_PLL_BUCKET, i_procTarget, i_image); } - if (p9_xip_find(i_image, "ATTR_MC_PLL_BUCKET", &l_item) != - P9_XIP_ITEM_NOT_FOUND) + if (!p9_xip_find(i_image, "ATTR_MC_PLL_BUCKET", &l_item)) { MBOX_ATTR_WRITE(ATTR_MC_PLL_BUCKET, FAPI_SYSTEM, i_image); } @@ -1950,12 +1947,79 @@ ReturnCode p9_xip_customize ( FAPI_DBG("Input image size: %d", l_inputImageSize); +#ifndef WIN32 + /////////////////////////////////////////////////////////////////////////// - // CUSTOMIZE item: Write mailbox attributes + // CUSTOMIZE item: Update Filter PLL attribute from MVPD AW keyword // System phase: HB_SBE /////////////////////////////////////////////////////////////////////////// -#ifndef WIN32 + if (i_sysPhase == SYSPHASE_HB_SBE) + { + uint8_t l_filterPllBucket = 0; + uint32_t l_sizeMvpdFieldExpected = 4; + uint32_t l_sizeMvpdField = 0; + uint8_t* l_bufMvpdField = (uint8_t*)i_ringBuf1; + P9XipItem l_item; + + FAPI_TRY( getMvpdField(MVPD_RECORD_CP00, + MVPD_KEYWORD_AW, + i_procTarget, + NULL, + l_sizeMvpdField), + "getMvpdField(NULL buffer) failed w/rc=0x%08x", + (uint64_t)fapi2::current_err ); + + FAPI_ASSERT( l_sizeMvpdField == l_sizeMvpdFieldExpected, + fapi2::XIPC_MVPD_FIELD_SIZE_MESS(). + set_CHIP_TARGET(i_procTarget). + set_MVPD_FIELD_SIZE(l_sizeMvpdField). + set_EXPECTED_SIZE(l_sizeMvpdFieldExpected), + "MVPD field size bug:\n" + " Returned MVPD field size of AW keyword = %d\n" + " Anticipated MVPD field size = %d", + l_sizeMvpdField, + l_sizeMvpdFieldExpected ); + + FAPI_TRY( getMvpdField(MVPD_RECORD_CP00, + MVPD_KEYWORD_AW, + i_procTarget, + l_bufMvpdField, + l_sizeMvpdField), + "getMvpdField(valid buffer) failed w/rc=0x%08x", + (uint64_t)fapi2::current_err ); + + // extract data + l_filterPllBucket = (uint8_t)(*l_bufMvpdField); + + FAPI_ASSERT( l_filterPllBucket <= MAX_FILTER_PLL_BUCKETS, + fapi2::XIPC_MVPD_AW_FIELD_VALUE_ERR(). + set_CHIP_TARGET(i_procTarget). + set_MVPD_VALUE(l_filterPllBucket), + "MVPD AW field bug:\n" + " Value of filter PLL bucket select = %d\n" + " Anticipated range = 0..%d\n", + l_filterPllBucket, + MAX_FILTER_PLL_BUCKETS ); + + // set FAPI attribute + FAPI_TRY(FAPI_ATTR_SET( fapi2::ATTR_FILTER_PLL_BUCKET, + i_procTarget, + l_filterPllBucket ), + "Error from FAPI_ATTR_SET (ATTR_FILTER_PLL_BUCKET)" ); + + // customize attribute in SBE image, if field exists + if (!p9_xip_find(io_image, "ATTR_FILTER_PLL_BUCKET", &l_item)) + { + MBOX_ATTR_WRITE(ATTR_FILTER_PLL_BUCKET, i_procTarget, io_image); + } + } + + + /////////////////////////////////////////////////////////////////////////// + // CUSTOMIZE item: Write mailbox attributes + // System phase: HB_SBE + /////////////////////////////////////////////////////////////////////////// if (i_sysPhase == SYSPHASE_HB_SBE) { diff --git a/src/import/chips/p9/procedures/xml/attribute_info/pervasive_attributes.xml b/src/import/chips/p9/procedures/xml/attribute_info/pervasive_attributes.xml index 25648f418..4c7cc2bc6 100755 --- a/src/import/chips/p9/procedures/xml/attribute_info/pervasive_attributes.xml +++ b/src/import/chips/p9/procedures/xml/attribute_info/pervasive_attributes.xml @@ -141,6 +141,16 @@ </attribute> <attribute> + <id>ATTR_FILTER_PLL_BUCKET</id> + <targetType>TARGET_TYPE_PROC_CHIP</targetType> + <description>Select Filter PLL BGoffset programming</description> + <valueType>uint8</valueType> + <persistRuntime/> + <writeable/> + <initToZero/> +</attribute> + +<attribute> <id>ATTR_OB0_PLL_BUCKET</id> <targetType>TARGET_TYPE_PROC_CHIP</targetType> <description>Select OBUS0 pll setting from one of the supported frequencies</description> diff --git a/src/import/chips/p9/procedures/xml/error_info/p9_sbe_chiplet_pll_initf_errors.xml b/src/import/chips/p9/procedures/xml/error_info/p9_sbe_chiplet_pll_initf_errors.xml index 7647500ef..d90fd65ea 100755 --- a/src/import/chips/p9/procedures/xml/error_info/p9_sbe_chiplet_pll_initf_errors.xml +++ b/src/import/chips/p9/procedures/xml/error_info/p9_sbe_chiplet_pll_initf_errors.xml @@ -48,4 +48,12 @@ <ffdc>OB3_BUCKET_INDEX</ffdc> </hwpError> <!-- ******************************************************************** --> + <hwpError> + <sbeError/> + <rc>RC_P9_SBE_CHIPLET_PLL_INITF_UNSUPPORTED_MC_BUCKET</rc> + <description>Unsupported MC PLL bucket select</description> + <ffdc>TARGET</ffdc> + <ffdc>BUCKET_INDEX</ffdc> + </hwpError> + <!-- ******************************************************************** --> </hwpErrors> diff --git a/src/import/chips/p9/procedures/xml/error_info/p9_sbe_npll_initf_errors.xml b/src/import/chips/p9/procedures/xml/error_info/p9_sbe_npll_initf_errors.xml index 8fc8a2500..842783c76 100755 --- a/src/import/chips/p9/procedures/xml/error_info/p9_sbe_npll_initf_errors.xml +++ b/src/import/chips/p9/procedures/xml/error_info/p9_sbe_npll_initf_errors.xml @@ -27,7 +27,7 @@ <!-- ******************************************************************** --> <hwpError> <sbeError/> - <rc>RC_P9_SBE_NPLL_INITF_UNSUPPORTED_BUCKET</rc> + <rc>RC_P9_SBE_NPLL_INITF_UNSUPPORTED_NPLL_BUCKET</rc> <description>Unsupported Nest PLL bucket value</description> <ffdc>TARGET</ffdc> <ffdc>BUCKET_INDEX</ffdc> @@ -37,4 +37,16 @@ </callout> </hwpError> <!-- ******************************************************************** --> + <hwpError> + <sbeError/> + <rc>RC_P9_SBE_NPLL_INITF_UNSUPPORTED_FPLL_BUCKET</rc> + <description>Unsupported Filter PLL bucket value</description> + <ffdc>TARGET</ffdc> + <ffdc>BUCKET_INDEX</ffdc> + <callout> + <procedure>CODE</procedure> + <priority>HIGH</priority> + </callout> + </hwpError> + <!-- ******************************************************************** --> </hwpErrors> diff --git a/src/import/chips/p9/procedures/xml/error_info/p9_xip_customize_errors.xml b/src/import/chips/p9/procedures/xml/error_info/p9_xip_customize_errors.xml index 6ed8f88b6..c5a55f7d3 100644 --- a/src/import/chips/p9/procedures/xml/error_info/p9_xip_customize_errors.xml +++ b/src/import/chips/p9/procedures/xml/error_info/p9_xip_customize_errors.xml @@ -170,6 +170,17 @@ </hwpError> <!-- ********************************************************************* --> <hwpError> + <rc>RC_XIPC_MVPD_AW_FIELD_VALUE_ERR</rc> + <description>Out of range value observed in MVPD AW keyword</description> + <ffdc>CHIP_TARGET</ffdc> + <ffdc>MVPD_VALUE</ffdc> + <callout> + <procedure>CODE</procedure> + <priority>HIGH</priority> + </callout> + </hwpError> + <!-- ********************************************************************* --> + <hwpError> <rc>RC_XIPC_RS4_REDUNDANT_ERROR</rc> <description>rs4_redundant() failed</description> <ffdc>CHIP_TARGET</ffdc> |