fm10k: don't initialize fm10k_workqueue at global level
authorBruce Allan <bruce.w.allan@intel.com>
Tue, 3 Nov 2015 19:35:02 +0000 (11:35 -0800)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Tue, 22 Dec 2015 12:20:19 +0000 (04:20 -0800)
Cleans up checkpatch GLOBAL_INITIALIZERS error

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Krishneil Singh <Krishneil.k.singh@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/fm10k/fm10k_main.c

index 75ff1092b7ee405cabfd56b5e1c44db4619c5748..b243c3cbe68faefa9e5857ade0e6a875b4141727 100644 (file)
@@ -42,7 +42,7 @@ MODULE_LICENSE("GPL");
 MODULE_VERSION(DRV_VERSION);
 
 /* single workqueue for entire fm10k driver */
-struct workqueue_struct *fm10k_workqueue = NULL;
+struct workqueue_struct *fm10k_workqueue;
 
 /**
  * fm10k_init_module - Driver Registration Routine
@@ -56,8 +56,7 @@ static int __init fm10k_init_module(void)
        pr_info("%s\n", fm10k_copyright);
 
        /* create driver workqueue */
-       if (!fm10k_workqueue)
-               fm10k_workqueue = create_workqueue("fm10k");
+       fm10k_workqueue = create_workqueue("fm10k");
 
        fm10k_dbg_init();
 
@@ -80,7 +79,6 @@ static void __exit fm10k_exit_module(void)
        /* destroy driver workqueue */
        flush_workqueue(fm10k_workqueue);
        destroy_workqueue(fm10k_workqueue);
-       fm10k_workqueue = NULL;
 }
 module_exit(fm10k_exit_module);