Hello!

The attached patch fixes bold attribute and positioning in libpayload serial output. Compile tested against r3478 (latest non-broken libpayload+coreinfo) and runtime tested with coreinfo+coreboot-v3 in QEMU (serial output in xterm).

/ulf
Bugfixes to serial output functions: vt100 has bold with \e[1m,
upper left corner is (0,0) in curses, but (1,1) on the vt100.

Signed-off-by: Ulf Jordan <[EMAIL PROTECTED]>

Index: libpayload/drivers/serial.c
===================================================================
--- libpayload/drivers/serial.c (revision 3478)
+++ libpayload/drivers/serial.c (arbetskopia)
@@ -101,7 +101,7 @@
 /*  These are thinly veiled vt100 functions used by curses */
 
 #define VT100_CLEAR       "\e[H\e[J"
-#define VT100_SBOLD       "\e[7m"
+#define VT100_SBOLD       "\e[1m"
 #define VT100_EBOLD       "\e[m"
 #define VT100_CURSOR_ADDR "\e[%d;%dH"
 
@@ -129,6 +129,6 @@
 void serial_set_cursor(int y, int x)
 {
        char buffer[32];
-       snprintf(buffer, sizeof(buffer), VT100_CURSOR_ADDR, y, x);
+       snprintf(buffer, sizeof(buffer), VT100_CURSOR_ADDR, y + 1, x + 1);
        serial_putcmd(buffer);
 }
--
coreboot mailing list
[email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to