drivers: net: rsi_91x: 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>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Allen Pais 2017-09-21 22:34:32 +05:30 committed by David S. Miller
parent 1e153e554f
commit 531f3ce953
1 changed files with 2 additions and 3 deletions

View File

@ -411,9 +411,8 @@ static void bl_cmd_timeout(unsigned long priv)
static int bl_start_cmd_timer(struct rsi_hw *adapter, u32 timeout)
{
init_timer(&adapter->bl_cmd_timer);
adapter->bl_cmd_timer.data = (unsigned long)adapter;
adapter->bl_cmd_timer.function = (void *)&bl_cmd_timeout;
setup_timer(&adapter->bl_cmd_timer, (void *)&bl_cmd_timeout,
(unsigned long)adapter);
adapter->bl_cmd_timer.expires = (msecs_to_jiffies(timeout) + jiffies);
adapter->blcmd_timer_expired = false;