summaryrefslogtreecommitdiffstats
path: root/src/import/chips
diff options
context:
space:
mode:
authorAdam Hale <adam.samuel.hale@ibm.com>2018-10-10 17:08:42 -0500
committerChristian R. Geddes <crgeddes@us.ibm.com>2018-10-18 10:55:31 -0500
commit4f8994da8802111de87c90a4cd0b984b64a200f5 (patch)
tree323fdeb808eba850b4258fa27506ef829deab6e5 /src/import/chips
parent26d020f01c51f5b92fa8e66dcfcc4b6a656c4bf9 (diff)
downloadtalos-hostboot-4f8994da8802111de87c90a4cd0b984b64a200f5.tar.gz
talos-hostboot-4f8994da8802111de87c90a4cd0b984b64a200f5.zip
HW467590 - WAT Solution to prevent ARMWF starvation early hang
CMVC-Prereq: 1070687 Change-Id: I72b6ea74f053a13532a7d0f887795cfc0160cef2 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/67324 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: HWSV CI <hwsv-ci+hostboot@us.ibm.com> Reviewed-by: SHELTON LEUNG <sleung@us.ibm.com> Tested-by: PPE CI <ppe-ci+hostboot@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Jenny Huynh <jhuynh@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/67332 Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com>
Diffstat (limited to 'src/import/chips')
-rw-r--r--src/import/chips/p9/procedures/hwp/initfiles/p9c_dmi_scom.C37
-rw-r--r--src/import/chips/p9/procedures/hwp/initfiles/p9c_mc_scom.C105
-rw-r--r--src/import/chips/p9/procedures/hwp/initfiles/p9c_mi_scom.C26
-rw-r--r--src/import/chips/p9/procedures/xml/attribute_info/chip_ec_attributes.xml19
4 files changed, 186 insertions, 1 deletions
diff --git a/src/import/chips/p9/procedures/hwp/initfiles/p9c_dmi_scom.C b/src/import/chips/p9/procedures/hwp/initfiles/p9c_dmi_scom.C
index 1b61f1644..aef1aa481 100644
--- a/src/import/chips/p9/procedures/hwp/initfiles/p9c_dmi_scom.C
+++ b/src/import/chips/p9/procedures/hwp/initfiles/p9c_dmi_scom.C
@@ -53,6 +53,9 @@ constexpr uint64_t literal_0x33 = 0x33;
constexpr uint64_t literal_0x40 = 0x40;
constexpr uint64_t literal_0b01111 = 0b01111;
constexpr uint64_t literal_0b00001 = 0b00001;
+constexpr uint64_t literal_2 = 2;
+constexpr uint64_t literal_0x020 = 0x020;
+constexpr uint64_t literal_0x010 = 0x010;
constexpr uint64_t literal_3 = 3;
constexpr uint64_t literal_1167 = 1167;
constexpr uint64_t literal_1000 = 1000;
@@ -62,7 +65,6 @@ constexpr uint64_t literal_1400 = 1400;
constexpr uint64_t literal_1500 = 1500;
constexpr uint64_t literal_0b0 = 0b0;
constexpr uint64_t literal_0b1 = 0b1;
-constexpr uint64_t literal_2 = 2;
fapi2::ReturnCode p9c_dmi_scom(const fapi2::Target<fapi2::TARGET_TYPE_DMI>& TGT0,
const fapi2::Target<fapi2::TARGET_TYPE_SYSTEM>& TGT1, const fapi2::Target<fapi2::TARGET_TYPE_PROC_CHIP>& TGT3)
@@ -93,6 +95,10 @@ fapi2::ReturnCode p9c_dmi_scom(const fapi2::Target<fapi2::TARGET_TYPE_DMI>& TGT0
FAPI_TRY(FAPI_ATTR_GET(fapi2::ATTR_PROC_EPS_READ_CYCLES_T2, TGT1, l_TGT1_ATTR_PROC_EPS_READ_CYCLES_T2));
uint64_t l_def_MC_EPSILON_CFG_T2 = ((l_TGT1_ATTR_PROC_EPS_READ_CYCLES_T2 + literal_6) / literal_4);
uint64_t l_def_ENABLE_MCBUSY = literal_1;
+ fapi2::ATTR_CHIP_UNIT_POS_Type l_TGT0_ATTR_CHIP_UNIT_POS;
+ FAPI_TRY(FAPI_ATTR_GET(fapi2::ATTR_CHIP_UNIT_POS, TGT0, l_TGT0_ATTR_CHIP_UNIT_POS));
+ uint64_t l_def_POSITION = l_TGT0_ATTR_CHIP_UNIT_POS;
+ uint64_t l_def_CHAN0_OR_1 = ((l_def_POSITION % literal_4) < literal_2);
fapi2::ATTR_ENABLE_MEM_EARLY_DATA_SCOM_Type l_TGT1_ATTR_ENABLE_MEM_EARLY_DATA_SCOM;
FAPI_TRY(FAPI_ATTR_GET(fapi2::ATTR_ENABLE_MEM_EARLY_DATA_SCOM, TGT1, l_TGT1_ATTR_ENABLE_MEM_EARLY_DATA_SCOM));
uint64_t l_def_ENABLE_MCU_TIMEOUTS = literal_1;
@@ -269,6 +275,16 @@ fapi2::ReturnCode p9c_dmi_scom(const fapi2::Target<fapi2::TARGET_TYPE_DMI>& TGT0
l_scom_buffer.insert<12, 5, 59, uint64_t>(literal_0b01111 );
l_scom_buffer.insert<17, 5, 59, uint64_t>(literal_0b00001 );
+
+ if ((l_def_CHAN0_OR_1 == literal_1))
+ {
+ l_scom_buffer.insert<22, 10, 54, uint64_t>(literal_0x020 );
+ }
+ else if ((l_def_CHAN0_OR_1 == literal_0))
+ {
+ l_scom_buffer.insert<22, 10, 54, uint64_t>(literal_0x010 );
+ }
+
FAPI_TRY(fapi2::putScom(TGT0, 0x501082aull, l_scom_buffer));
}
{
@@ -504,6 +520,25 @@ fapi2::ReturnCode p9c_dmi_scom(const fapi2::Target<fapi2::TARGET_TYPE_DMI>& TGT0
FAPI_TRY(fapi2::putScom(TGT0, 0x7010914ull, l_scom_buffer));
}
{
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012344ull, l_scom_buffer ));
+
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_WDF_ON = 0x1;
+ l_scom_buffer.insert<1, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_WDF_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ0_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<2, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ0_DEBUG_0_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ1_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<4, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ1_DEBUG_0_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ2_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<6, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ2_DEBUG_0_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ3_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<8, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ3_DEBUG_0_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ4_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<10, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ4_DEBUG_0_ON );
+ constexpr auto l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ5_DEBUG_0_ON = 0x1;
+ l_scom_buffer.insert<12, 1, 63, uint64_t>(l_MCP_CHAN0_WDF_DBG_SEL_PWSEQ5_DEBUG_0_ON );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012344ull, l_scom_buffer));
+ }
+ {
FAPI_TRY(fapi2::getScom( TGT0, 0x7012348ull, l_scom_buffer ));
if (l_def_ENABLE_AMO_CACHING)
diff --git a/src/import/chips/p9/procedures/hwp/initfiles/p9c_mc_scom.C b/src/import/chips/p9/procedures/hwp/initfiles/p9c_mc_scom.C
index 9b1ed886f..d80db56f8 100644
--- a/src/import/chips/p9/procedures/hwp/initfiles/p9c_mc_scom.C
+++ b/src/import/chips/p9/procedures/hwp/initfiles/p9c_mc_scom.C
@@ -29,6 +29,15 @@
using namespace fapi2;
+constexpr uint64_t literal_0x400000000000 = 0x400000000000;
+constexpr uint64_t literal_0b0001111111111111111111111111111111111111111010000000000000000 =
+ 0b0001111111111111111111111111111111111111111010000000000000000;
+constexpr uint64_t literal_0x20000000001 = 0x20000000001;
+constexpr uint64_t literal_0x800000000000 = 0x800000000000;
+constexpr uint64_t literal_0x8000000000000000 = 0x8000000000000000;
+constexpr uint64_t literal_0x00000000000C0000 = 0x00000000000C0000;
+constexpr uint64_t literal_0b00000011000000000000000000100100000000000000000000000000000 =
+ 0b00000011000000000000000000100100000000000000000000000000000;
constexpr uint64_t literal_0b01110 = 0b01110;
fapi2::ReturnCode p9c_mc_scom(const fapi2::Target<fapi2::TARGET_TYPE_MC>& TGT0,
@@ -37,6 +46,78 @@ fapi2::ReturnCode p9c_mc_scom(const fapi2::Target<fapi2::TARGET_TYPE_MC>& TGT0,
{
fapi2::buffer<uint64_t> l_scom_buffer;
{
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012380ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 48, 16, uint64_t>(literal_0x400000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012380ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012381ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 61, 3, uint64_t>(literal_0b0001111111111111111111111111111111111111111010000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012381ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012383ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 44, 20, uint64_t>(literal_0x20000000001 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012383ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012385ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 48, 16, uint64_t>(literal_0x400000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012385ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012386ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 61, 3, uint64_t>(literal_0b0001111111111111111111111111111111111111111010000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012386ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012388ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 44, 20, uint64_t>(literal_0x20000000001 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012388ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x701238aull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 48, 16, uint64_t>(literal_0x400000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x701238aull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x701238bull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 61, 3, uint64_t>(literal_0b0001111111111111111111111111111111111111111010000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x701238bull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x701238dull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 44, 20, uint64_t>(literal_0x20000000001 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x701238dull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x701238full, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 48, 16, uint64_t>(literal_0x400000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x701238full, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012390ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 61, 3, uint64_t>(literal_0b0001111111111111111111111111111111111111111010000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012390ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x7012392ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 44, 20, uint64_t>(literal_0x20000000001 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x7012392ull, l_scom_buffer));
+ }
+ {
FAPI_TRY(fapi2::getScom( TGT0, 0x70123afull, l_scom_buffer ));
constexpr auto l_MCP_MISC_MBA_SCOMFIR_MCBPARMQ_CFG_CLOCK_MONITOR_EN_ON = 0x1;
@@ -44,6 +125,30 @@ fapi2::ReturnCode p9c_mc_scom(const fapi2::Target<fapi2::TARGET_TYPE_MC>& TGT0,
FAPI_TRY(fapi2::putScom(TGT0, 0x70123afull, l_scom_buffer));
}
{
+ FAPI_TRY(fapi2::getScom( TGT0, 0x70123e8ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 48, 16, uint64_t>(literal_0x800000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x70123e8ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x70123e9ull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 64, 0, uint64_t>(literal_0x8000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x70123e9ull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x70123eaull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 64, 0, uint64_t>(literal_0x00000000000C0000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x70123eaull, l_scom_buffer));
+ }
+ {
+ FAPI_TRY(fapi2::getScom( TGT0, 0x70123ebull, l_scom_buffer ));
+
+ l_scom_buffer.insert<0, 59, 5, uint64_t>(literal_0b00000011000000000000000000100100000000000000000000000000000 );
+ FAPI_TRY(fapi2::putScom(TGT0, 0x70123ebull, l_scom_buffer));
+ }
+ {
FAPI_TRY(fapi2::getScom( TGT0, 0x800f1c000701103full, l_scom_buffer ));
l_scom_buffer.insert<48, 5, 59, uint64_t>(literal_0b01110 );
diff --git a/src/import/chips/p9/procedures/hwp/initfiles/p9c_mi_scom.C b/src/import/chips/p9/procedures/hwp/initfiles/p9c_mi_scom.C
index 977fe9103..fb84b5cc3 100644
--- a/src/import/chips/p9/procedures/hwp/initfiles/p9c_mi_scom.C
+++ b/src/import/chips/p9/procedures/hwp/initfiles/p9c_mi_scom.C
@@ -49,6 +49,9 @@ constexpr uint64_t literal_0b01 = 0b01;
constexpr uint64_t literal_5 = 5;
constexpr uint64_t literal_0xE = 0xE;
constexpr uint64_t literal_0b100 = 0b100;
+constexpr uint64_t literal_2 = 2;
+constexpr uint64_t literal_0b010 = 0b010;
+constexpr uint64_t literal_0b000 = 0b000;
fapi2::ReturnCode p9c_mi_scom(const fapi2::Target<fapi2::TARGET_TYPE_MI>& TGT0,
const fapi2::Target<fapi2::TARGET_TYPE_SYSTEM>& TGT1, const fapi2::Target<fapi2::TARGET_TYPE_PROC_CHIP>& TGT2)
@@ -85,6 +88,10 @@ fapi2::ReturnCode p9c_mi_scom(const fapi2::Target<fapi2::TARGET_TYPE_MI>& TGT0,
fapi2::ATTR_SMF_CONFIG_Type l_TGT1_ATTR_SMF_CONFIG;
FAPI_TRY(FAPI_ATTR_GET(fapi2::ATTR_SMF_CONFIG, TGT1, l_TGT1_ATTR_SMF_CONFIG));
uint64_t l_def_ENABLE_MCU_TIMEOUTS = literal_1;
+ fapi2::ATTR_CHIP_UNIT_POS_Type l_TGT0_ATTR_CHIP_UNIT_POS;
+ FAPI_TRY(FAPI_ATTR_GET(fapi2::ATTR_CHIP_UNIT_POS, TGT0, l_TGT0_ATTR_CHIP_UNIT_POS));
+ uint64_t l_def_POSITION = l_TGT0_ATTR_CHIP_UNIT_POS;
+ uint64_t l_def_CHAN0_OR_1 = ((l_def_POSITION % literal_2) == literal_0);
fapi2::buffer<uint64_t> l_scom_buffer;
{
FAPI_TRY(fapi2::getScom( TGT0, 0x5010810ull, l_scom_buffer ));
@@ -353,6 +360,25 @@ fapi2::ReturnCode p9c_mi_scom(const fapi2::Target<fapi2::TARGET_TYPE_MI>& TGT0,
l_scom_buffer.insert<32, 4, 60, uint64_t>(literal_0xE );
l_scom_buffer.insert<16, 3, 61, uint64_t>(literal_0b100 );
+
+ if ((l_def_CHAN0_OR_1 == literal_1))
+ {
+ l_scom_buffer.insert<22, 3, 61, uint64_t>(literal_0b010 );
+ }
+ else if ((l_def_CHAN0_OR_1 == literal_0))
+ {
+ l_scom_buffer.insert<22, 3, 61, uint64_t>(literal_0b000 );
+ }
+
+ if ((l_def_CHAN0_OR_1 == literal_0))
+ {
+ l_scom_buffer.insert<25, 3, 61, uint64_t>(literal_0b010 );
+ }
+ else if ((l_def_CHAN0_OR_1 == literal_1))
+ {
+ l_scom_buffer.insert<25, 3, 61, uint64_t>(literal_0b000 );
+ }
+
FAPI_TRY(fapi2::putScom(TGT0, 0x501081cull, l_scom_buffer));
}
diff --git a/src/import/chips/p9/procedures/xml/attribute_info/chip_ec_attributes.xml b/src/import/chips/p9/procedures/xml/attribute_info/chip_ec_attributes.xml
index 5c2160bc6..d55877da8 100644
--- a/src/import/chips/p9/procedures/xml/attribute_info/chip_ec_attributes.xml
+++ b/src/import/chips/p9/procedures/xml/attribute_info/chip_ec_attributes.xml
@@ -7849,6 +7849,25 @@
</attribute>
<!-- ******************************************************************** -->
<attribute>
+ <id>ATTR_CHIP_EC_FEATURE_HW467590</id>
+ <targetType>TARGET_TYPE_PROC_CHIP</targetType>
+ <description>
+ Enable MC WAT to inject stalls into Read Queue when Atomic Read Modify Write
+ Fetch operations request read buffer access. This produces a gap to allow the
+ operation to complete.
+ </description>
+ <chipEcFeature>
+ <chip>
+ <name>ENUM_ATTR_NAME_CUMULUS</name>
+ <ec>
+ <value>0x10</value>
+ <test>GREATER_THAN_OR_EQUAL</test>
+ </ec>
+ </chip>
+ </chipEcFeature>
+ </attribute>
+ <!-- ******************************************************************** -->
+ <attribute>
<id>ATTR_CHIP_EC_FEATURE_HW461448</id>
<targetType>TARGET_TYPE_PROC_CHIP</targetType>
<description>
OpenPOWER on IntegriCloud