diff options
author | Malcolm Priestley <tvboxspy@gmail.com> | 2013-12-09 22:23:19 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-12-10 23:14:26 -0800 |
commit | ae27b1428e874097d530f368d64c784f8701a0b4 (patch) | |
tree | 0bf02d26fc7e9da0a4c536457e1ceee72e87bd64 /drivers/staging/vt6656/mib.c | |
parent | 57cc0279f59da295ea6d98c31fccf2c3a4547e09 (diff) |
staging: vt6656: Remove STAvUpdateTDStatCounter and apply directly to stats
Apply directly to net_device_stats and wireless stats.
tx_bytes are relayed from s_vSaveTxPktInfo via scStatistic,
so collect them there.
All other statistics in STAvUpdateTDStatCounter are dead code
and don't reach user.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vt6656/mib.c')
-rw-r--r-- | drivers/staging/vt6656/mib.c | 89 |
1 files changed, 0 insertions, 89 deletions
diff --git a/drivers/staging/vt6656/mib.c b/drivers/staging/vt6656/mib.c index 12333cdcbc6..002f2b29a63 100644 --- a/drivers/staging/vt6656/mib.c +++ b/drivers/staging/vt6656/mib.c @@ -334,95 +334,6 @@ void STAvUpdateRDStatCounter(PSStatCounter pStatistic, } /* - * Description: Update Tx Statistic Counter - * - * Parameters: - * In: - * pStatistic - Pointer to Statistic Counter Data Structure - * byTSR0 - Tx Status - * byTSR1 - Tx Status - * pbyBuffer - Tx Buffer - * cbFrameLength - Tx Length - * uIdx - Index of Tx DMA - * Out: - * none - * - * Return Value: none - * - */ -void -STAvUpdateTDStatCounter ( - PSStatCounter pStatistic, - u8 byPktNum, - u8 byRate, - u8 byTSR - ) -{ - u8 byRetyCnt; - // increase tx packet count - pStatistic->dwTsrTxPacket++; - - byRetyCnt = (byTSR & 0xF0) >> 4; - if (byRetyCnt != 0) { - pStatistic->dwTsrRetry++; - pStatistic->dwTsrTotalRetry += byRetyCnt; - pStatistic->dwTxFail[byRate]+= byRetyCnt; - pStatistic->dwTxFail[MAX_RATE] += byRetyCnt; - - if ( byRetyCnt == 0x1) - pStatistic->dwTsrOnceRetry++; - else - pStatistic->dwTsrMoreThanOnceRetry++; - - if (byRetyCnt <= 8) - pStatistic->dwTxRetryCount[byRetyCnt-1]++; - - } - if ( !(byTSR & (TSR_TMO | TSR_RETRYTMO))) { - - if (byRetyCnt < 2) - pStatistic->TxNoRetryOkCount ++; - else - pStatistic->TxRetryOkCount ++; - - pStatistic->ullTsrOK++; - pStatistic->CustomStat.ullTsrAllOK++; - // update counters in case that successful transmit - pStatistic->dwTxOk[byRate]++; - pStatistic->dwTxOk[MAX_RATE]++; - - if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_BROAD ) { - pStatistic->ullTxBroadcastFrames++; - pStatistic->ullTxBroadcastBytes += pStatistic->abyTxPktInfo[byPktNum].wLength; - } else if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_MULTI ) { - pStatistic->ullTxMulticastFrames++; - pStatistic->ullTxMulticastBytes += pStatistic->abyTxPktInfo[byPktNum].wLength; - } else if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_UNI ) { - pStatistic->ullTxDirectedFrames++; - pStatistic->ullTxDirectedBytes += pStatistic->abyTxPktInfo[byPktNum].wLength; - } - } - else { - - pStatistic->TxFailCount ++; - - pStatistic->dwTsrErr++; - if (byTSR & TSR_RETRYTMO) - pStatistic->dwTsrRetryTimeout++; - if (byTSR & TSR_TMO) - pStatistic->dwTsrTransmitTimeout++; - } - - if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_BROAD ) { - pStatistic->dwTsrBroadcast++; - } else if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_MULTI ) { - pStatistic->dwTsrMulticast++; - } else if ( pStatistic->abyTxPktInfo[byPktNum].byBroadMultiUni == TX_PKT_UNI ) { - pStatistic->dwTsrDirected++; - } -} - -/* * Description: Update 802.11 mib counter * * Parameters: |