diff options
author | Allen Pais <allen.lkml@gmail.com> | 2017-09-22 13:56:44 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-10-03 20:27:13 +0200 |
commit | 177b508f3c7694647e94509a1ef3f5a139deac50 (patch) | |
tree | 11ef1a44196f2222f94a57b1b870aa767d655051 /drivers/tty/serial | |
parent | a0983c742a5885f82afb282166f83f1d3d8addf4 (diff) |
drivers: tty: imx: use setup_timer() helper.
Use setup_timer function instead of initializing timer with the
function and data fields.
Signed-off-by: Allen Pais <allen.lkml@gmail.com>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial')
-rw-r--r-- | drivers/tty/serial/imx.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c index 19253a6e0b7e..20a83712329b 100644 --- a/drivers/tty/serial/imx.c +++ b/drivers/tty/serial/imx.c @@ -2118,9 +2118,7 @@ static int serial_imx_probe(struct platform_device *pdev) sport->port.rs485_config = imx_rs485_config; sport->port.rs485.flags |= SER_RS485_RTS_ON_SEND; sport->port.flags = UPF_BOOT_AUTOCONF; - init_timer(&sport->timer); - sport->timer.function = imx_timeout; - sport->timer.data = (unsigned long)sport; + setup_timer(&sport->timer, imx_timeout, (unsigned long)sport); sport->gpios = mctrl_gpio_init(&sport->port, 0); if (IS_ERR(sport->gpios)) |