diff options
author | Patrick Williams <iawillia@us.ibm.com> | 2013-12-02 15:42:00 -0600 |
---|---|---|
committer | A. Patrick Williams III <iawillia@us.ibm.com> | 2013-12-09 13:35:42 -0600 |
commit | 1249f09a980679936b5f67b6f90baec50a3b1e19 (patch) | |
tree | 0c058618e04d6277f1ce43e6702b35529462e2a2 /src/include | |
parent | 10d410189691f5d4107d5c7d2a0af9332204e634 (diff) | |
download | talos-hostboot-1249f09a980679936b5f67b6f90baec50a3b1e19.tar.gz talos-hostboot-1249f09a980679936b5f67b6f90baec50a3b1e19.zip |
Force TIs for unhandled exceptions
Change-Id: I743687d7072af303e62d638a7ee5ad6f89afbccb
RTC: 89403
Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/7484
Tested-by: Jenkins Server
Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/arch/ppc.H | 17 | ||||
-rw-r--r-- | src/include/kernel/hbterminatetypes.H | 1 | ||||
-rw-r--r-- | src/include/kernel/kernel_reasoncodes.H | 1 |
3 files changed, 19 insertions, 0 deletions
diff --git a/src/include/arch/ppc.H b/src/include/arch/ppc.H index cb21f5b24..9914453a7 100644 --- a/src/include/arch/ppc.H +++ b/src/include/arch/ppc.H @@ -103,6 +103,23 @@ inline uint64_t getPIR() } ALWAYS_INLINE +inline uint64_t getSPRG2() +{ + register uint64_t sprg2 = 0; + asm volatile("mfsprg2 %0" : "=r" (sprg2)); + return sprg2; +} + +ALWAYS_INLINE +inline void setSPRG2(uint64_t _sprg2) +{ + register uint64_t sprg2 = _sprg2; + asm volatile("mtsprg2 %0" : : "r" (sprg2)); + return; +} + + +ALWAYS_INLINE inline uint64_t getSPRG3() { register uint64_t sprg3 = 0; diff --git a/src/include/kernel/hbterminatetypes.H b/src/include/kernel/hbterminatetypes.H index 0cd1cce0a..85e8eb9fd 100644 --- a/src/include/kernel/hbterminatetypes.H +++ b/src/include/kernel/hbterminatetypes.H @@ -104,6 +104,7 @@ enum hb_terminate_source TI_KERNEL_ASSERT = 0x0001, TI_CRIT_ASSERT = 0x0002, TI_SHUTDOWN = 0x0003, + TI_UNHANDLED_EX = 0x0004, }; diff --git a/src/include/kernel/kernel_reasoncodes.H b/src/include/kernel/kernel_reasoncodes.H index f76d0993b..6cab81be3 100644 --- a/src/include/kernel/kernel_reasoncodes.H +++ b/src/include/kernel/kernel_reasoncodes.H @@ -41,6 +41,7 @@ // without a MODULE ID. RC_ASSERT = KERNEL_COMP_ID | 0x01, /**< Assert */ RC_SHUTDOWN = KERNEL_COMP_ID | 0x02, /**< Shutdown */ + RC_UNHANDLED_EX = KERNEL_COMP_ID | 0x03, /**< Unhandled Except. */ }; #endif |