From 9ef0de4bc37de91e2a9416e81cd30472dbbff40a Mon Sep 17 00:00:00 2001 From: Raul E Rangel Date: Thu, 27 Feb 2020 15:18:30 -0700 Subject: common/keyboard_8042: Add ability to send/receive AUX data * Added CHAN_AUX to CHAN enum. * Added two new types to kblog for AUX data. * Moved mouse methods to handle_mouse_data so they can respond on the AUX channel. * Call lpc_aux_put_char to put an AUX byte. * Added send_aux_data_to_host and send_aux_data_to_device to pipe data in and out of the 8042. CONFIG_8042_AUX must be set if the board implements these methods. BUG=b:145575366 BRANCH=none TEST=Verified I can see AUX data going in and out. Signed-off-by: Raul E Rangel Change-Id: Iea1fc315846a9f768a1d82e309ff0725d1d2a9c2 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2079695 Reviewed-by: Edward Hill --- include/keyboard_8042.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include/keyboard_8042.h') diff --git a/include/keyboard_8042.h b/include/keyboard_8042.h index a038e877d1..3c9e87897c 100644 --- a/include/keyboard_8042.h +++ b/include/keyboard_8042.h @@ -45,4 +45,18 @@ void keyboard_host_write(int data, int is_cmd); enum ec_error_list keyboard_scancode_callback(uint16_t *make_code, int8_t pressed); +/** + * Send aux response data to host. + * + * @param data Aux response to send to host. + */ +void send_aux_data_to_host(uint8_t data); + +/** + * Send aux data to device. + * + * @param data Aux data to send to device. + */ +void send_aux_data_to_device(uint8_t data); + #endif /* __CROS_EC_KEYBOARD_8042_H */ -- cgit v1.2.1