diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-04-26 16:04:53 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-06-19 11:00:42 -0700 |
commit | 99db6000cf6bf662cf48c63c2fa3df7d99e0da69 (patch) | |
tree | fd7ce08490f4cdd8e5cd5d171f3b3098ed639bcc /drivers/staging/rt3070/common | |
parent | ae2d5411cd4be6784acb7c6df56ab6295a4e3922 (diff) |
Staging: rt3070: remove dead RALINK_ATE code
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/rt3070/common')
-rw-r--r-- | drivers/staging/rt3070/common/2870_rtmp_init.c | 19 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/action.c | 5 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/ba_action.c | 6 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/cmm_sync.c | 6 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/mlme.c | 83 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/rtmp_init.c | 43 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/rtusb_bulk.c | 23 | ||||
-rw-r--r-- | drivers/staging/rt3070/common/rtusb_io.c | 49 |
8 files changed, 1 insertions, 233 deletions
diff --git a/drivers/staging/rt3070/common/2870_rtmp_init.c b/drivers/staging/rt3070/common/2870_rtmp_init.c index 953ef541def..9795638f33c 100644 --- a/drivers/staging/rt3070/common/2870_rtmp_init.c +++ b/drivers/staging/rt3070/common/2870_rtmp_init.c @@ -503,10 +503,6 @@ NDIS_STATUS RTMPAllocTxRxRingMemory( NdisAllocateSpinLock(&pAd->TxContextQueueLock[num]); } -#ifdef RALINK_ATE - NdisAllocateSpinLock(&pAd->GenericLock); -#endif // RALINK_ATE // - // NdisAllocateSpinLock(&pAd->MemLock); // Not used in RT28XX // NdisAllocateSpinLock(&pAd->MacTabLock); // init it in UserCfgInit() @@ -672,9 +668,7 @@ VOID RTMPFreeTxRxRingMemory( NdisFreeSpinLock(&pAd->MLMEBulkOutLock); NdisFreeSpinLock(&pAd->CmdQLock); -#ifdef RALINK_ATE - NdisFreeSpinLock(&pAd->GenericLock); -#endif // RALINK_ATE // + // Clear all pending bulk-out request flags. RTUSB_CLEAR_BULK_FLAG(pAd, 0xffffffff); @@ -1182,17 +1176,6 @@ static void rx_done_tasklet(unsigned long data) ASSERT((pRxContext->InUse == pRxContext->IRPPending)); -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - { - // If the driver is in ATE mode and Rx frame is set into here. - if (pAd->ContinBulkIn == TRUE) - { - RTUSBBulkReceive(pAd); - } - } - else -#endif // RALINK_ATE // RTUSBBulkReceive(pAd); return; diff --git a/drivers/staging/rt3070/common/action.c b/drivers/staging/rt3070/common/action.c index b8ae5363366..1597d7aa72d 100644 --- a/drivers/staging/rt3070/common/action.c +++ b/drivers/staging/rt3070/common/action.c @@ -881,11 +881,6 @@ VOID ORIBATimerTimeout( // USHORT Sequence; UCHAR TID; -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - total = pAd->MacTab.Size * NUM_OF_TID; for (i = 1; ((i <MAX_LEN_OF_BA_ORI_TABLE) && (total > 0)) ; i++) diff --git a/drivers/staging/rt3070/common/ba_action.c b/drivers/staging/rt3070/common/ba_action.c index 2ad68cb7385..b312495b8d4 100644 --- a/drivers/staging/rt3070/common/ba_action.c +++ b/drivers/staging/rt3070/common/ba_action.c @@ -1081,12 +1081,6 @@ VOID BAOriSessionSetupTimeout( } #endif // CONFIG_STA_SUPPORT // -#ifdef RALINK_ATE - // Nothing to do in ATE mode. - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - pEntry = &pAd->MacTab.Content[pBAEntry->Wcid]; if ((pBAEntry->ORI_BA_Status == Originator_WaitRes) && (pBAEntry->Token < ORI_SESSION_MAX_RETRY)) diff --git a/drivers/staging/rt3070/common/cmm_sync.c b/drivers/staging/rt3070/common/cmm_sync.c index 2be7c77a384..60a8f021d83 100644 --- a/drivers/staging/rt3070/common/cmm_sync.c +++ b/drivers/staging/rt3070/common/cmm_sync.c @@ -397,12 +397,6 @@ VOID ScanNextChannel( } #endif // CONFIG_STA_SUPPORT // -#ifdef RALINK_ATE - // Nothing to do in ATE mode. - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - if (pAd->MlmeAux.Channel == 0) { if ((pAd->CommonCfg.BBPCurrentBW == BW_40) diff --git a/drivers/staging/rt3070/common/mlme.c b/drivers/staging/rt3070/common/mlme.c index 0189bab013c..f5c386b500a 100644 --- a/drivers/staging/rt3070/common/mlme.c +++ b/drivers/staging/rt3070/common/mlme.c @@ -590,14 +590,6 @@ VOID MlmeHandler( break; } -#ifdef RALINK_ATE - if(ATE_ON(pAd)) - { - DBGPRINT(RT_DEBUG_TRACE, ("The driver is in ATE mode now in MlmeHandler\n")); - break; - } -#endif // RALINK_ATE // - //From message type, determine which state machine I should drive if (MlmeDequeue(&pAd->Mlme.Queue, &Elem)) { @@ -844,18 +836,6 @@ VOID MlmePeriodicExec( RT28XX_MLME_PRE_SANITY_CHECK(pAd); -#ifdef RALINK_ATE - /* Do not show RSSI until "Normal 1 second Mlme PeriodicExec". */ - if (ATE_ON(pAd)) - { - if (pAd->Mlme.PeriodicRound % MLME_TASK_EXEC_MULTIPLE != (MLME_TASK_EXEC_MULTIPLE - 1)) - { - pAd->Mlme.PeriodicRound ++; - return; - } - } -#endif // RALINK_ATE // - #ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { @@ -913,30 +893,6 @@ VOID MlmePeriodicExec( { pAd->Mlme.OneSecPeriodicRound ++; -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - { - /* request from Baron : move this routine from later to here */ - /* for showing Rx error count in ATE RXFRAME */ - NICUpdateRawCounters(pAd); - if (pAd->ate.bRxFer == 1) - { - pAd->ate.RxTotalCnt += pAd->ate.RxCntPerSec; - ate_print(KERN_EMERG "MlmePeriodicExec: Rx packet cnt = %d/%d\n", pAd->ate.RxCntPerSec, pAd->ate.RxTotalCnt); - pAd->ate.RxCntPerSec = 0; - - if (pAd->ate.RxAntennaSel == 0) - ate_print(KERN_EMERG "MlmePeriodicExec: Rx AvgRssi0=%d, AvgRssi1=%d, AvgRssi2=%d\n\n", - pAd->ate.AvgRssi0, pAd->ate.AvgRssi1, pAd->ate.AvgRssi2); - else - ate_print(KERN_EMERG "MlmePeriodicExec: Rx AvgRssi=%d\n\n", pAd->ate.AvgRssi0); - } - MlmeResetRalinkCounters(pAd); - return; - } -#endif // RALINK_ATE // - - if (rx_Total) { @@ -1052,17 +1008,6 @@ VOID STAMlmePeriodicExec( ULONG TxTotalCnt; int i; -// -// We return here in ATE mode, because the statistics -// that ATE needs are not collected via this routine. -// -#ifdef RALINK_ATE - // It is supposed that we will never reach here in ATE mode. - ASSERT(!(ATE_ON(pAd))); - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - #ifdef WPA_SUPPLICANT_SUPPORT if (pAd->StaCfg.WpaSupplicantUP == WPA_SUPPLICANT_DISABLE) #endif // WPA_SUPPLICANT_SUPPORT // @@ -2024,13 +1969,6 @@ VOID MlmeDynamicTxRateSwitching( ULONG TxRetransmit = 0, TxSuccess = 0, TxFailCount = 0; MAC_TABLE_ENTRY *pEntry; -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - { - return; - } -#endif // RALINK_ATE // - // // walk through MAC table, see if need to change AP's TX rate toward each entry // @@ -4870,12 +4808,6 @@ BOOLEAN MlmeEnqueueForRecv( INT MsgType; MLME_QUEUE *Queue = (MLME_QUEUE *)&pAd->Mlme.Queue; -#ifdef RALINK_ATE - /* Nothing to do in ATE mode */ - if(ATE_ON(pAd)) - return FALSE; -#endif // RALINK_ATE // - // Do nothing if the driver is starting halt state. // This might happen when timer already been fired before cancel timer with mlmehalt if (RTMP_TEST_FLAG(pAd, fRTMP_ADAPTER_HALT_IN_PROGRESS | fRTMP_ADAPTER_NIC_NOT_EXIST)) @@ -5550,11 +5482,6 @@ VOID AsicUpdateProtect( UCHAR i; UINT32 MacReg = 0; -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - #ifdef DOT11_N_SUPPORT if (!(pAd->CommonCfg.bHTProtect) && (OperationMode != 8)) { @@ -8411,11 +8338,6 @@ VOID AsicEvaluateRxAnt( { UCHAR BBPR3 = 0; -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - if (RTMP_TEST_FLAG(pAd, fRTMP_ADAPTER_RESET_IN_PROGRESS | fRTMP_ADAPTER_HALT_IN_PROGRESS | fRTMP_ADAPTER_RADIO_OFF | @@ -8530,11 +8452,6 @@ VOID AsicRxAntEvalTimeout( CHAR larger = -127, rssi0, rssi1, rssi2; #endif // CONFIG_STA_SUPPORT // -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - if (RTMP_TEST_FLAG(pAd, fRTMP_ADAPTER_RESET_IN_PROGRESS | fRTMP_ADAPTER_HALT_IN_PROGRESS | fRTMP_ADAPTER_RADIO_OFF | diff --git a/drivers/staging/rt3070/common/rtmp_init.c b/drivers/staging/rt3070/common/rtmp_init.c index 298fce8aa71..2fb802f9219 100644 --- a/drivers/staging/rt3070/common/rtmp_init.c +++ b/drivers/staging/rt3070/common/rtmp_init.c @@ -2478,12 +2478,6 @@ VOID NICUpdateFifoStaCounters( CHAR reTry; UCHAR succMCS; -#ifdef RALINK_ATE - /* Nothing to do in ATE mode */ - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - do { RTMP_IO_READ32(pAd, TX_STA_FIFO, &StaFifo.word); @@ -3512,36 +3506,6 @@ VOID UserCfgInit( //RTMPInitTimer(pAd, &pAd->RECBATimer, RECBATimerTimeout, pAd, TRUE); //RTMPSetTimer(&pAd->RECBATimer, REORDER_EXEC_INTV); -#ifdef RALINK_ATE - NdisZeroMemory(&pAd->ate, sizeof(ATE_INFO)); - pAd->ate.Mode = ATE_STOP; - pAd->ate.TxCount = 200;/* to exceed TX_RING_SIZE ... */ - pAd->ate.TxLength = 1024; - pAd->ate.TxWI.ShortGI = 0;// LONG GI : 800 ns - pAd->ate.TxWI.PHYMODE = MODE_CCK; - pAd->ate.TxWI.MCS = 3; - pAd->ate.TxWI.BW = BW_20; - pAd->ate.Channel = 1; - pAd->ate.QID = QID_AC_BE; - pAd->ate.Addr1[0] = 0x00; - pAd->ate.Addr1[1] = 0x11; - pAd->ate.Addr1[2] = 0x22; - pAd->ate.Addr1[3] = 0xAA; - pAd->ate.Addr1[4] = 0xBB; - pAd->ate.Addr1[5] = 0xCC; - NdisMoveMemory(pAd->ate.Addr2, pAd->ate.Addr1, ETH_LENGTH_OF_ADDRESS); - NdisMoveMemory(pAd->ate.Addr3, pAd->ate.Addr1, ETH_LENGTH_OF_ADDRESS); - pAd->ate.bRxFer = 0; - pAd->ate.bQATxStart = FALSE; - pAd->ate.bQARxStart = FALSE; -#ifdef RALINK_28xx_QA - //pAd->ate.Repeat = 0; - pAd->ate.TxStatus = 0; - pAd->ate.AtePid = 0; -#endif // RALINK_28xx_QA // -#endif // RALINK_ATE // - - pAd->CommonCfg.bWiFiTest = FALSE; @@ -3820,13 +3784,6 @@ VOID RTMPSetLED( UCHAR HighByte = 0; UCHAR LowByte; -// In ATE mode of RT2860 AP/STA, we have erased 8051 firmware. -// So LED mode is not supported when ATE is running. -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - return; -#endif // RALINK_ATE // - LowByte = pAd->LedCntl.field.LedMode&0x7f; switch (Status) { diff --git a/drivers/staging/rt3070/common/rtusb_bulk.c b/drivers/staging/rt3070/common/rtusb_bulk.c index be736342c95..f0279af1f1e 100644 --- a/drivers/staging/rt3070/common/rtusb_bulk.c +++ b/drivers/staging/rt3070/common/rtusb_bulk.c @@ -1039,9 +1039,6 @@ VOID RTUSBKickBulkOut( { // BulkIn Reset will reset whole USB PHY. So we need to make sure fRTMP_ADAPTER_BULKIN_RESET not flaged. if (!RTMP_TEST_FLAG(pAd ,fRTMP_ADAPTER_NEED_STOP_TX) -#ifdef RALINK_ATE - && !(ATE_ON(pAd)) -#endif // RALINK_ATE // ) { // 2. PS-Poll frame is next @@ -1119,18 +1116,6 @@ VOID RTUSBKickBulkOut( } } -#ifdef RALINK_ATE - /* If the mode is in ATE mode. */ - else if((ATE_ON(pAd)) && - !RTMP_TEST_FLAG(pAd ,fRTMP_ADAPTER_NEED_STOP_TX))// PETER : watch out ! - { - if (RTUSB_TEST_BULK_FLAG(pAd, fRTUSB_BULK_OUT_DATA_ATE)) - { - ATE_RTUSBBulkOutDataPacket(pAd, 0); - } - } -#endif // RALINK_ATE // - } /* @@ -1295,14 +1280,6 @@ VOID RTUSBCancelPendingBulkOutIRP( RTMPusecDelay(200); } -#ifdef RALINK_ATE - pHTTXContext->bCopySavePad = 0; - pHTTXContext->CurWritePosition = 0; - pHTTXContext->CurWriteRealPos = 0; - pHTTXContext->bCurWriting = FALSE; - pHTTXContext->NextBulkOutPosition = 0; - pHTTXContext->ENextBulkOutPosition = 0; -#endif // RALINK_ATE // pAd->BulkOutPending[Idx] = FALSE; } diff --git a/drivers/staging/rt3070/common/rtusb_io.c b/drivers/staging/rt3070/common/rtusb_io.c index a6a52e3445f..01153b7d59e 100644 --- a/drivers/staging/rt3070/common/rtusb_io.c +++ b/drivers/staging/rt3070/common/rtusb_io.c @@ -1217,13 +1217,6 @@ VOID CMDHandler( #ifdef CONFIG_STA_SUPPORT UINT32 data; #endif // CONFIG_STA_SUPPORT // -#ifdef RALINK_ATE - if(ATE_ON(pAd)) - { - DBGPRINT(RT_DEBUG_TRACE, ("The driver is in ATE mode now\n")); - break; - } -#endif // RALINK_ATE // #ifdef CONFIG_STA_SUPPORT @@ -1284,9 +1277,6 @@ VOID CMDHandler( PHT_TX_CONTEXT pHTTXContext; // RTMP_TX_RING *pTxRing; unsigned long IrqFlags; -#ifdef RALINK_ATE - PTX_CONTEXT pNullContext = &(pAd->NullContext); -#endif // RALINK_ATE // DBGPRINT_RAW(RT_DEBUG_TRACE, ("CmdThread : CMDTHREAD_RESET_BULK_OUT(ResetPipeid=0x%0x)===>\n", pAd->bulkResetPipeid)); // All transfers must be aborted or cancelled before attempting to reset the pipe. //RTUSBCancelPendingBulkOutIRP(pAd); @@ -1349,32 +1339,6 @@ VOID CMDHandler( //NdisReleaseSpinLock(&pAd->BulkOutLock[pAd->bulkResetPipeid]); RTMP_INT_UNLOCK(&pAd->BulkOutLock[pAd->bulkResetPipeid], IrqFlags); /*-----------------------------------------------------------------------------------------------*/ -#ifdef RALINK_ATE - if(ATE_ON(pAd)) - { - pNullContext->IRPPending = TRUE; - // - // If driver is still in ATE TXFRAME mode, - // keep on transmitting ATE frames. - // - DBGPRINT_RAW(RT_DEBUG_TRACE, ("pAd->ate.Mode == %d\npAd->ContinBulkOut == %d\npAd->BulkOutRemained == %d\n", pAd->ate.Mode, pAd->ContinBulkOut, atomic_read(&pAd->BulkOutRemained))); - if((pAd->ate.Mode == ATE_TXFRAME) && ((pAd->ContinBulkOut == TRUE) || (atomic_read(&pAd->BulkOutRemained) > 0))) - { - DBGPRINT_RAW(RT_DEBUG_TRACE, ("After CMDTHREAD_RESET_BULK_OUT, continue to bulk out frames !\n")); - - // Init Tx context descriptor - RTUSBInitTxDesc(pAd, pNullContext, 0/* pAd->bulkResetPipeid */, (usb_complete_t)ATE_RTUSBBulkOutDataPacketComplete); - - if((ret = RTUSB_SUBMIT_URB(pNullContext->pUrb))!=0) - { - DBGPRINT(RT_DEBUG_ERROR, ("ATE_RTUSBBulkOutDataPacket: Submit Tx URB failed %d\n", ret)); - } - - pAd->BulkOutReq++; - } - } - else -#endif // RALINK_ATE // /*-----------------------------------------------------------------------------------------------*/ { RTUSBInitHTTxDesc(pAd, pHTTXContext, pAd->bulkResetPipeid, pHTTXContext->BulkOutSize, (usb_complete_t)RTUSBBulkOutDataPacketComplete); @@ -1487,19 +1451,6 @@ VOID CMDHandler( { UINT32 MACValue; /*-----------------------------------------------------------------------------------------------*/ -#ifdef RALINK_ATE - if (ATE_ON(pAd)) - { - if((pAd->PendingRx > 0) && (!RTMP_TEST_FLAG(pAd, fRTMP_ADAPTER_NIC_NOT_EXIST))) - { - DBGPRINT_RAW(RT_DEBUG_ERROR, ("ATE : BulkIn IRP Pending!!!\n")); - ATE_RTUSBCancelPendingBulkInIRP(pAd); - RTMPusecDelay(100000); - pAd->PendingRx = 0; - } - } - else -#endif // RALINK_ATE // /*-----------------------------------------------------------------------------------------------*/ { //while ((atomic_read(&pAd->PendingRx) > 0) && (!RTMP_TEST_FLAG(pAd, fRTMP_ADAPTER_NIC_NOT_EXIST))) |