We change the position of fintek_8250_set_irq_mode() above the find_base_port() to eliminate the prototype define. Signed-off-by: Ji-Ze Hong (Peter Hong) <hpeter+linux_kernel@xxxxxxxxx> --- drivers/tty/serial/8250/8250_fintek.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/drivers/tty/serial/8250/8250_fintek.c b/drivers/tty/serial/8250/8250_fintek.c index 5625203..921f742 100644 --- a/drivers/tty/serial/8250/8250_fintek.c +++ b/drivers/tty/serial/8250/8250_fintek.c @@ -56,9 +56,6 @@ struct fintek_8250 { u8 key; }; -static void fintek_8250_set_irq_mode(struct fintek_8250 *pdata, - bool level_mode); - static u8 sio_read_reg(struct fintek_8250 *pdata, u8 reg) { outb(reg, pdata->base_port + ADDR_PORT); @@ -179,6 +176,14 @@ static void fintek_8250_set_max_fifo(struct fintek_8250 *pdata) } } +static void fintek_8250_set_irq_mode(struct fintek_8250 *pdata, bool is_level) +{ + sio_write_reg(pdata, LDN, pdata->index); + sio_write_mask_reg(pdata, FINTEK_IRQ_MODE, IRQ_SHARE, IRQ_SHARE); + sio_write_mask_reg(pdata, FINTEK_IRQ_MODE, IRQ_MODE_MASK, + is_level ? IRQ_LEVEL_LOW : IRQ_EDGE_HIGH); +} + static int find_base_port(struct fintek_8250 *pdata, u16 io_address, unsigned int irq) { @@ -230,14 +235,6 @@ static int find_base_port(struct fintek_8250 *pdata, u16 io_address, return -ENODEV; } -static void fintek_8250_set_irq_mode(struct fintek_8250 *pdata, bool is_level) -{ - sio_write_reg(pdata, LDN, pdata->index); - sio_write_mask_reg(pdata, FINTEK_IRQ_MODE, IRQ_SHARE, IRQ_SHARE); - sio_write_mask_reg(pdata, FINTEK_IRQ_MODE, IRQ_MODE_MASK, - is_level ? IRQ_LEVEL_LOW : IRQ_EDGE_HIGH); -} - int fintek_8250_probe(struct uart_8250_port *uart) { struct fintek_8250 *pdata; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-serial" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html