summaryrefslogtreecommitdiffstats
path: root/drivers/net/caif
diff options
context:
space:
mode:
authorAllen Pais <allen.lkml@gmail.com>2017-09-21 13:05:12 -0400
committerDavid S. Miller <davem@davemloft.net>2017-09-21 14:44:43 -0400
commit7890d5341999968b94dbdf9e30ad32f37f82ea10 (patch)
treec2b1c4e8089f24dd3a8f2f07af0c5a55d06b7c76 /drivers/net/caif
parent13e96b93ff5f1093592419e1f84962d4a266bd3e (diff)
drivers: net: caif: 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>
Diffstat (limited to 'drivers/net/caif')
-rw-r--r--drivers/net/caif/caif_hsi.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/drivers/net/caif/caif_hsi.c b/drivers/net/caif/caif_hsi.c
index 438966bf51c2..fed75e75207a 100644
--- a/drivers/net/caif/caif_hsi.c
+++ b/drivers/net/caif/caif_hsi.c
@@ -1211,17 +1211,14 @@ static int cfhsi_open(struct net_device *ndev)
1211 init_waitqueue_head(&cfhsi->flush_fifo_wait); 1211 init_waitqueue_head(&cfhsi->flush_fifo_wait);
1212 1212
1213 /* Setup the inactivity timer. */ 1213 /* Setup the inactivity timer. */
1214 init_timer(&cfhsi->inactivity_timer); 1214 setup_timer(&cfhsi->inactivity_timer, cfhsi_inactivity_tout,
1215 cfhsi->inactivity_timer.data = (unsigned long)cfhsi; 1215 (unsigned long)cfhsi);
1216 cfhsi->inactivity_timer.function = cfhsi_inactivity_tout;
1217 /* Setup the slowpath RX timer. */ 1216 /* Setup the slowpath RX timer. */
1218 init_timer(&cfhsi->rx_slowpath_timer); 1217 setup_timer(&cfhsi->rx_slowpath_timer, cfhsi_rx_slowpath,
1219 cfhsi->rx_slowpath_timer.data = (unsigned long)cfhsi; 1218 (unsigned long)cfhsi);
1220 cfhsi->rx_slowpath_timer.function = cfhsi_rx_slowpath;
1221 /* Setup the aggregation timer. */ 1219 /* Setup the aggregation timer. */
1222 init_timer(&cfhsi->aggregation_timer); 1220 setup_timer(&cfhsi->aggregation_timer, cfhsi_aggregation_tout,
1223 cfhsi->aggregation_timer.data = (unsigned long)cfhsi; 1221 (unsigned long)cfhsi);
1224 cfhsi->aggregation_timer.function = cfhsi_aggregation_tout;
1225 1222
1226 /* Activate HSI interface. */ 1223 /* Activate HSI interface. */
1227 res = cfhsi->ops->cfhsi_up(cfhsi->ops); 1224 res = cfhsi->ops->cfhsi_up(cfhsi->ops);