aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2017-02-03 20:51:58 +1100
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-02-07 14:16:03 +1100
commit7d252cdeb5f5f85d4a386859e0c87613162bcf31 (patch)
treeb0defc9d54750cdc509171eb2b5f3db3bc8bb77d /include
parentdcffe14d4075ac9e8bfce6eb1c53401630a6582f (diff)
downloadskiboot-7d252cdeb5f5f85d4a386859e0c87613162bcf31.zip
skiboot-7d252cdeb5f5f85d4a386859e0c87613162bcf31.tar.gz
skiboot-7d252cdeb5f5f85d4a386859e0c87613162bcf31.tar.bz2
xive/psi/lpc: Handle proper clearing of LPC SerIRQ latch on DD1
On DD1, the LPC SerIRQ are latched to 1 in HW but never back to 0, we need an explicit clear after running the handler. (Not before as they are level interrupts, they will be latched again if they are still pending). For now we do that in lpc_dispatch_ser_irqs() but that only works for interrupts routed to OPAL. In order to support routing LPC interrutps to Linux, we need a custom EOI handler that does the clearing of the latch before we do the EOI in the ESB. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'include')
-rw-r--r--include/lpc.h3
-rw-r--r--include/xive.h4
2 files changed, 7 insertions, 0 deletions
diff --git a/include/lpc.h b/include/lpc.h
index 59f0779..3e92d53 100644
--- a/include/lpc.h
+++ b/include/lpc.h
@@ -98,6 +98,9 @@ extern void lpc_register_client(uint32_t chip_id, const struct lpc_client *clt);
/* Manual control of routing on P9 for use by platforms if necessary */
extern void lpc_route_serirq(uint32_t chip_id, uint32_t sirq, uint32_t psi_idx);
+/* Clear SerIRQ latch on P9 DD1 */
+extern void lpc_p9_sirq_eoi(uint32_t chip_id, uint32_t index);
+
/* Default bus accessors */
extern int64_t lpc_write(enum OpalLPCAddressType addr_type, uint32_t addr,
uint32_t data, uint32_t sz);
diff --git a/include/xive.h b/include/xive.h
index e9a01c3..58c4da9 100644
--- a/include/xive.h
+++ b/include/xive.h
@@ -460,4 +460,8 @@ void xive_cpu_callin(struct cpu_thread *cpu);
*/
void *xive_get_trigger_port(uint32_t girq);
+/* To be used by special EOI override in PSI */
+struct irq_source;
+void __xive_source_eoi(struct irq_source *is, uint32_t isn);
+
#endif /* __XIVE_H__ */