aboutsummaryrefslogtreecommitdiff
path: root/payloads/libpayload/include/libpayload.h
diff options
context:
space:
mode:
authorPatrick Rudolph <siro@das-labor.org>2017-03-01 19:07:37 +0100
committerPatrick Georgi <pgeorgi@google.com>2018-05-15 11:20:06 +0000
commite6a3821b97bdbe817646f3b151ace7d4471c2fab (patch)
treebcf50c147502e8421dcc2cb4e80b4822f1760348 /payloads/libpayload/include/libpayload.h
parent2b2f89565e1298ba9dad355d2de0c943a846acbb (diff)
libpayload-x86: Add common i8042 driver
Add a common i8042 driver that uses multiple overflowing fifos to seperate PS/2 port and PS/2 aux port. Required to support PC keyboard and PC mouse at the same time. Tested on Lenovo T500. Change-Id: I4ca803bfa3ed45111776eef1f4dccd3fab02ea39 Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-on: https://review.coreboot.org/18594 Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'payloads/libpayload/include/libpayload.h')
-rw-r--r--payloads/libpayload/include/libpayload.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/payloads/libpayload/include/libpayload.h b/payloads/libpayload/include/libpayload.h
index 43ecd05b02..96cc5f8165 100644
--- a/payloads/libpayload/include/libpayload.h
+++ b/payloads/libpayload/include/libpayload.h
@@ -179,6 +179,31 @@ u8 mouse_cursor_get_acceleration(void);
/** @} */
/**
+ * @defgroup i8042 controller functions
+ * @ingroup input
+ * @{
+ */
+size_t i8042_has_ps2(void);
+size_t i8042_has_aux(void);
+
+u8 i8042_probe(void);
+void i8042_close(void);
+
+int i8042_cmd(u8 cmd);
+void i8042_write_data(u8 data);
+
+u8 i8042_data_ready_ps2(void);
+u8 i8042_data_ready_aux(void);
+
+u8 i8042_read_data_ps2(void);
+u8 i8042_read_data_aux(void);
+
+int i8042_wait_read_ps2(void);
+int i8042_wait_read_aux(void);
+
+/** @} */
+
+/**
* @defgroup serial Serial functions
* @ingroup input
* @{