summaryrefslogtreecommitdiff
path: root/include/keyboard.h
diff options
context:
space:
mode:
authorDavid Hendricks <dhendrix@chromium.org>2012-02-07 14:30:03 -0800
committerDavid Hendricks <dhendrix@chromium.org>2012-02-15 18:20:28 -0800
commit05f0eb3005934c1d6593066555e175d96148953f (patch)
tree497561547560be70e16e185db24d8e32d2a89d7e /include/keyboard.h
parent30fc5d72849de5fc791db06b432969096f76469c (diff)
downloadchrome-ec-05f0eb3005934c1d6593066555e175d96148953f.tar.gz
Make i8042 independent of host <--> KBC bus.
This CL attempts to abstract underlying bus from i8042 code. Nearly all i8042 logic is isolated already. This patch is intended to allow us to use i8042 logic for processing keys and commands on boards which do not necessarily use LPC as the host <--> KBC bus interface. This CL does the following: - Define KBC bus <--> host (kbc_host_bus) on a per-board basis in board.c. - Add generic wrappers in place of lpc_keyboard_* in i8042 code. - Define the behavior of generic wrappers in EC-specific keyboard sources. If board.c specifies LPC, then send via LPC. TODO: This needs to be tested on real hardware... Signed-off-by: David Hendricks <dhendrix@chromium.org> BUG=None TEST=Locally compiled for Link, BDS and Discovery. Change-Id: I9cabd514bd44fd6b508c26994eccc3011eedbc0f
Diffstat (limited to 'include/keyboard.h')
-rw-r--r--include/keyboard.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/keyboard.h b/include/keyboard.h
index b00ebfe05e..f715ab2bba 100644
--- a/include/keyboard.h
+++ b/include/keyboard.h
@@ -95,5 +95,10 @@ enum ec_error_list keyboard_register_callback(keyboard_callback cb);
*/
enum ec_error_list keyboard_get_state(uint8_t *bit_array);
+/* Return true if the TOH is still set */
+extern int keyboard_has_char(void);
+
+extern void keyboard_put_char(uint8_t chr, int send_irq);
+
#endif /* __INCLUDE_KEYBOARD_H */