--- zzzz-none-000/linux-3.10.107/drivers/tty/serial/timbuart.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/tty/serial/timbuart.c 2021-02-04 17:41:59.000000000 +0000 @@ -162,7 +162,7 @@ dev_dbg(port->dev, "%s - leaving\n", __func__); } -void timbuart_handle_rx_port(struct uart_port *port, u32 isr, u32 *ier) +static void timbuart_handle_rx_port(struct uart_port *port, u32 isr, u32 *ier) { if (isr & RXFLAGS) { /* Some RX status is set */ @@ -184,7 +184,7 @@ dev_dbg(port->dev, "%s - leaving\n", __func__); } -void timbuart_tasklet(unsigned long arg) +static void timbuart_tasklet(unsigned long arg) { struct timbuart_port *uart = (struct timbuart_port *)arg; u32 isr, ier = 0; @@ -244,11 +244,6 @@ *ier |= CTS_DELTA; } -static void timbuart_enable_ms(struct uart_port *port) -{ - /* N/A */ -} - static void timbuart_break_ctl(struct uart_port *port, int ctl) { /* N/A */ @@ -278,6 +273,8 @@ dev_dbg(port->dev, "%s\n", __func__); free_irq(port->irq, uart); iowrite32(0, port->membase + TIMBUART_IER); + + timbuart_flush_buffer(port); } static int get_bindex(int baud) @@ -405,7 +402,6 @@ .start_tx = timbuart_start_tx, .flush_buffer = timbuart_flush_buffer, .stop_rx = timbuart_stop_rx, - .enable_ms = timbuart_enable_ms, .break_ctl = timbuart_break_ctl, .startup = timbuart_startup, .shutdown = timbuart_shutdown, @@ -507,7 +503,6 @@ static struct platform_driver timbuart_platform_driver = { .driver = { .name = "timb-uart", - .owner = THIS_MODULE, }, .probe = timbuart_probe, .remove = timbuart_remove,