diff options
author | Neelesh Gupta <neelegup@linux.vnet.ibm.com> | 2014-10-25 23:33:52 +0530 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2014-10-27 18:13:41 +1100 |
commit | 2fe43d8776b19ff5896312c8bfef6a46156d0d48 (patch) | |
tree | 14c00d74019d94ae7ce7af1d79565cc6c0b18adc /hw/psi.c | |
parent | 531bdefda91102cb3240e4e3289900af0a50e78b (diff) | |
download | skiboot-2fe43d8776b19ff5896312c8bfef6a46156d0d48.zip skiboot-2fe43d8776b19ff5896312c8bfef6a46156d0d48.tar.gz skiboot-2fe43d8776b19ff5896312c8bfef6a46156d0d48.tar.bz2 |
hw/i2c: i2c driver infrastructure providing device I/O
This patch adds the generic i2c driver infrastructure to handle multiple i2c
master cores present in the system and exposes structures and interfaces for
the client to perform I/O on the i2c slave devices.
The driver adds the capability to queue multiple requests from client and
let clients notified asynchronously after completion. It does that by
handling the i2c interrupt or through OPAL poller in the absence of
interrupt.
Signed-off-by: Neelesh Gupta <neelegup@linux.vnet.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/psi.c')
-rw-r--r-- | hw/psi.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -27,6 +27,7 @@ #include <trace.h> #include <xscom.h> #include <chip.h> +#include <lpc.h> #include <timebase.h> #include <platform.h> @@ -280,7 +281,7 @@ static void handle_extra_interrupt(struct psi *psi) if (val & PSIHB_IRQ_STAT_FSI) printf("PSI: FSI irq received\n"); if (val & PSIHB_IRQ_STAT_LPC) - printf("PSI: LPC/I2C irq received\n"); + lpc_interrupt(); if (val & PSIHB_IRQ_STAT_LOCAL_ERR) printf("PSI: ATTN irq received\n"); if (val & PSIHB_IRQ_STAT_HOST_ERR) { |