aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2017-04-13 17:43:32 +1000
committerMichael Neuling <mikey@neuling.org>2017-04-19 14:45:09 +1000
commitf257a053df54e2b05c841ee74a1a553143fb67d7 (patch)
treeddfeb4c871b392d290a675457e9c15bc2ffc3cba /hw
parent7184ed2d281aefb010109068bb7d2b91b30047c7 (diff)
downloadskiboot-f257a053df54e2b05c841ee74a1a553143fb67d7.zip
skiboot-f257a053df54e2b05c841ee74a1a553143fb67d7.tar.gz
skiboot-f257a053df54e2b05c841ee74a1a553143fb67d7.tar.bz2
xive: Clear emulation mode queue on reset
When resetting, we need to clear the emulation mode queue for each CPU, otherwise it may contain "stale" interrupts causing the OS to go completely out of sync. This fixes problems doing kexecs from emulation to native back to emulation. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Michael Neuling <mikey@neuling.org>
Diffstat (limited to 'hw')
-rw-r--r--hw/xive.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/xive.c b/hw/xive.c
index d76f4cf..530e0df 100644
--- a/hw/xive.c
+++ b/hw/xive.c
@@ -2873,6 +2873,7 @@ static void xive_init_cpu_emulation(struct xive_cpu_state *xs,
xs->eqbuf = xive_get_eq_buf(xs->vp_blk,
xs->eq_idx + XIVE_EMULATION_PRIO);
assert(xs->eqbuf);
+ memset(xs->eqbuf, 0, 0x10000);
xs->eqptr = 0;
xs->eqmsk = (0x10000/4) - 1;