summaryrefslogtreecommitdiff
path: root/drivers/net/igb
diff options
context:
space:
mode:
authorAlexander Duyck <alexander.h.duyck@intel.com>2009-03-20 03:17:08 +0300
committerDavid S. Miller <davem@davemloft.net>2009-03-22 02:57:01 +0300
commit0e340485725ea35ca4e354cce5df09e86e31e20d (patch)
tree3daceec952d52d4fb3925a51a81945b879b60e41 /drivers/net/igb
parentc493ea45a4251869fe7b820e0486b73b57df7c12 (diff)
downloadlinux-0e340485725ea35ca4e354cce5df09e86e31e20d.tar.xz
igb: update driver to use setup_timer function
igb was previously setting up all of the timer members itself. It is easier to just call setup_timer and reduce the calls to one line. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/igb')
-rw-r--r--drivers/net/igb/igb_main.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index 3fd2efa91cb2..4853a74843ec 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -1312,13 +1312,10 @@ static int __devinit igb_probe(struct pci_dev *pdev,
goto err_eeprom;
}
- init_timer(&adapter->watchdog_timer);
- adapter->watchdog_timer.function = &igb_watchdog;
- adapter->watchdog_timer.data = (unsigned long) adapter;
-
- init_timer(&adapter->phy_info_timer);
- adapter->phy_info_timer.function = &igb_update_phy_info;
- adapter->phy_info_timer.data = (unsigned long) adapter;
+ setup_timer(&adapter->watchdog_timer, &igb_watchdog,
+ (unsigned long) adapter);
+ setup_timer(&adapter->phy_info_timer, &igb_update_phy_info,
+ (unsigned long) adapter);
INIT_WORK(&adapter->reset_task, igb_reset_task);
INIT_WORK(&adapter->watchdog_task, igb_watchdog_task);