From 068ca086af2312d56efe51a724d78d84e1339ab4 Mon Sep 17 00:00:00 2001 From: Anup Patel Date: Wed, 21 Apr 2021 18:03:50 +0530 Subject: lib: sbi: Simplify console platform operations Instead of having console_putc() and console_getc() callbacks in platform operations, it will be much simpler for console driver to directly register these operations as device to the sbi_console implementation. Signed-off-by: Anup Patel Reviewed-by: Alistair Francis Reviewed-by: Xiang W --- platform/template/platform.c | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'platform/template') diff --git a/platform/template/platform.c b/platform/template/platform.c index 5bdb186..fbbac30 100644 --- a/platform/template/platform.c +++ b/platform/template/platform.c @@ -63,23 +63,6 @@ static int platform_console_init(void) PLATFORM_UART_BAUDRATE, 0, 1); } -/* - * Write a character to the platform console output. - */ -static void platform_console_putc(char ch) -{ - /* Example if the generic UART8250 driver is used */ - uart8250_putc(ch); -} - -/* - * Read a character from the platform console input. - */ -static int platform_console_getc(void) -{ - return uart8250_getc(); -} - /* * Initialize the platform interrupt controller for current HART. */ @@ -198,8 +181,6 @@ static void platform_system_reset(u32 type, u32 reason) const struct sbi_platform_operations platform_ops = { .early_init = platform_early_init, .final_init = platform_final_init, - .console_putc = platform_console_putc, - .console_getc = platform_console_getc, .console_init = platform_console_init, .irqchip_init = platform_irqchip_init, .ipi_send = platform_ipi_send, -- cgit v1.2.3