Loading drivers/staging/rt2870/ap.h +0 −12 Original line number Diff line number Diff line Loading @@ -163,18 +163,6 @@ USHORT APBuildAssociation( IN UCHAR HtCapabilityLen, OUT USHORT *pAid); /* VOID RTMPAddClientSec( IN PRTMP_ADAPTER pAd, IN UCHAR BssIdx, IN UCHAR KeyIdx, IN UCHAR CipherAlg, IN PUCHAR pKey, IN PUCHAR pTxMic, IN PUCHAR pRxMic, IN MAC_TABLE_ENTRY *pEntry); */ // ap_auth.c void APAuthStateMachineInit( Loading drivers/staging/rt2870/chlist.h +0 −43 Original line number Diff line number Diff line Loading @@ -1195,49 +1195,6 @@ static inline VOID N_ChannelCheck( pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; //pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_NONE; // We didn't set the ExtCh as NONE due to it'll set in RTMPSetHT() } #if 0 switch (pAd->CommonCfg.CountryRegion & 0x7f) { case REGION_0_BG_BAND: // 1 -11 case REGION_1_BG_BAND: // 1 - 13 case REGION_5_BG_BAND: // 1 - 14 if (Channel <= 4) { pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; } else if (Channel >= 8) { if ((ChannelNum - Channel) < 4) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; } break; case REGION_2_BG_BAND: // 10 - 11 case REGION_3_BG_BAND: // 10 - 13 case REGION_4_BG_BAND: // 14 pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; break; case REGION_6_BG_BAND: // 3 - 9 if (Channel <= 5) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; else if (Channel == 6) pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; else if (Channel >= 7) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; break; case REGION_7_BG_BAND: // 5 - 13 if (Channel <= 8) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; else if (Channel >= 10) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; break; default: // Error. should never happen break; } #endif } } Loading drivers/staging/rt2870/common/2870_rtmp_init.c +0 −22 Original line number Diff line number Diff line Loading @@ -266,27 +266,6 @@ NDIS_STATUS NICInitTransmit( // // MGMT_RING_SIZE // #if 0 for(i=0; i<MGMT_RING_SIZE; i++) // 8 { PTX_CONTEXT pMLMEContext = &(pAd->MLMEContext[i]); NdisZeroMemory(pMLMEContext, sizeof(TX_CONTEXT)); //Allocate URB LM_USB_ALLOC(pObj, pMLMEContext, PTX_BUFFER, sizeof(TX_BUFFER), Status, ("<-- ERROR in Alloc TX MLMEContext[%d] urb!! \n", i), out2, ("<-- ERROR in Alloc TX MLMEContext[%d] TX_BUFFER !! \n", i), out2); pMLMEContext->pAd = pAd; pMLMEContext->pIrp = NULL; pMLMEContext->InUse = FALSE; pMLMEContext->IRPPending = FALSE; } #else // Allocate MGMT ring descriptor's memory pAd->MgmtDescRing.AllocSize = MGMT_RING_SIZE * sizeof(TX_CONTEXT); RTMPAllocateMemory(&pAd->MgmtDescRing.AllocVa, pAd->MgmtDescRing.AllocSize); Loading Loading @@ -336,7 +315,6 @@ NDIS_STATUS NICInitTransmit( pAd->MgmtRing.TxSwFreeIdx = MGMT_RING_SIZE; pAd->MgmtRing.TxCpuIdx = 0; pAd->MgmtRing.TxDmaIdx = 0; #endif // // BEACON_RING_SIZE Loading drivers/staging/rt2870/common/action.c +1 −9 Original line number Diff line number Diff line Loading @@ -466,11 +466,6 @@ VOID ORIBATimerTimeout( { MAC_TABLE_ENTRY *pEntry; INT i, total; // FRAME_BAR FrameBar; // ULONG FrameLen; // NDIS_STATUS NStatus; // PUCHAR pOutBuffer = NULL; // USHORT Sequence; UCHAR TID; total = pAd->MacTab.Size * NUM_OF_TID; Loading Loading @@ -535,10 +530,9 @@ VOID SendRefreshBAR( MakeOutgoingFrame(pOutBuffer, &FrameLen, sizeof(FRAME_BAR), &FrameBar, END_OF_ARGS); //if (!(CLIENT_STATUS_TEST_FLAG(pEntry, fCLIENT_STATUS_RALINK_CHIPSET))) if (1) // Now we always send BAR. { //MiniportMMRequestUnlock(pAd, 0, pOutBuffer, FrameLen); MiniportMMRequest(pAd, 0, pOutBuffer, FrameLen); } MlmeFreeMemory(pAd, pOutBuffer); Loading Loading @@ -568,8 +562,6 @@ VOID BarHeaderInit( IN PUCHAR pDA, IN PUCHAR pSA) { // USHORT Duration; NdisZeroMemory(pCntlBar, sizeof(FRAME_BAR)); pCntlBar->FC.Type = BTYPE_CNTL; pCntlBar->FC.SubType = SUBTYPE_BLOCK_ACK_REQ; Loading drivers/staging/rt2870/common/ba_action.c +1 −45 Original line number Diff line number Diff line Loading @@ -462,19 +462,6 @@ void ba_flush_reordering_timeout_mpdus( } } #if 0 else if ( (RTMP_TIME_AFTER((unsigned long)Now32, (unsigned long)(pBAEntry->LastIndSeqAtTimer+(MAX_REORDERING_PACKET_TIMEOUT))) && (pBAEntry->list.qlen > 1)) ) { DBGPRINT(RT_DEBUG_TRACE,("timeout[%d] (%lx-%lx = %d > %d): %x\n ", pBAEntry->list.qlen, Now32, (pBAEntry->LastIndSeqAtTimer), (int)((long) Now32 - (long)(pBAEntry->LastIndSeqAtTimer)), MAX_REORDERING_PACKET_TIMEOUT, pBAEntry->LastIndSeq)); ba_refresh_reordering_mpdus(pAd, pBAEntry); pBAEntry->LastIndSeqAtTimer = Now32; } #endif } Loading Loading @@ -688,10 +675,6 @@ BOOLEAN BARecSessionAdd( RTMPInitTimer(pAd, &pBAEntry->RECBATimer, GET_TIMER_FUNCTION(BARecSessionIdleTimeout), pBAEntry, TRUE); } #if 0 // for debugging RTMPSetTimer(&pBAEntry->RECBATimer, REC_BA_SESSION_IDLE_TIMEOUT); #endif // Set Bitmap flag. pEntry->RXBAbitmap |= (1<<TID); pEntry->BARecWcidArray[TID] = Idx; Loading Loading @@ -1552,13 +1535,9 @@ static VOID ba_enqueue_reordering_packet( } else { #if 0 DBGPRINT(RT_DEBUG_ERROR, ("!!! (%d:%d) Can't allocate reordering mpdu blk\n", blk_count, pBAEntry->list.qlen)); #else DBGPRINT(RT_DEBUG_ERROR, ("!!! (%d) Can't allocate reordering mpdu blk\n", pBAEntry->list.qlen)); #endif /* * flush all pending reordering mpdus * and receving mpdu to upper layer Loading Loading @@ -1606,29 +1585,11 @@ VOID Indicate_AMPDU_Packet( if (!RX_BLK_TEST_FLAG(pRxBlk, fRX_AMSDU) && (pRxBlk->DataSize > MAX_RX_PKT_LEN)) { #if 0 // sample take off, no use static int err_size; err_size++; if (err_size > 20) { printk("AMPDU DataSize = %d\n", pRxBlk->DataSize); hex_dump("802.11 Header", (UCHAR *)pRxBlk->pHeader, 24); hex_dump("Payload", pRxBlk->pData, 64); err_size = 0; } #endif // release packet RELEASE_NDIS_PACKET(pAd, pRxBlk->pRxPacket, NDIS_STATUS_FAILURE); return; } #if 0 // test /* Rec BA Session had been torn down */ INDICATE_LEGACY_OR_AMSDU(pAd, pRxBlk, FromWhichBSSID); return; #endif if (Wcid < MAX_LEN_OF_MAC_TABLE) { Idx = pAd->MacTab.Content[Wcid].BARecWcidArray[TID]; Loading Loading @@ -1723,10 +1684,6 @@ VOID Indicate_AMPDU_Packet( // else { #if 0 ba_refresh_reordering_mpdus(pAd, pBAEntry); INDICATE_LEGACY_OR_AMSDU(pAd, pRxBlk, FromWhichBSSID); #else LONG WinStartSeq, TmpSeq; Loading @@ -1748,6 +1705,5 @@ VOID Indicate_AMPDU_Packet( { pBAEntry->LastIndSeq = TmpSeq; } #endif } } Loading
drivers/staging/rt2870/ap.h +0 −12 Original line number Diff line number Diff line Loading @@ -163,18 +163,6 @@ USHORT APBuildAssociation( IN UCHAR HtCapabilityLen, OUT USHORT *pAid); /* VOID RTMPAddClientSec( IN PRTMP_ADAPTER pAd, IN UCHAR BssIdx, IN UCHAR KeyIdx, IN UCHAR CipherAlg, IN PUCHAR pKey, IN PUCHAR pTxMic, IN PUCHAR pRxMic, IN MAC_TABLE_ENTRY *pEntry); */ // ap_auth.c void APAuthStateMachineInit( Loading
drivers/staging/rt2870/chlist.h +0 −43 Original line number Diff line number Diff line Loading @@ -1195,49 +1195,6 @@ static inline VOID N_ChannelCheck( pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; //pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_NONE; // We didn't set the ExtCh as NONE due to it'll set in RTMPSetHT() } #if 0 switch (pAd->CommonCfg.CountryRegion & 0x7f) { case REGION_0_BG_BAND: // 1 -11 case REGION_1_BG_BAND: // 1 - 13 case REGION_5_BG_BAND: // 1 - 14 if (Channel <= 4) { pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; } else if (Channel >= 8) { if ((ChannelNum - Channel) < 4) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; } break; case REGION_2_BG_BAND: // 10 - 11 case REGION_3_BG_BAND: // 10 - 13 case REGION_4_BG_BAND: // 14 pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; break; case REGION_6_BG_BAND: // 3 - 9 if (Channel <= 5) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; else if (Channel == 6) pAd->CommonCfg.RegTransmitSetting.field.BW = BW_20; else if (Channel >= 7) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; break; case REGION_7_BG_BAND: // 5 - 13 if (Channel <= 8) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_ABOVE; else if (Channel >= 10) pAd->CommonCfg.RegTransmitSetting.field.EXTCHA = EXTCHA_BELOW; break; default: // Error. should never happen break; } #endif } } Loading
drivers/staging/rt2870/common/2870_rtmp_init.c +0 −22 Original line number Diff line number Diff line Loading @@ -266,27 +266,6 @@ NDIS_STATUS NICInitTransmit( // // MGMT_RING_SIZE // #if 0 for(i=0; i<MGMT_RING_SIZE; i++) // 8 { PTX_CONTEXT pMLMEContext = &(pAd->MLMEContext[i]); NdisZeroMemory(pMLMEContext, sizeof(TX_CONTEXT)); //Allocate URB LM_USB_ALLOC(pObj, pMLMEContext, PTX_BUFFER, sizeof(TX_BUFFER), Status, ("<-- ERROR in Alloc TX MLMEContext[%d] urb!! \n", i), out2, ("<-- ERROR in Alloc TX MLMEContext[%d] TX_BUFFER !! \n", i), out2); pMLMEContext->pAd = pAd; pMLMEContext->pIrp = NULL; pMLMEContext->InUse = FALSE; pMLMEContext->IRPPending = FALSE; } #else // Allocate MGMT ring descriptor's memory pAd->MgmtDescRing.AllocSize = MGMT_RING_SIZE * sizeof(TX_CONTEXT); RTMPAllocateMemory(&pAd->MgmtDescRing.AllocVa, pAd->MgmtDescRing.AllocSize); Loading Loading @@ -336,7 +315,6 @@ NDIS_STATUS NICInitTransmit( pAd->MgmtRing.TxSwFreeIdx = MGMT_RING_SIZE; pAd->MgmtRing.TxCpuIdx = 0; pAd->MgmtRing.TxDmaIdx = 0; #endif // // BEACON_RING_SIZE Loading
drivers/staging/rt2870/common/action.c +1 −9 Original line number Diff line number Diff line Loading @@ -466,11 +466,6 @@ VOID ORIBATimerTimeout( { MAC_TABLE_ENTRY *pEntry; INT i, total; // FRAME_BAR FrameBar; // ULONG FrameLen; // NDIS_STATUS NStatus; // PUCHAR pOutBuffer = NULL; // USHORT Sequence; UCHAR TID; total = pAd->MacTab.Size * NUM_OF_TID; Loading Loading @@ -535,10 +530,9 @@ VOID SendRefreshBAR( MakeOutgoingFrame(pOutBuffer, &FrameLen, sizeof(FRAME_BAR), &FrameBar, END_OF_ARGS); //if (!(CLIENT_STATUS_TEST_FLAG(pEntry, fCLIENT_STATUS_RALINK_CHIPSET))) if (1) // Now we always send BAR. { //MiniportMMRequestUnlock(pAd, 0, pOutBuffer, FrameLen); MiniportMMRequest(pAd, 0, pOutBuffer, FrameLen); } MlmeFreeMemory(pAd, pOutBuffer); Loading Loading @@ -568,8 +562,6 @@ VOID BarHeaderInit( IN PUCHAR pDA, IN PUCHAR pSA) { // USHORT Duration; NdisZeroMemory(pCntlBar, sizeof(FRAME_BAR)); pCntlBar->FC.Type = BTYPE_CNTL; pCntlBar->FC.SubType = SUBTYPE_BLOCK_ACK_REQ; Loading
drivers/staging/rt2870/common/ba_action.c +1 −45 Original line number Diff line number Diff line Loading @@ -462,19 +462,6 @@ void ba_flush_reordering_timeout_mpdus( } } #if 0 else if ( (RTMP_TIME_AFTER((unsigned long)Now32, (unsigned long)(pBAEntry->LastIndSeqAtTimer+(MAX_REORDERING_PACKET_TIMEOUT))) && (pBAEntry->list.qlen > 1)) ) { DBGPRINT(RT_DEBUG_TRACE,("timeout[%d] (%lx-%lx = %d > %d): %x\n ", pBAEntry->list.qlen, Now32, (pBAEntry->LastIndSeqAtTimer), (int)((long) Now32 - (long)(pBAEntry->LastIndSeqAtTimer)), MAX_REORDERING_PACKET_TIMEOUT, pBAEntry->LastIndSeq)); ba_refresh_reordering_mpdus(pAd, pBAEntry); pBAEntry->LastIndSeqAtTimer = Now32; } #endif } Loading Loading @@ -688,10 +675,6 @@ BOOLEAN BARecSessionAdd( RTMPInitTimer(pAd, &pBAEntry->RECBATimer, GET_TIMER_FUNCTION(BARecSessionIdleTimeout), pBAEntry, TRUE); } #if 0 // for debugging RTMPSetTimer(&pBAEntry->RECBATimer, REC_BA_SESSION_IDLE_TIMEOUT); #endif // Set Bitmap flag. pEntry->RXBAbitmap |= (1<<TID); pEntry->BARecWcidArray[TID] = Idx; Loading Loading @@ -1552,13 +1535,9 @@ static VOID ba_enqueue_reordering_packet( } else { #if 0 DBGPRINT(RT_DEBUG_ERROR, ("!!! (%d:%d) Can't allocate reordering mpdu blk\n", blk_count, pBAEntry->list.qlen)); #else DBGPRINT(RT_DEBUG_ERROR, ("!!! (%d) Can't allocate reordering mpdu blk\n", pBAEntry->list.qlen)); #endif /* * flush all pending reordering mpdus * and receving mpdu to upper layer Loading Loading @@ -1606,29 +1585,11 @@ VOID Indicate_AMPDU_Packet( if (!RX_BLK_TEST_FLAG(pRxBlk, fRX_AMSDU) && (pRxBlk->DataSize > MAX_RX_PKT_LEN)) { #if 0 // sample take off, no use static int err_size; err_size++; if (err_size > 20) { printk("AMPDU DataSize = %d\n", pRxBlk->DataSize); hex_dump("802.11 Header", (UCHAR *)pRxBlk->pHeader, 24); hex_dump("Payload", pRxBlk->pData, 64); err_size = 0; } #endif // release packet RELEASE_NDIS_PACKET(pAd, pRxBlk->pRxPacket, NDIS_STATUS_FAILURE); return; } #if 0 // test /* Rec BA Session had been torn down */ INDICATE_LEGACY_OR_AMSDU(pAd, pRxBlk, FromWhichBSSID); return; #endif if (Wcid < MAX_LEN_OF_MAC_TABLE) { Idx = pAd->MacTab.Content[Wcid].BARecWcidArray[TID]; Loading Loading @@ -1723,10 +1684,6 @@ VOID Indicate_AMPDU_Packet( // else { #if 0 ba_refresh_reordering_mpdus(pAd, pBAEntry); INDICATE_LEGACY_OR_AMSDU(pAd, pRxBlk, FromWhichBSSID); #else LONG WinStartSeq, TmpSeq; Loading @@ -1748,6 +1705,5 @@ VOID Indicate_AMPDU_Packet( { pBAEntry->LastIndSeq = TmpSeq; } #endif } }