}
return TRUE;
-
-#ifdef RT30xx
-FillTxBlkErr:
- return FALSE;
-#endif
}
TX_BLK TxBlk;
TX_BLK *pTxBlk;
-#ifdef DBG_DIAGNOSE
- BOOLEAN firstRound;
- RtmpDiagStruct *pDiagStruct = &pAd->DiagStruct;
-#endif
if (QIdx == NUM_OF_TX_RING)
RT28XX_START_DEQUEUE(pAd, QueIdx, IrqFlags);
-#ifdef DBG_DIAGNOSE
- firstRound = ((QueIdx == 0) ? TRUE : FALSE);
-#endif // DBG_DIAGNOSE //
while (1)
{
DEQUEUE_LOCK(&pAd->irq_lock, bIntContext, IrqFlags);
if (&pAd->TxSwQueue[QueIdx] == NULL)
{
-#ifdef DBG_DIAGNOSE
- if (firstRound == TRUE)
- pDiagStruct->TxSWQueCnt[pDiagStruct->ArrayCurIdx][0]++;
-#endif // DBG_DIAGNOSE //
DEQUEUE_UNLOCK(&pAd->irq_lock, bIntContext, IrqFlags);
break;
}
#ifdef RT2860
FreeNumber[QueIdx] = GET_TXRING_FREENO(pAd, QueIdx);
-#ifdef DBG_DIAGNOSE
- if (firstRound == TRUE)
- {
- UCHAR txDescNumLevel, txSwQNumLevel;
-
- txDescNumLevel = (TX_RING_SIZE - FreeNumber[QueIdx]); // Number of occupied hw desc.
- txDescNumLevel = ((txDescNumLevel <=15) ? txDescNumLevel : 15);
- pDiagStruct->TxDescCnt[pDiagStruct->ArrayCurIdx][txDescNumLevel]++;
-
- txSwQNumLevel = ((pAd->TxSwQueue[QueIdx].Number <=7) ? pAd->TxSwQueue[QueIdx].Number : 8);
- pDiagStruct->TxSWQueCnt[pDiagStruct->ArrayCurIdx][txSwQNumLevel]++;
-
- firstRound = FALSE;
- }
-#endif // DBG_DIAGNOSE //
if (FreeNumber[QueIdx] <= 5)
{
}
}
-#ifdef DBG_DIAGNOSE
- if (pTxBlk->QueIdx== 0)
- {
- pAd->DiagStruct.TxDataCnt[pAd->DiagStruct.ArrayCurIdx]++;
- pAd->DiagStruct.TxMcsCnt[pAd->DiagStruct.ArrayCurIdx][pTxWI->MCS]++;
- }
-#endif // DBG_DIAGNOSE //
// for rate adapation
pTxWI->PacketId = pTxWI->MCS;
}
}
-#ifdef DBG_DIAGNOSE
- if (pTxBlk->QueIdx== 0)
- {
- pAd->DiagStruct.TxDataCnt[pAd->DiagStruct.ArrayCurIdx]++;
- pAd->DiagStruct.TxMcsCnt[pAd->DiagStruct.ArrayCurIdx][pTxWI->MCS]++;
- }
-#endif // DBG_DIAGNOSE //
pTxWI->MPDUtotalByteCount = pTxBlk->MpduHeaderLen + pTxBlk->SrcBufLen;
AsicUpdateProtect(pAd, 0 /*pAd->CommonCfg.AddHTInfo.AddHtInfo2.OperaionMode*/, (ALLN_SETPROTECT), TRUE, 0 /*pAd->MacTab.fAnyStationNonGF*/);
#endif
#ifdef RT30xx
- RT28XX_UPDATE_PROTECT(pAd); // edit by johnli, fix "in_interrupt" error when call "MacTableDeleteEntry" in Rx tasklet
+ // edit by johnli, fix "in_interrupt" error when call "MacTableDeleteEntry" in Rx tasklet
+ // Set MAC register value according operation mode
+ RTUSBEnqueueInternalCmd(pAd, CMDTHREAD_UPDATE_PROTECT, NULL, 0);
#endif
}