diff options
author | Namyoon Woo <namyoon@chromium.org> | 2019-08-08 09:46:43 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-09-19 03:03:34 +0000 |
commit | 16d2b24ac05f7a5654bddcf9cb61f0f6684d1806 (patch) | |
tree | 6d20d184c6b3752376d4492bd925f367bf8ef87c /board | |
parent | 580a54658ad27550a1da5cd6077b901a12d447f2 (diff) | |
download | chrome-ec-16d2b24ac05f7a5654bddcf9cb61f0f6684d1806.tar.gz |
g: re-implement usb console with usb-stream configuration.
This patch introduces CONFIG_USB_CONSOLE_STREAM, which implements
usb-console with usb-stream configuration, intending to remove
code redundancy between the previous implementation (usb_console.c)
and usb_stream.c.
Flash usage decreases by 224 bytes, and RAM usage by 40 bytes.
BUG=b:138447451
BRANCH=cr50
TEST=Checked cr50 USB console and cr50 UART console respectively.
Key-in response and output are working well:
./util/uart_stress_tester.py /dev/ttyUSB0 -t 300 --debug
Change-Id: I305038e1db83dc49bb12a8afdbfcc2a8135d50f5
Signed-off-by: Namyoon Woo <namyoon@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1741302
Reviewed-by: Mary Ruthven <mruthven@chromium.org>
Diffstat (limited to 'board')
-rw-r--r-- | board/cr50/board.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/board/cr50/board.h b/board/cr50/board.h index 5a0dc1e330..130ac2320a 100644 --- a/board/cr50/board.h +++ b/board/cr50/board.h @@ -98,7 +98,9 @@ /* USB configuration */ #define CONFIG_USB -#define CONFIG_USB_CONSOLE +#define CONFIG_USB_CONSOLE_STREAM +#undef CONFIG_USB_CONSOLE_TX_BUF_SIZE +#define CONFIG_USB_CONSOLE_TX_BUF_SIZE 4096 #define CONFIG_USB_I2C #define CONFIG_USB_INHIBIT_INIT #define CONFIG_USB_SPI |