mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-04-18 17:18:16 -04:00
igc: Switch to use hrtimer_setup()
hrtimer_setup() takes the callback function pointer as argument and initializes the timer completely. Replace hrtimer_init() and the open coded initialization of hrtimer::function with the new setup mechanism. Patch was created by using Coccinelle. Signed-off-by: Nam Cao <namcao@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/baeaabb84aef1803dfae385f6e9614d6fc547667.1738746872.git.namcao@linutronix.de
This commit is contained in:
@@ -7090,8 +7090,8 @@ static int igc_probe(struct pci_dev *pdev,
|
||||
INIT_WORK(&adapter->reset_task, igc_reset_task);
|
||||
INIT_WORK(&adapter->watchdog_task, igc_watchdog_task);
|
||||
|
||||
hrtimer_init(&adapter->hrtimer, CLOCK_MONOTONIC, HRTIMER_MODE_REL);
|
||||
adapter->hrtimer.function = &igc_qbv_scheduling_timer;
|
||||
hrtimer_setup(&adapter->hrtimer, &igc_qbv_scheduling_timer, CLOCK_MONOTONIC,
|
||||
HRTIMER_MODE_REL);
|
||||
|
||||
/* Initialize link properties that are user-changeable */
|
||||
adapter->fc_autoneg = true;
|
||||
|
||||
Reference in New Issue
Block a user