wlan: Replace init work related functions with wrapper APIs.

Proprietary driver can not access INIT_WORK and
INIT_DELAYED_WORK kernel APIs.
To mitigate issue replace above init work related functions
with vos wrapper APIs.

CRs-Fixed: 847627
Change-Id: Ic3b9a0e3d2057b0e1e8e9b4d0fba2f3cdb1fef9a
diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c
index 0cb4e33..50ebcb0 100755
--- a/CORE/HDD/src/wlan_hdd_main.c
+++ b/CORE/HDD/src/wlan_hdd_main.c
@@ -6844,11 +6844,11 @@
          }
 
          // Workqueue which gets scheduled in IPv4 notification callback.
-         INIT_WORK(&pAdapter->ipv4NotifierWorkQueue, hdd_ipv4_notifier_work_queue);
+         vos_init_work(&pAdapter->ipv4NotifierWorkQueue, hdd_ipv4_notifier_work_queue);
 
 #ifdef WLAN_NS_OFFLOAD
          // Workqueue which gets scheduled in IPv6 notification callback.
-         INIT_WORK(&pAdapter->ipv6NotifierWorkQueue, hdd_ipv6_notifier_work_queue);
+         vos_init_work(&pAdapter->ipv6NotifierWorkQueue, hdd_ipv6_notifier_work_queue);
 #endif
          //Stop the Interface TX queue.
          hddLog(VOS_TRACE_LEVEL_INFO, FL("Disabling queues"));
@@ -6861,7 +6861,7 @@
          {
              /* Initialize the work queue to defer the
               * back to back RoC request */
-             INIT_DELAYED_WORK(&pAdapter->roc_work,
+             vos_init_delayed_work(&pAdapter->roc_work,
                      hdd_p2p_roc_work_queue);
          }
 
@@ -7267,19 +7267,13 @@
                   break;
                }
             }
-#ifdef WLAN_OPEN_SOURCE
-          cancel_delayed_work_sync(&pAdapter->roc_work);
-#endif
+          vos_flush_delayed_work(&pAdapter->roc_work);
        }
 #ifdef WLAN_NS_OFFLOAD
-#ifdef WLAN_OPEN_SOURCE
-         cancel_work_sync(&pAdapter->ipv6NotifierWorkQueue);
-#endif
+         vos_flush_work(&pAdapter->ipv6NotifierWorkQueue);
 #endif
 
-#ifdef WLAN_OPEN_SOURCE
-         cancel_work_sync(&pAdapter->ipv4NotifierWorkQueue);
-#endif
+         vos_flush_work(&pAdapter->ipv4NotifierWorkQueue);
 
          /* It is possible that the caller of this function does not
           * wish to close the session
@@ -7329,9 +7323,7 @@
                }
             }
 
-#ifdef WLAN_OPEN_SOURCE
-            cancel_delayed_work_sync(&pAdapter->roc_work);
-#endif
+            vos_flush_delayed_work(&pAdapter->roc_work);
          }
          mutex_lock(&pHddCtx->sap_lock);
          if (test_bit(SOFTAP_BSS_STARTED, &pAdapter->event_flags))