Author: stepan
Date: 2008-08-19 19:44:49 +0200 (Tue, 19 Aug 2008)
New Revision: 3520

Modified:
   trunk/payloads/libpayload/drivers/video/video.c
   trunk/payloads/libpayload/include/libpayload.h
Log:
add functions to query cursor position to video layer

Signed-off-by: Stefan Reinauer <[EMAIL PROTECTED]>
Acked-by: Jordan Crouse <[EMAIL PROTECTED]>


Modified: trunk/payloads/libpayload/drivers/video/video.c
===================================================================
--- trunk/payloads/libpayload/drivers/video/video.c     2008-08-19 16:55:05 UTC 
(rev 3519)
+++ trunk/payloads/libpayload/drivers/video/video.c     2008-08-19 17:44:49 UTC 
(rev 3520)
@@ -141,6 +141,26 @@
        video_console_fixup_cursor();
 }
 
+void video_console_get_cursor(unsigned int *x, unsigned int *y, unsigned int 
*en)
+{
+       *x=0;
+       *y=0;
+       *en=0;
+
+       if (console->get_cursor)
+               console->get_cursor(x, y, en);
+
+       *x = cursorx;
+       *y = cursory;
+}
+
+void video_console_set_cursor(unsigned int x, unsigned int y)
+{
+       cursorx = x;
+       cursory = y;
+       video_console_fixup_cursor();
+}
+
 int video_console_init(void)
 {
                int i;

Modified: trunk/payloads/libpayload/include/libpayload.h
===================================================================
--- trunk/payloads/libpayload/include/libpayload.h      2008-08-19 16:55:05 UTC 
(rev 3519)
+++ trunk/payloads/libpayload/include/libpayload.h      2008-08-19 17:44:49 UTC 
(rev 3520)
@@ -120,7 +120,12 @@
 void video_console_putc(u8 row, u8 col, unsigned int ch);
 void video_console_clear(void);
 void video_console_cursor_enable(int state);
+void video_console_get_cursor(unsigned int *x, unsigned int *y, unsigned int 
*en);
+void video_console_set_cursor(unsigned int cursorx, unsigned int cursory);
 
+/* drivers/option.c */
+int get_option(void *dest, char *name);
+
 /* libc/console.c */
 void console_init(void);
 int putchar(int c);


--
coreboot mailing list
[email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to