[9610][7885][7872] wlbt: Rename wifi-hal return values enum
authorJayaprakash Sangaru <j.sangaru@samsung.com>
Wed, 25 Jul 2018 09:33:19 +0000 (15:03 +0530)
committerhskang <hs1218.kang@samsung.com>
Fri, 17 Aug 2018 00:32:14 +0000 (20:32 -0400)
wifi-hal return vaalues enum is defined in enchanced logging and
in NAN which is creating some issues. Rename these enum params in
NAN.

SCSC-Bug-Id: SSB-42223

Change-Id: I1afe03e412a03d1e39db8df96a94f510f8ac9e2c
Signed-off-by: Jayaprakash Sangaru <j.sangaru@samsung.com>
drivers/net/wireless/scsc/nl80211_vendor.c
drivers/net/wireless/scsc/nl80211_vendor.h

index 060deb610fb8c1039f87a6c1c302e1d1333dd28b..bd7570b7773bc10548c23b1f690539bdba294101 100755 (executable)
@@ -3256,7 +3256,7 @@ static int slsi_nan_enable(struct wiphy *wiphy, struct wireless_dev *wdev, const
 
        if (!slsi_dev_nan_supported(sdev)) {
                SLSI_ERR(sdev, "NAN not allowed(mib:%d)\n", sdev->nan_enabled);
-               ret = WIFI_ERROR_NOT_SUPPORTED;
+               ret = WIFI_HAL_ERROR_NOT_SUPPORTED;
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
                goto exit;
        }
@@ -3441,7 +3441,7 @@ static int slsi_nan_publish(struct wiphy *wiphy, struct wireless_dev *wdev, cons
        if (!ndev_vif->activated) {
                SLSI_WARN(sdev, "NAN vif not activated\n");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
                goto exit_with_lock;
        }
 
@@ -3507,7 +3507,7 @@ static int slsi_nan_publish_cancel(struct wiphy *wiphy, struct wireless_dev *wde
        SLSI_MUTEX_LOCK(ndev_vif->vif_mutex);
        if (!ndev_vif->activated) {
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
                goto exit_with_lock;
        }
        if (!publish_id || !slsi_nan_is_publish_id_active(ndev_vif, publish_id)) {
@@ -3673,7 +3673,7 @@ static int slsi_nan_subscribe(struct wiphy *wiphy, struct wireless_dev *wdev, co
        if (!ndev_vif->activated) {
                SLSI_WARN(sdev, "NAN vif not activated\n");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
                goto exit_with_lock;
        }
 
@@ -3706,7 +3706,7 @@ static int slsi_nan_subscribe_cancel(struct wiphy *wiphy, struct wireless_dev *w
        struct slsi_dev *sdev = SDEV_FROM_WIPHY(wiphy);
        struct net_device *dev = slsi_nan_get_netdev(sdev);
        struct netdev_vif *ndev_vif;
-       int type, tmp, ret = WIFI_ERROR_UNKNOWN;
+       int type, tmp, ret = WIFI_HAL_ERROR_UNKNOWN;
        u16 subscribe_id = 0;
        const struct nlattr *iter;
        u32 reply_status = NAN_STATUS_SUCCESS;
@@ -3714,7 +3714,7 @@ static int slsi_nan_subscribe_cancel(struct wiphy *wiphy, struct wireless_dev *w
        if (!dev) {
                SLSI_ERR(sdev, "NAN netif not active!!");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
                goto exit;
        }
 
@@ -3747,7 +3747,7 @@ static int slsi_nan_subscribe_cancel(struct wiphy *wiphy, struct wireless_dev *w
        } else {
                SLSI_ERR(sdev, "vif not activated\n");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
        }
        SLSI_MUTEX_UNLOCK(ndev_vif->vif_mutex);
 exit:
@@ -3832,7 +3832,7 @@ static int slsi_nan_transmit_followup(struct wiphy *wiphy, struct wireless_dev *
        if (!ndev_vif->activated) {
                SLSI_WARN(sdev, "NAN vif not activated\n");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
                goto exit_with_lock;
        }
 
@@ -4090,7 +4090,7 @@ static int slsi_nan_set_config(struct wiphy *wiphy, struct wireless_dev *wdev, c
        if (!ndev_vif->activated) {
                SLSI_WARN(sdev, "NAN vif not activated\n");
                reply_status = NAN_STATUS_NAN_NOT_ALLOWED;
-               ret = WIFI_ERROR_NOT_AVAILABLE;
+               ret = WIFI_HAL_ERROR_NOT_AVAILABLE;
        } else {
                ret = slsi_mlme_nan_set_config(sdev, dev, &hal_req);
                if (ret)
index 4b8e975f8f9bb6202bfd3b1b3df8499e8b5f739d..f604887f7ee7127bc682e829dcda726fa23deb60 100755 (executable)
@@ -937,24 +937,19 @@ struct slsi_lls_iface_stat {
 #define SLSI_HAL_NAN_MAX_SUBSCRIBE_MAX_ADDRESS 42
 #define SLSI_HAL_NAN_MAX_POSTDISCOVERY_LEN 5
 
-/* WiFi-HAL return codes are defined in scsc_wifilogger_types.h */
-#ifdef CONFIG_SCSC_WLAN_ENHANCED_LOGGING
-#include "scsc_wifilogger_types.h"
-#else
-enum slsi_nan_api_return_types {
-       WIFI_SUCCESS = 0,
-       WIFI_ERROR_NONE = 0,
-       WIFI_ERROR_UNKNOWN = -1,
-       WIFI_ERROR_UNINITIALIZED = -2,
-       WIFI_ERROR_NOT_SUPPORTED = -3,
-       WIFI_ERROR_NOT_AVAILABLE = -4,
-       WIFI_ERROR_INVALID_ARGS = -5,
-       WIFI_ERROR_INVALID_REQUEST_ID = -6,
-       WIFI_ERROR_TIMED_OUT = -7,
-       WIFI_ERROR_TOO_MANY_REQUESTS = -8,
-       WIFI_ERROR_OUT_OF_MEMORY = -9
+enum slsi_wifi_hal_api_return_types {
+       WIFI_HAL_SUCCESS = 0,
+       WIFI_HAL_ERROR_NONE = 0,
+       WIFI_HAL_ERROR_UNKNOWN = -1,
+       WIFI_HAL_ERROR_UNINITIALIZED = -2,
+       WIFI_HAL_ERROR_NOT_SUPPORTED = -3,
+       WIFI_HAL_ERROR_NOT_AVAILABLE = -4,
+       WIFI_HAL_ERROR_INVALID_ARGS = -5,
+       WIFI_HAL_ERROR_INVALID_REQUEST_ID = -6,
+       WIFI_HAL_ERROR_TIMED_OUT = -7,
+       WIFI_HAL_ERROR_TOO_MANY_REQUESTS = -8,
+       WIFI_HAL_ERROR_OUT_OF_MEMORY = -9
 };
-#endif
 
 enum slsi_nan_status_type {
        /* NAN Protocol Response Codes */