summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndres Lugo-Reyes <aalugore@us.ibm.com>2017-06-22 14:21:15 -0500
committerMartha Broyles <mbroyles@us.ibm.com>2017-06-28 11:53:40 -0400
commit62895c54c09a699527d9c5089d84ccb150a33df5 (patch)
treecdbf7180cf5c1032a94fa34251de1578ed67df14 /src
parent2f3dd9e14af82d8c7bcc0f154d6fc06fa96d279a (diff)
downloadtalos-occ-62895c54c09a699527d9c5089d84ccb150a33df5.tar.gz
talos-occ-62895c54c09a699527d9c5089d84ccb150a33df5.zip
error TODO clean up
Change-Id: I13f37c944fdd222a029f83dbbb8a9d2db00961c2 RTC: 163364 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/42322 Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: William A. Bryan <wilbryan@us.ibm.com> Reviewed-by: Shawn M. McCarney <shawnmm@us.ibm.com> Reviewed-by: Martha Broyles <mbroyles@us.ibm.com>
Diffstat (limited to 'src')
-rwxr-xr-xsrc/occ_405/errl/errl.c89
-rwxr-xr-xsrc/occ_405/errl/test/errltest.c4
2 files changed, 8 insertions, 85 deletions
diff --git a/src/occ_405/errl/errl.c b/src/occ_405/errl/errl.c
index 8076163..4c9fe05 100755
--- a/src/occ_405/errl/errl.c
+++ b/src/occ_405/errl/errl.c
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER OnChipController Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2011,2016 */
+/* Contributors Listed Below - COPYRIGHT 2011,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -67,7 +67,6 @@ uint8_t G_error_history[ERR_HISTORY_SIZE] = {0};
extern uint8_t G_occ_interrupt_type;
extern bool G_fir_collection_required;
-void hexDumpLog( errlHndl_t i_log );
// Function Specification
//
@@ -293,6 +292,7 @@ errlHndl_t createErrl(
uint64_t l_time = 0;
uint8_t l_id = 0;
uint8_t l_errSlot = getErrSlotNumAndErrId( i_sev, &l_id, &l_time);
+ static uint8_t traceCount = 5;
if ( l_errSlot != ERRL_INVALID_SLOT )
@@ -338,8 +338,6 @@ errlHndl_t createErrl(
l_rc->iv_numCallouts = 0;
// save off occ fields
- //NOTE: Design does not exist for these fields
- //TODO: fix this when design is done!
l_rc->iv_userDetails.iv_fwLevel = 0;
l_rc->iv_userDetails.iv_occId = G_pbax_id.chip_id;
l_rc->iv_userDetails.iv_occRole = G_occ_role;
@@ -348,8 +346,11 @@ errlHndl_t createErrl(
}
else
{
- // TODO: put a threshold on this trace
- TRAC_INFO("Error Logs are FULL - Slot [%d]", l_errSlot);
+ if( traceCount > 0 )
+ {
+ TRAC_INFO("Error Logs are FULL - Slot [%d]", l_errSlot);
+ traceCount--;
+ }
}
return l_rc;
@@ -940,79 +941,3 @@ void setErrlActions(errlHndl_t io_err, const uint8_t i_mask)
}
}
-// TODO: Cleanup this function.
-// Function Specification
-//
-// Name: hexDumpLog
-//
-// Description: Hex Dump Log
-//
-// End Function Specification
-void hexDumpLog( errlHndl_t i_log )
-{
-#if 0
- uint32_t l_written = 0;
- uint32_t l_counter = 0;
- uint8_t * l_data = (uint8_t*) i_log;
- uint32_t l_len = i_log->iv_userDetails.iv_entrySize;
-
- while ( l_counter < l_len)
- {
- if (( i_log == NULL ) ||
- ( i_log == INVALID_ERR_HNDL ))
- {
- // break out if log is invalid
- // do nothing
- break;
- }
-
- printf("| %08X ", (uint32_t) l_data + l_counter);
-
- // Display 16 bytes in Hex with 2 spaces in between
- l_written = 0;
- uint8_t i = 0;
- for ( i = 0; i < 16 && l_counter < l_len; i++ )
- {
- l_written += printf("%02X",l_data[l_counter++]);
-
- if ( ! ( l_counter % 4 ) )
- {
- l_written += printf(" ");
- }
- }
-
- // Pad with spaces
- uint8_t l_space[64] = {0};
- memset( l_space, 0x00, sizeof( l_space ));
- memset( l_space, ' ', 43-l_written);
- printf("%s", l_space );
-
- // Display ASCII
- l_written = 0;
- uint8_t l_char;
- for ( ; i > 0 ; i-- )
- {
- l_char = l_data[ l_counter-i ];
-
- if ( isprint( l_char ) &&
- ( l_char != '&' ) &&
- ( l_char != '<' ) &&
- ( l_char != '>' )
- )
- {
- l_written += printf("%c",l_char );
- }
- else
- {
- l_written += printf("." );
- }
- }
-
- // Pad with spaces
- uint8_t l_space2[64] = {0};
- memset( l_space2, 0x00, sizeof( l_space2 ));
- memset( l_space2, ' ', 19-l_written);
- printf("%s|\n", l_space2 );
- }
-#endif
-}
diff --git a/src/occ_405/errl/test/errltest.c b/src/occ_405/errl/test/errltest.c
index 42e8fa3..9a35ae0 100755
--- a/src/occ_405/errl/test/errltest.c
+++ b/src/occ_405/errl/test/errltest.c
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER OnChipController Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2011,2015 */
+/* Contributors Listed Below - COPYRIGHT 2011,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -54,7 +54,6 @@ SsxTimer timer;
/// Our idle thread. See #main_thread_routine
SsxThread main_thread;
-/// TODO: Goes away due to device driver layer
SsxThread prcd_thread;
/*----------------------------------------------------------------------------*/
@@ -90,7 +89,6 @@ void pgp_validation_ssx_main_hook(void)
// Description:
//
// End Function Specification
-//TODO placeholder
void Cmd_Hndl_thread_routine(void *arg)
{
}
OpenPOWER on IntegriCloud