Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 215112
b: refs/heads/master
c: f7ec804
h: refs/heads/master
v: v3
  • Loading branch information
Amit Kumar Salecha authored and David S. Miller committed Oct 8, 2010
1 parent 847df66 commit 79fd322
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9cf8d1a3b8cb19fa49494c1b8f0f9e3a37f2c218
refs/heads/master: f7ec804a3edd2f7cf98a42bcad741d89d547c117
12 changes: 11 additions & 1 deletion trunk/drivers/net/qlcnic/qlcnic_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ char qlcnic_driver_name[] = "qlcnic";
static const char qlcnic_driver_string[] = "QLogic 1/10 GbE "
"Converged/Intelligent Ethernet Driver v" QLCNIC_LINUX_VERSIONID;

static struct workqueue_struct *qlcnic_wq;
static int qlcnic_mac_learn;
module_param(qlcnic_mac_learn, int, 0644);
MODULE_PARM_DESC(qlcnic_mac_learn, "Mac Filter (0=disabled, 1=enabled)");
Expand Down Expand Up @@ -2886,7 +2887,8 @@ qlcnic_schedule_work(struct qlcnic_adapter *adapter,
return;

INIT_DELAYED_WORK(&adapter->fw_work, func);
schedule_delayed_work(&adapter->fw_work, round_jiffies_relative(delay));
queue_delayed_work(qlcnic_wq, &adapter->fw_work,
round_jiffies_relative(delay));
}

static void
Expand Down Expand Up @@ -4163,6 +4165,12 @@ static int __init qlcnic_init_module(void)

printk(KERN_INFO "%s\n", qlcnic_driver_string);

qlcnic_wq = create_singlethread_workqueue("qlcnic");
if (qlcnic_wq == NULL) {
printk(KERN_ERR "qlcnic: cannot create workqueue\n");
return -ENOMEM;
}

#ifdef CONFIG_INET
register_netdevice_notifier(&qlcnic_netdev_cb);
register_inetaddr_notifier(&qlcnic_inetaddr_cb);
Expand All @@ -4174,6 +4182,7 @@ static int __init qlcnic_init_module(void)
unregister_inetaddr_notifier(&qlcnic_inetaddr_cb);
unregister_netdevice_notifier(&qlcnic_netdev_cb);
#endif
destroy_workqueue(qlcnic_wq);
}

return ret;
Expand All @@ -4190,6 +4199,7 @@ static void __exit qlcnic_exit_module(void)
unregister_inetaddr_notifier(&qlcnic_inetaddr_cb);
unregister_netdevice_notifier(&qlcnic_netdev_cb);
#endif
destroy_workqueue(qlcnic_wq);
}

module_exit(qlcnic_exit_module);

0 comments on commit 79fd322

Please sign in to comment.