Staging: rt2860: remove dead EXT_BUILD_CHANNEL_LIST code
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Sun, 26 Apr 2009 14:05:13 +0000 (16:05 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 19 Jun 2009 18:00:44 +0000 (11:00 -0700)
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/rt2860/common/cmm_info.c
drivers/staging/rt2860/common/cmm_sanity.c
drivers/staging/rt2860/common/mlme.c
drivers/staging/rt2860/common/rtmp_init.c
drivers/staging/rt2860/mlme.h
drivers/staging/rt2860/rt_profile.c
drivers/staging/rt2860/rtmp.h
drivers/staging/rt2860/sta/connect.c
drivers/staging/rt2860/sta/sync.c
drivers/staging/rt2860/sta_ioctl.c

index 4dd02bce061fffbbb85862b48206841823e4255b..aeb91ef0c77cd6640670508e545fb5907dff74cb 100644 (file)
@@ -259,10 +259,6 @@ INT Set_CountryRegion_Proc(
 
        region = simple_strtol(arg, 0, 10);
 
-#ifdef EXT_BUILD_CHANNEL_LIST
-       return -EOPNOTSUPP;
-#endif // EXT_BUILD_CHANNEL_LIST //
-
        // Country can be set only when EEPROM not programmed
        if (pAd->CommonCfg.CountryRegion & 0x80)
        {
@@ -309,10 +305,6 @@ INT Set_CountryRegionABand_Proc(
 
        region = simple_strtol(arg, 0, 10);
 
-#ifdef EXT_BUILD_CHANNEL_LIST
-       return -EOPNOTSUPP;
-#endif // EXT_BUILD_CHANNEL_LIST //
-
        // Country can be set only when EEPROM not programmed
        if (pAd->CommonCfg.CountryRegionForABand & 0x80)
        {
@@ -1210,11 +1202,8 @@ VOID     RTMPSetPhyMode(
        pAd->CommonCfg.PhyMode = (UCHAR)phymode;
 
        DBGPRINT(RT_DEBUG_TRACE,("RTMPSetPhyMode : PhyMode=%d, channel=%d \n", pAd->CommonCfg.PhyMode, pAd->CommonCfg.Channel));
-#ifdef EXT_BUILD_CHANNEL_LIST
-       BuildChannelListEx(pAd);
-#else
+
        BuildChannelList(pAd);
-#endif // EXT_BUILD_CHANNEL_LIST //
 
        // sanity check user setting
        for (i = 0; i < pAd->ChannelListNum; i++)
index 1d1aaa6f7691191826b7675ed1fe9c1ad657f7c7..d5553428e8f43cf94b406f43519aaf7574e848fe 100644 (file)
@@ -712,15 +712,6 @@ BOOLEAN PeerBeaconAndProbeRspSanity(
                     *LengthVIE += (pEid->Len + 2);
                 }
                 break;
-#ifdef CONFIG_STA_SUPPORT
-#ifdef EXT_BUILD_CHANNEL_LIST
-                       case IE_COUNTRY:
-                               Ptr = (PUCHAR) pVIE;
-                NdisMoveMemory(Ptr + *LengthVIE, &pEid->Eid, pEid->Len + 2);
-                *LengthVIE += (pEid->Len + 2);
-                               break;
-#endif // EXT_BUILD_CHANNEL_LIST //
-#endif // CONFIG_STA_SUPPORT //
 
             default:
                 break;
index d1c0a822c086488a7dc463d7be662ea008a8e025..2f76748a56ba188d4a43efd23f820b1ebe91feb2 100644 (file)
@@ -3702,11 +3702,9 @@ VOID BssEntrySet(
 
                NdisZeroMemory(&pBss->WpaIE.IE[0], MAX_CUSTOM_LEN);
                NdisZeroMemory(&pBss->RsnIE.IE[0], MAX_CUSTOM_LEN);
-#ifdef EXT_BUILD_CHANNEL_LIST
-               NdisZeroMemory(&pBss->CountryString[0], 3);
-               pBss->bHasCountryIE = FALSE;
-#endif // EXT_BUILD_CHANNEL_LIST //
+
                pEid = (PEID_STRUCT) pVIE;
+
                while ((Length + 2 + (USHORT)pEid->Len) <= LengthVIE)
                {
                        switch(pEid->Eid)
@@ -3735,12 +3733,6 @@ VOID BssEntrySet(
                                                NdisMoveMemory(pBss->RsnIE.IE, pEid, pBss->RsnIE.IELen);
                        }
                                break;
-#ifdef EXT_BUILD_CHANNEL_LIST
-                               case IE_COUNTRY:
-                                       NdisMoveMemory(&pBss->CountryString[0], pEid->Octet, 3);
-                                       pBss->bHasCountryIE = TRUE;
-                                       break;
-#endif // EXT_BUILD_CHANNEL_LIST //
             }
                        Length = Length + 2 + (USHORT)pEid->Len;  // Eid[1] + Len[1]+ content[Len]
                        pEid = (PEID_STRUCT)((UCHAR*)pEid + 2 + pEid->Len);
@@ -3982,18 +3974,6 @@ VOID BssTableSsidSort(
                        (SSID_EQUAL(Ssid, SsidLen, pInBss->Ssid, pInBss->SsidLen) || bIsHiddenApIncluded))
                {
                        BSS_ENTRY *pOutBss = &OutTab->BssEntry[OutTab->BssNr];
-
-
-#ifdef EXT_BUILD_CHANNEL_LIST
-                       // If no Country IE exists no Connection will be established when IEEE80211dClientMode is strict.
-                       if ((pAd->StaCfg.IEEE80211dClientMode == Rt802_11_D_Strict) &&
-                               (pInBss->bHasCountryIE == FALSE))
-                       {
-                               DBGPRINT(RT_DEBUG_TRACE,("StaCfg.IEEE80211dClientMode == Rt802_11_D_Strict, but this AP doesn't have country IE.\n"));
-                               continue;
-                       }
-#endif // EXT_BUILD_CHANNEL_LIST //
-
 #ifdef DOT11_N_SUPPORT
                        // 2.4G/5G N only mode
                        if ((pInBss->HtCapabilityLen == 0) &&
index 1351e65b3a8935a3f1bdac07ed610e055d84153d..f0cf264477e4a105a21c1104919748fdfd05fb19 100644 (file)
@@ -3061,10 +3061,6 @@ VOID     UserCfgInit(
                pAd->StaCfg.bAutoTxRateSwitch = TRUE;
                pAd->StaCfg.DesiredTransmitSetting.field.MCS = MCS_AUTO;
        }
-
-#ifdef EXT_BUILD_CHANNEL_LIST
-       pAd->StaCfg.IEEE80211dClientMode = Rt802_11_D_None;
-#endif // EXT_BUILD_CHANNEL_LIST //
 #endif // CONFIG_STA_SUPPORT //
 
        // global variables mXXXX used in MAC protocol state machines
index 76ced85611bd7591655169b3124fc66dbe7d8ed9..8c46c70dabe6dea123d5521d9d07edc0c64d488a 100644 (file)
@@ -1166,10 +1166,6 @@ typedef struct {
 #ifdef CONFIG_STA_SUPPORT
     WPA_IE_     WpaIE;
     WPA_IE_     RsnIE;
-#ifdef EXT_BUILD_CHANNEL_LIST
-       UCHAR           CountryString[3];
-       BOOLEAN         bHasCountryIE;
-#endif // EXT_BUILD_CHANNEL_LIST //
 #endif // CONFIG_STA_SUPPORT //
 } BSS_ENTRY, *PBSS_ENTRY;
 
index 5f6d3495f46c48b3322e7d8e58802314a2dc0023..4138656e9e2ac5e1ed950190fdc4df92151cb9b5 100644 (file)
@@ -950,12 +950,7 @@ NDIS_STATUS        RTMPReadParametersHook(
                                        if(RTMPGetKeyParameter("CountryCode", tmpbuf, 25, buffer))
                                        {
                                                NdisMoveMemory(pAd->CommonCfg.CountryCode, tmpbuf , 2);
-#ifdef CONFIG_STA_SUPPORT
-#ifdef EXT_BUILD_CHANNEL_LIST
-                                               IF_DEV_CONFIG_OPMODE_ON_STA(pAd)
-                                                       NdisMoveMemory(pAd->StaCfg.StaOriCountryCode, tmpbuf , 2);
-#endif // EXT_BUILD_CHANNEL_LIST //
-#endif // CONFIG_STA_SUPPORT //
+
                                                if (strlen(pAd->CommonCfg.CountryCode) != 0)
                                                {
                                                        pAd->CommonCfg.bCountryFlag = TRUE;
@@ -971,12 +966,6 @@ NDIS_STATUS        RTMPReadParametersHook(
                                                        pAd->CommonCfg.Geography = Geography;
                                                        pAd->CommonCfg.CountryCode[2] =
                                                                (pAd->CommonCfg.Geography == BOTH) ? ' ' : ((pAd->CommonCfg.Geography == IDOR) ? 'I' : 'O');
-#ifdef CONFIG_STA_SUPPORT
-#ifdef EXT_BUILD_CHANNEL_LIST
-                                               IF_DEV_CONFIG_OPMODE_ON_STA(pAd)
-                                                       pAd->StaCfg.StaOriGeography = pAd->CommonCfg.Geography;
-#endif // EXT_BUILD_CHANNEL_LIST //
-#endif // CONFIG_STA_SUPPORT //
                                                        DBGPRINT(RT_DEBUG_TRACE, ("ChannelGeography=%d\n", pAd->CommonCfg.Geography));
                                                }
                                        }
index d2566c32e549f255e91468b2932e56ef27ad821f..aa452eff060ad68e642ca89106f5432b4fec3b62 100644 (file)
@@ -2111,12 +2111,6 @@ typedef struct _STA_ADMIN_CONFIG {
        BOOLEAN                                                 bAutoTxRateSwitch;
 
     UCHAR       BBPR3;
-
-#ifdef EXT_BUILD_CHANNEL_LIST
-       UCHAR                           IEEE80211dClientMode;
-       UCHAR                           StaOriCountryCode[3];
-       UCHAR                           StaOriGeography;
-#endif // EXT_BUILD_CHANNEL_LIST //
 } STA_ADMIN_CONFIG, *PSTA_ADMIN_CONFIG;
 
 // This data structure keep the current active BSS/IBSS's configuration that this STA
index 3fd744c6c4b037b43c185283174bbd43fed94acd..9e2672074fc7aefe2439fead867b674f629f2806 100644 (file)
@@ -1917,17 +1917,6 @@ VOID LinkDown(
                        NdisMoveMemory(pAd->StaCfg.CCXAdjacentAPSsid, pAd->CommonCfg.Ssid, pAd->StaCfg.CCXAdjacentAPSsidLen);
                        COPY_MAC_ADDR(pAd->StaCfg.CCXAdjacentAPBssid, pAd->CommonCfg.Bssid);
                }
-
-#ifdef EXT_BUILD_CHANNEL_LIST
-               // Country IE of the AP will be evaluated and will be used.
-               if (pAd->StaCfg.IEEE80211dClientMode != Rt802_11_D_None)
-               {
-                       NdisMoveMemory(&pAd->CommonCfg.CountryCode[0], &pAd->StaCfg.StaOriCountryCode[0], 2);
-                       pAd->CommonCfg.Geography = pAd->StaCfg.StaOriGeography;
-                       BuildChannelListEx(pAd);
-               }
-#endif // EXT_BUILD_CHANNEL_LIST //
-
        }
 
        for (i=1; i<MAX_LEN_OF_MAC_TABLE; i++)
index 91f7846a36b3d29f993e6b82f15dcabf91adbe7d..9c68c9118e37c17da5f3050704f42fec13efb5a0 100644 (file)
@@ -375,22 +375,6 @@ VOID MlmeJoinReqAction(
        pAd->MlmeAux.Channel = pBss->Channel;
        pAd->MlmeAux.CentralChannel = pBss->CentralChannel;
 
-#ifdef EXT_BUILD_CHANNEL_LIST
-       // Country IE of the AP will be evaluated and will be used.
-       if ((pAd->StaCfg.IEEE80211dClientMode != Rt802_11_D_None) &&
-               (pBss->bHasCountryIE == TRUE))
-       {
-               NdisMoveMemory(&pAd->CommonCfg.CountryCode[0], &pBss->CountryString[0], 2);
-               if (pBss->CountryString[2] == 'I')
-                       pAd->CommonCfg.Geography = IDOR;
-               else if (pBss->CountryString[2] == 'O')
-                       pAd->CommonCfg.Geography = ODOR;
-               else
-                       pAd->CommonCfg.Geography = BOTH;
-               BuildChannelListEx(pAd);
-       }
-#endif // EXT_BUILD_CHANNEL_LIST //
-
        // Let BBP register at 20MHz to do scan
        RTMP_BBP_IO_READ8_BY_REG_ID(pAd, BBP_R4, &BBPValue);
        BBPValue &= (~0x18);
index 510c66b84c1ad3017d6fdd7df1ad49dee9c0fe14..88c75dc800ab63510aa270cb9e54449a9daa4697 100644 (file)
@@ -203,12 +203,6 @@ INT Set_ShortRetryLimit_Proc(
        IN      PRTMP_ADAPTER   pAdapter,
        IN      PUCHAR                  arg);
 
-#ifdef EXT_BUILD_CHANNEL_LIST
-INT Set_Ieee80211dClientMode_Proc(
-    IN  PRTMP_ADAPTER   pAdapter,
-    IN  PUCHAR          arg);
-#endif // EXT_BUILD_CHANNEL_LIST //
-
 static struct {
        CHAR *name;
        INT (*set_proc)(PRTMP_ADAPTER pAdapter, PUCHAR arg);
@@ -277,9 +271,6 @@ static struct {
 #endif // DOT11_N_SUPPORT //
        {"LongRetry",                           Set_LongRetryLimit_Proc},
        {"ShortRetry",                          Set_ShortRetryLimit_Proc},
-#ifdef EXT_BUILD_CHANNEL_LIST
-       {"11dClientMode",                               Set_Ieee80211dClientMode_Proc},
-#endif // EXT_BUILD_CHANNEL_LIST //
        {NULL,}
 };
 
@@ -5138,13 +5129,8 @@ INT RTMPQueryInformation(
                                UCHAR value;
                                DBGPRINT(RT_DEBUG_TRACE, ("Query::OID_802_11_BUILD_CHANNEL_EX \n"));
                                wrq->u.data.length = sizeof(UCHAR);
-#ifdef EXT_BUILD_CHANNEL_LIST
-                               DBGPRINT(RT_DEBUG_TRACE, ("Support EXT_BUILD_CHANNEL_LIST.\n"));
-                               value = 1;
-#else
                                DBGPRINT(RT_DEBUG_TRACE, ("Doesn't support EXT_BUILD_CHANNEL_LIST.\n"));
                                value = 0;
-#endif // EXT_BUILD_CHANNEL_LIST //
                                Status = copy_to_user(wrq->u.data.pointer, &value, 1);
                                DBGPRINT(RT_DEBUG_TRACE, ("Status=%d\n", Status));
                        }
@@ -6692,22 +6678,3 @@ INT Set_ShortRetryLimit_Proc(
        DBGPRINT(RT_DEBUG_TRACE, ("IF Set_ShortRetryLimit_Proc::(tx_rty_cfg=0x%x)\n", tx_rty_cfg.word));
        return TRUE;
 }
-
-#ifdef EXT_BUILD_CHANNEL_LIST
-INT Set_Ieee80211dClientMode_Proc(
-    IN  PRTMP_ADAPTER   pAdapter,
-    IN  PUCHAR          arg)
-{
-    if (simple_strtol(arg, 0, 10) == 0)
-        pAdapter->StaCfg.IEEE80211dClientMode = Rt802_11_D_None;
-    else if (simple_strtol(arg, 0, 10) == 1)
-        pAdapter->StaCfg.IEEE80211dClientMode = Rt802_11_D_Flexible;
-    else if (simple_strtol(arg, 0, 10) == 2)
-        pAdapter->StaCfg.IEEE80211dClientMode = Rt802_11_D_Strict;
-    else
-        return FALSE;
-
-    DBGPRINT(RT_DEBUG_TRACE, ("Set_Ieee802dMode_Proc::(IEEEE0211dMode=%d)\n", pAdapter->StaCfg.IEEE80211dClientMode));
-    return TRUE;
-}
-#endif // EXT_BUILD_CHANNEL_LIST //