From e75c3d85a35f0c42fef1621ca76eb085b6ae5a94 Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Fri, 26 Sep 2008 18:36:26 +0000 Subject: * factor out serial hardware init * add reverse color support for serial * add cursor enable/disable support for serial * fix tinycurses compilation if serial is disabled * add functions to query whether serial or vga console is enabled in tinycurses * initialize uninitialized COLOR_PAIRS variable * implement has_colors(), wredrawln() functions in curses Signed-off-by: Stefan Reinauer Acked-by: Jordan Crouse git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3604 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- payloads/libpayload/include/curses.h | 3 +++ payloads/libpayload/include/libpayload.h | 4 ++++ 2 files changed, 7 insertions(+) (limited to 'payloads/libpayload/include') diff --git a/payloads/libpayload/include/curses.h b/payloads/libpayload/include/curses.h index 993bb3c962..6c9307a598 100644 --- a/payloads/libpayload/include/curses.h +++ b/payloads/libpayload/include/curses.h @@ -1673,4 +1673,7 @@ extern NCURSES_EXPORT(const char *) _nc_visbuf (const char *); void curses_enable_vga(int); void curses_enable_serial(int); +int curses_vga_enabled(void); +int curses_serial_enabled(void); + #endif /* _CURSES_H */ diff --git a/payloads/libpayload/include/libpayload.h b/payloads/libpayload/include/libpayload.h index 7af19dee06..6a4db0e051 100644 --- a/payloads/libpayload/include/libpayload.h +++ b/payloads/libpayload/include/libpayload.h @@ -131,15 +131,19 @@ int keyboard_getchar(void); * @{ */ void serial_init(void); +void serial_hardware_init(int port, int speed, int word_bits, int parity, int stop_bits); void serial_putchar(unsigned char c); int serial_havechar(void); int serial_getchar(void); void serial_clear(void); void serial_start_bold(void); void serial_end_bold(void); +void serial_start_reverse(void); +void serial_end_reverse(void); void serial_start_altcharset(void); void serial_end_altcharset(void); void serial_set_color(short fg, short bg); +void serial_cursor_enable(int state); void serial_set_cursor(int y, int x); /** @} */ -- cgit v1.2.3