aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVasant Hegde <hegdevasant@linux.vnet.ibm.com>2016-07-02 21:03:41 +0530
committerStewart Smith <stewart@linux.vnet.ibm.com>2016-07-21 16:52:08 +1000
commit6fe711278074a6c7380eca0101a9cebda1b85419 (patch)
tree9fa429ec4dd685080176c6c9930c513e6854e92c
parent71eb483122eb5ec0ef6e845d3ccf3a2a90f35e65 (diff)
downloadskiboot-6fe711278074a6c7380eca0101a9cebda1b85419.zip
skiboot-6fe711278074a6c7380eca0101a9cebda1b85419.tar.gz
skiboot-6fe711278074a6c7380eca0101a9cebda1b85419.tar.bz2
FSP/ELOG: Disable event notification if list is not consistent
Chances of elog_read_pending inconsistent state is very very less. Just to be on safer side, disable notification if list is not in consistent state. Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com> Reviewed-by: Mukesh Ojha <mukesh02@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com> (cherry picked from commit 1fb10de164d3ca034193df81c1f5d007aec37781) Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r--hw/fsp/fsp-elog-read.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/fsp/fsp-elog-read.c b/hw/fsp/fsp-elog-read.c
index 5814aab..135dfe7 100644
--- a/hw/fsp/fsp-elog-read.c
+++ b/hw/fsp/fsp-elog-read.c
@@ -299,6 +299,7 @@ static int64_t fsp_opal_elog_info(uint64_t *opal_elog_id,
if (!log_data) {
prlog(PR_ERR, "%s: Inconsistent internal list state !\n",
__func__);
+ fsp_elog_set_head_state(ELOG_STATE_NONE);
unlock(&elog_read_lock);
return OPAL_WRONG_STATE;
}
@@ -334,6 +335,7 @@ static int64_t fsp_opal_elog_read(uint64_t *buffer, uint64_t opal_elog_size,
if (!log_data) {
prlog(PR_ERR, "%s: Inconsistent internal list state !\n",
__func__);
+ fsp_elog_set_head_state(ELOG_STATE_NONE);
unlock(&elog_read_lock);
return OPAL_WRONG_STATE;
}