From 6f93bd233e0f1ffddc7b97cb4be83a944d4483d1 Mon Sep 17 00:00:00 2001 From: Dan Crowell Date: Mon, 13 Feb 2017 22:46:45 -0600 Subject: XSCOM/LPC Workaround for Nimbus DD1 There is a shared resource between the XSCOM and LPC logic that leads to errors at the XSCOM level causing errors to be detected during LPC operations. This commit adds an external interface to access block LPC operations while an XSCOM operation is in flight. Change-Id: I571094dfb666aa9198fabec5280a0f45c62c90ba RTC: 167291 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/36399 Tested-by: Jenkins Server Tested-by: Jenkins OP Build CI Tested-by: FSP CI Jenkins Reviewed-by: Thi N. Tran Reviewed-by: Dean Sanner Reviewed-by: Daniel M. Crowell --- src/usr/lpc/lpcdd.H | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'src/usr/lpc/lpcdd.H') diff --git a/src/usr/lpc/lpcdd.H b/src/usr/lpc/lpcdd.H index 1b4e3c5bd..f4bd04176 100644 --- a/src/usr/lpc/lpcdd.H +++ b/src/usr/lpc/lpcdd.H @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2014,2016 */ +/* Contributors Listed Below - COPYRIGHT 2014,2017 */ /* [+] Google Inc. */ /* [+] International Business Machines Corp. */ /* */ @@ -131,6 +131,19 @@ class LpcDD iv_lpcBaseAddr = reinterpret_cast(i_baseLPCAddr); }; + /** + * @brief Block/unblock all LPC operations + * @param[in] i_block true: block ops, false: allow ops + */ + void lock( bool i_block ) + { + if( i_block ) { + mutex_lock(ivp_mutex); + } else { + mutex_unlock(ivp_mutex); + } + }; + /** * @brief Constructor * @param[in] Processor target associated with the ECCB logic -- cgit v1.2.1