make cursor position available to payloads

Signed-off-by: Stefan Reinauer <stepan@coresystems.de>


Index: include/libpayload.h
===================================================================
--- include/libpayload.h	(revision 425)
+++ include/libpayload.h	(working copy)
@@ -123,6 +123,7 @@
 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);
 
 /* drivers/option.c */
 int get_option(void *dest, char *name);
Index: drivers/video/video.c
===================================================================
--- drivers/video/video.c	(revision 425)
+++ drivers/video/video.c	(working copy)
@@ -140,6 +140,12 @@
 	video_console_fixup_cursor();
 }
 
+void video_console_get_cursor(unsigned int *x, unsigned int *y, unsigned int *en)
+{
+	if (console->get_cursor)
+		console->get_cursor(&cursorx, &cursory, &cursor_enabled);
+}
+
 int video_console_init(void)
 {
 		int i;
