aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMahesh Salgaonkar <mahesh@linux.vnet.ibm.com>2019-03-04 22:36:20 +0530
committerStewart Smith <stewart@linux.ibm.com>2019-03-05 15:28:06 +1100
commit017da88b2d056ac60ae1c582fe41b4f609f17a0f (patch)
tree89de946ab55e0afd6997eaf9723b99752e86237b
parent52be9b85e45527cdf13084192beb378ff2466e99 (diff)
downloadskiboot-017da88b2d056ac60ae1c582fe41b4f609f17a0f.zip
skiboot-017da88b2d056ac60ae1c582fe41b4f609f17a0f.tar.gz
skiboot-017da88b2d056ac60ae1c582fe41b4f609f17a0f.tar.bz2
opal/hmi: Fix double unlock of hmi lock in failure path.
unlock once and goto error_out. Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
-rw-r--r--core/hmi.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/core/hmi.c b/core/hmi.c
index c01a2c3..7094b4c 100644
--- a/core/hmi.c
+++ b/core/hmi.c
@@ -1042,13 +1042,9 @@ static int handle_all_core_tfac_error(uint64_t tfmr, uint64_t *out_flags)
if (!recover_corrupt_tfmr()) {
unlock(&hmi_lock);
recover = 0;
+ goto error_out;
}
- if (!recover) {
- unlock(&hmi_lock);
- goto error_out;
- }
-
tfmr = mfspr(SPR_TFMR);
/* We could have got new thread errors in the meantime */