From 7fe0933c5898e5cce70407184fd458cf3ad9ee32 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Sun, 18 Oct 2015 21:17:18 -0600 Subject: video: Drop unused console functions CONFIG_CONSOLE_CURSOR, CONFIG_SYS_CONSOLE_BLINK_COUNT and CONFIG_CONSOLE_TIME are not used by any board. The implementation is not great and stands in the way of a refactor of i8042. Drop these for now. They can be re-introduced quite easily later, perhaps with driver-model real-time-clock (RTC) support. When reintroducing, it might be useful to make a few changes: - Blink time would be more useful than blink count - The confusing #ifdefs should be avoided - The time functions should support driver model - It would be best keyed off console_tstc() or some similar idle loop rather than a particular input driver (i8042 in this case) Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- drivers/input/i8042.c | 23 ----------------------- 1 file changed, 23 deletions(-) (limited to 'drivers/input/i8042.c') diff --git a/drivers/input/i8042.c b/drivers/input/i8042.c index 9b5fa32666..7b95b21f8a 100644 --- a/drivers/input/i8042.c +++ b/drivers/input/i8042.c @@ -17,12 +17,6 @@ #define in8(p) inb(p) #define out8(p, v) outb(v, p) -#ifdef CONFIG_CONSOLE_CURSOR -extern void console_cursor(int state); -static int blink_count = CONFIG_SYS_CONSOLE_BLINK_COUNT; -static int cursor_state; -#endif - /* locals */ static int kbd_input = -1; /* no input yet */ @@ -598,15 +592,6 @@ int i8042_tstc(struct stdio_dev *dev) { unsigned char scan_code = 0; -#ifdef CONFIG_CONSOLE_CURSOR - if (--blink_count == 0) { - cursor_state ^= 1; - console_cursor(cursor_state); - blink_count = CONFIG_SYS_CONSOLE_BLINK_COUNT; - udelay(10); - } -#endif - if ((in8(I8042_STS_REG) & STATUS_OBF) == 0) { return 0; } else { @@ -635,14 +620,6 @@ int i8042_getc(struct stdio_dev *dev) while (kbd_input == -1) { while ((in8(I8042_STS_REG) & STATUS_OBF) == 0) { -#ifdef CONFIG_CONSOLE_CURSOR - if (--blink_count == 0) { - cursor_state ^= 1; - console_cursor(cursor_state); - blink_count = CONFIG_SYS_CONSOLE_BLINK_COUNT; - } - udelay(10); -#endif } scan_code = in8(I8042_DATA_REG); if (scan_code != 0xfa) -- cgit v1.2.1