diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2017-03-09 11:45:36 +1100 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-03-09 13:36:35 +1100 |
commit | 790ad9fe07a1ba2b55293238e21872ea6d8c740a (patch) | |
tree | 75aeaafe9f38af57b245e42ab3e76b65647abc9d /hw | |
parent | b63cb7694379500ca3e5ef81d8ffc1b2f60f30f9 (diff) | |
download | skiboot-790ad9fe07a1ba2b55293238e21872ea6d8c740a.zip skiboot-790ad9fe07a1ba2b55293238e21872ea6d8c740a.tar.gz skiboot-790ad9fe07a1ba2b55293238e21872ea6d8c740a.tar.bz2 |
xive: Fix setting of OPAL_XIVE_IRQ_EOI_VIA_FW
This flag needs to be set when the original source has an EOI
callback. It indicates that the OS should call back into OPAL
to perform the EOI and is necessary for some LPC interrupts
on DD1. Without this, Linux with XIVE exploitation hangs at
boot with a stuck interrupt.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/xive.c | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -3268,15 +3268,20 @@ static int64_t opal_xive_get_irq_info(uint32_t girq, return OPAL_PARAMETER; assert(is->ops == &xive_irq_source_ops); - *out_flags = xive_convert_irq_flags(s->flags); + if (out_flags) + *out_flags = xive_convert_irq_flags(s->flags); /* * If the orig source has a set_xive callback, then set * OPAL_XIVE_IRQ_MASK_VIA_FW as masking/unmasking requires - * source specific workarounds. + * source specific workarounds. Same with EOI. */ - if (out_flags && s->orig_ops && s->orig_ops->set_xive) - *out_flags |= OPAL_XIVE_IRQ_MASK_VIA_FW; + if (out_flags && s->orig_ops) { + if (s->orig_ops->set_xive) + *out_flags |= OPAL_XIVE_IRQ_MASK_VIA_FW; + if (s->orig_ops->eoi) + *out_flags |= OPAL_XIVE_IRQ_EOI_VIA_FW; + } idx = girq - s->esb_base; |