Explorar o código

drivers: net: enic: 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>
Allen Pais %!s(int64=8) %!d(string=hai) anos
pai
achega
7afd516ff7
Modificáronse 1 ficheiros con 2 adicións e 3 borrados
  1. 2 3
      drivers/net/ethernet/cisco/enic/enic_main.c

+ 2 - 3
drivers/net/ethernet/cisco/enic/enic_main.c

@@ -2846,9 +2846,8 @@ static int enic_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 	/* Setup notification timer, HW reset task, and wq locks
 	 */
 
-	init_timer(&enic->notify_timer);
-	enic->notify_timer.function = enic_notify_timer;
-	enic->notify_timer.data = (unsigned long)enic;
+	setup_timer(&enic->notify_timer, enic_notify_timer,
+		    (unsigned long)enic);
 
 	enic_set_rx_coal_setting(enic);
 	INIT_WORK(&enic->reset, enic_reset);