diff options
author | Sven Schnelle <svens@stackframe.org> | 2012-07-26 14:31:40 +0200 |
---|---|---|
committer | Patrick Georgi <patrick@georgi-clan.de> | 2012-07-26 15:52:00 +0200 |
commit | 82704c63b98202fe2a24032697369cd190202d3f (patch) | |
tree | e1893f92423bd4e4c111fb57fe54429327dbf9cb /src/console | |
parent | 0b7b7b6334de592b82d36ee47bc25b1b72043681 (diff) | |
download | coreboot-82704c63b98202fe2a24032697369cd190202d3f.tar.xz |
USBDEBUG: buffer up to 8 bytes
EHCI debug allows to send message with 8 bytes length, but
we're only sending one byte in each transaction. Buffer up
to 8 bytes to speed up debug output.
Change-Id: I9dbb406833c4966c3afbd610e1b13a8fa3d62f39
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/1357
Tested-by: build bot (Jenkins)
Reviewed-by: Nico Huber <nico.huber@secunet.com>
Diffstat (limited to 'src/console')
-rw-r--r-- | src/console/usbdebug_console.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/console/usbdebug_console.c b/src/console/usbdebug_console.c index a624b9dd21..58a62b8e94 100644 --- a/src/console/usbdebug_console.c +++ b/src/console/usbdebug_console.c @@ -55,8 +55,7 @@ static void dbgp_init(void) static void dbgp_tx_byte(unsigned char data) { - if (dbg_info.ehci_debug) - dbgp_bulk_write_x(&dbg_info, (char*)&data, 1); + usbdebug_tx_byte(&dbg_info, data); } static unsigned char dbgp_rx_byte(void) @@ -69,6 +68,11 @@ static unsigned char dbgp_rx_byte(void) return data; } +static void dbgp_tx_flush(void) +{ + usbdebug_tx_flush(&dbg_info); +} + static int dbgp_tst_byte(void) { return (int)dbg_info.ehci_debug; @@ -77,6 +81,7 @@ static int dbgp_tst_byte(void) static const struct console_driver usbdebug_direct_console __console = { .init = dbgp_init, .tx_byte = dbgp_tx_byte, + .tx_flush = dbgp_tx_flush, .rx_byte = dbgp_rx_byte, .tst_byte = dbgp_tst_byte, }; |