diff options
author | Dean Sanner <dsanner@us.ibm.com> | 2017-01-26 07:47:34 -0600 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2017-02-07 12:00:08 -0500 |
commit | eb217e512338e8d2182762cbe97f55d4759e799e (patch) | |
tree | d550bb52cec837d26e172237c8082fd099ec2373 /src/usr/sbeio/sbe_fifodd.C | |
parent | 606659144d3bf5d397bc24a54c6a5538e34cc5c5 (diff) | |
download | talos-hostboot-eb217e512338e8d2182762cbe97f55d4759e799e.tar.gz talos-hostboot-eb217e512338e8d2182762cbe97f55d4759e799e.zip |
Ensure sbefifo is clean on slave chips before starting
Change-Id: I440d6f5bd6aa1c3c72b3d8df581262b01765214c
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/35447
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Reviewed-by: Prachi Gupta <pragupta@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com>
Diffstat (limited to 'src/usr/sbeio/sbe_fifodd.C')
-rw-r--r-- | src/usr/sbeio/sbe_fifodd.C | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/src/usr/sbeio/sbe_fifodd.C b/src/usr/sbeio/sbe_fifodd.C index fae31ec5d..03d2cfba3 100644 --- a/src/usr/sbeio/sbe_fifodd.C +++ b/src/usr/sbeio/sbe_fifodd.C @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2012,2016 */ +/* Contributors Listed Below - COPYRIGHT 2012,2017 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -158,6 +158,30 @@ errlHndl_t SbeFifo::performFifoChipOp(TARGETING::Target * i_target, /** + * @brief perform SBE FIFO Reset + */ +errlHndl_t SbeFifo::performFifoReset(TARGETING::Target * i_target) +{ + errlHndl_t errl = NULL; + static mutex_t l_fifoOpMux = MUTEX_INITIALIZER; + + SBE_TRACF(ENTER_MRK "sending FSI SBEFIFO Reset to HUID 0x%x", + TARGETING::get_huid(i_target)); + + //Serialize access to the FIFO + mutex_lock(&l_fifoOpMux); + + // Perform a write to the DNFIFO Reset to cleanup the fifo + uint32_t l_dummy = 0xDEAD; + errl = writeFsi(i_target,SBE_FIFO_DNFIFO_RESET,&l_dummy); + + mutex_unlock(&l_fifoOpMux); + + return errl; +} + + +/** * @brief write FIFO request message */ errlHndl_t SbeFifo::writeRequest(TARGETING::Target * i_target, |