aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMahesh Salgaonkar <mahesh@linux.vnet.ibm.com>2019-04-16 14:59:28 +0530
committeroohal <oohal@users.noreply.github.com>2019-05-09 17:05:56 +1000
commiteedb012b66a6b37adb99bc0e54eb9bac0c4d9468 (patch)
treea0e94e2d775d2b267fa68c756e679ee9cf9a89f0
parent365da17acd186562e6b90c41a948ed88bde0e5e5 (diff)
downloadskiboot-eedb012b66a6b37adb99bc0e54eb9bac0c4d9468.zip
skiboot-eedb012b66a6b37adb99bc0e54eb9bac0c4d9468.tar.gz
skiboot-eedb012b66a6b37adb99bc0e54eb9bac0c4d9468.tar.bz2
opal/hmi: Initialize the hmi event with old value of TFMR.
[ Upstream commit 5f339b4b5d805d8d6bb50e11674dca01255402b4 ] Do this before we fix TFAC errors. Otherwise the event at host console shows no thread error reported in TFMR register. Without this patch the console event show TFMR with no thread error: (DEC parity error TFMR[59] injection) [ 53.737572] Severe Hypervisor Maintenance interrupt [Recovered] [ 53.737596] Error detail: Timer facility experienced an error [ 53.737611] HMER: 0840000000000000 [ 53.737621] TFMR: 3212000870e04000 After this patch it shows old TFMR value on host console: [ 2302.267271] Severe Hypervisor Maintenance interrupt [Recovered] [ 2302.267305] Error detail: Timer facility experienced an error [ 2302.267320] HMER: 0840000000000000 [ 2302.267330] TFMR: 3212000870e14010 Fixes: 674f7696f ("opal/hmi: Rework HMI handling of TFAC errors") Cc: skiboot-stable@lists.ozlabs.org Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com> Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
-rw-r--r--core/hmi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/hmi.c b/core/hmi.c
index c01a2c3..ee493f0 100644
--- a/core/hmi.c
+++ b/core/hmi.c
@@ -1160,6 +1160,9 @@ static int handle_tfac_errors(struct OpalHMIEvent *hmi_evt, uint64_t *out_flags)
int recover = -1;
uint64_t tfmr = mfspr(SPR_TFMR);
+ /* Initialize the hmi event with old value of TFMR */
+ hmi_evt->tfmr = tfmr;
+
/* A TFMR parity/corrupt error makes us ignore all the local stuff.*/
if (tfmr & SPR_TFMR_TFMR_CORRUPT) {
/* Mark TB as invalid for now as we don't trust TFMR, we'll fix
@@ -1220,7 +1223,6 @@ static int handle_tfac_errors(struct OpalHMIEvent *hmi_evt, uint64_t *out_flags)
if (recover != -1 && hmi_evt) {
hmi_evt->severity = OpalHMI_SEV_ERROR_SYNC;
hmi_evt->type = OpalHMI_ERROR_TFAC;
- hmi_evt->tfmr = tfmr;
queue_hmi_event(hmi_evt, recover, out_flags);
}