Commit f2af99ee authored by Malcolm Priestley's avatar Malcolm Priestley Committed by Greg Kroah-Hartman

staging: vt6655: Remove TxInSleep macro

TxInSleep is always enabled remove the macro and any
else code.
Signed-off-by: default avatarMalcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 11a72e5e
...@@ -643,12 +643,10 @@ typedef struct __device_info { ...@@ -643,12 +643,10 @@ typedef struct __device_info {
// command timer // command timer
struct timer_list sTimerCommand; struct timer_list sTimerCommand;
#ifdef TxInSleep
struct timer_list sTimerTxData; struct timer_list sTimerTxData;
unsigned long nTxDataTimeCout; unsigned long nTxDataTimeCout;
bool fTxDataInSleep; bool fTxDataInSleep;
bool IsTxDataTrigger; bool IsTxDataTrigger;
#endif
#ifdef WPA_SM_Transtatus #ifdef WPA_SM_Transtatus
bool fWPA_Authened; //is WPA/WPA-PSK or WPA2/WPA2-PSK authen?? bool fWPA_Authened; //is WPA/WPA-PSK or WPA2/WPA2-PSK authen??
......
...@@ -1720,9 +1720,8 @@ static int device_close(struct net_device *dev) ...@@ -1720,9 +1720,8 @@ static int device_close(struct net_device *dev)
bScheduleCommand((void *)pDevice, WLAN_CMD_DISASSOCIATE, NULL); bScheduleCommand((void *)pDevice, WLAN_CMD_DISASSOCIATE, NULL);
mdelay(30); mdelay(30);
} }
#ifdef TxInSleep
del_timer(&pDevice->sTimerTxData); del_timer(&pDevice->sTimerTxData);
#endif
del_timer(&pDevice->sTimerCommand); del_timer(&pDevice->sTimerCommand);
del_timer(&pMgmt->sTimerSecondCallback); del_timer(&pMgmt->sTimerSecondCallback);
if (pDevice->bDiversityRegCtlON) { if (pDevice->bDiversityRegCtlON) {
...@@ -2232,9 +2231,8 @@ static int device_xmit(struct sk_buff *skb, struct net_device *dev) ...@@ -2232,9 +2231,8 @@ static int device_xmit(struct sk_buff *skb, struct net_device *dev)
pLastTD->pTDInfo->skb = skb; pLastTD->pTDInfo->skb = skb;
pLastTD->pTDInfo->byFlags = 0; pLastTD->pTDInfo->byFlags = 0;
pLastTD->pTDInfo->byFlags |= TD_FLAGS_NETIF_SKB; pLastTD->pTDInfo->byFlags |= TD_FLAGS_NETIF_SKB;
#ifdef TxInSleep
pDevice->nTxDataTimeCout = 0; //2008-8-21 chester <add> for send null packet pDevice->nTxDataTimeCout = 0; //2008-8-21 chester <add> for send null packet
#endif
if (AVAIL_TD(pDevice, TYPE_AC0DMA) <= 1) if (AVAIL_TD(pDevice, TYPE_AC0DMA) <= 1)
netif_stop_queue(dev); netif_stop_queue(dev);
......
...@@ -274,13 +274,9 @@ PSbSendNullPacket( ...@@ -274,13 +274,9 @@ PSbSendNullPacket(
if (!pDevice->bLinkPass) if (!pDevice->bLinkPass)
return false; return false;
#ifdef TxInSleep
if (!pDevice->bEnablePSMode && !pDevice->fTxDataInSleep) if (!pDevice->bEnablePSMode && !pDevice->fTxDataInSleep)
return false; return false;
#else
if (!pDevice->bEnablePSMode)
return false;
#endif
if (pDevice->bEnablePSMode) { if (pDevice->bEnablePSMode) {
for (uIdx = 0; uIdx < TYPE_MAXTD; uIdx++) { for (uIdx = 0; uIdx < TYPE_MAXTD; uIdx++) {
if (pDevice->iTDUsed[uIdx] != 0) if (pDevice->iTDUsed[uIdx] != 0)
......
...@@ -2326,9 +2326,7 @@ CMD_STATUS csMgmt_xmit(PSDevice pDevice, PSTxMgmtPacket pPacket) ...@@ -2326,9 +2326,7 @@ CMD_STATUS csMgmt_xmit(PSDevice pDevice, PSTxMgmtPacket pPacket)
pDevice->apCurrTD[TYPE_TXDMA0] = pFrstTD->next; pDevice->apCurrTD[TYPE_TXDMA0] = pFrstTD->next;
#ifdef TxInSleep
pDevice->nTxDataTimeCout = 0; //2008-8-21 chester <add> for send null packet pDevice->nTxDataTimeCout = 0; //2008-8-21 chester <add> for send null packet
#endif
// Poll Transmit the adapter // Poll Transmit the adapter
MACvTransmit0(pDevice->PortOffset); MACvTransmit0(pDevice->PortOffset);
......
...@@ -31,10 +31,6 @@ ...@@ -31,10 +31,6 @@
/******* Common definitions and typedefs ***********************************/ /******* Common definitions and typedefs ***********************************/
#ifndef TxInSleep
#define TxInSleep
#endif
#ifndef WPA_SM_Transtatus #ifndef WPA_SM_Transtatus
#define WPA_SM_Transtatus #define WPA_SM_Transtatus
#endif #endif
......
...@@ -647,7 +647,6 @@ vCommandTimer( ...@@ -647,7 +647,6 @@ vCommandTimer(
if (netif_queue_stopped(pDevice->dev)) if (netif_queue_stopped(pDevice->dev))
netif_wake_queue(pDevice->dev); netif_wake_queue(pDevice->dev);
#ifdef TxInSleep
if (pDevice->IsTxDataTrigger) { //TxDataTimer is not triggered at the first time if (pDevice->IsTxDataTrigger) { //TxDataTimer is not triggered at the first time
del_timer(&pDevice->sTimerTxData); del_timer(&pDevice->sTimerTxData);
init_timer(&pDevice->sTimerTxData); init_timer(&pDevice->sTimerTxData);
...@@ -660,7 +659,7 @@ vCommandTimer( ...@@ -660,7 +659,7 @@ vCommandTimer(
pDevice->IsTxDataTrigger = true; pDevice->IsTxDataTrigger = true;
add_timer(&pDevice->sTimerTxData); add_timer(&pDevice->sTimerTxData);
#endif
} else if (pMgmt->eCurrState < WMAC_STATE_ASSOCPENDING) { } else if (pMgmt->eCurrState < WMAC_STATE_ASSOCPENDING) {
printk("WLAN_ASSOCIATE_WAIT:Association Fail???\n"); printk("WLAN_ASSOCIATE_WAIT:Association Fail???\n");
} else if (pDevice->byLinkWaitCount <= 4) { //mike add:wait another 2 sec if associated_frame delay! } else if (pDevice->byLinkWaitCount <= 4) { //mike add:wait another 2 sec if associated_frame delay!
...@@ -984,7 +983,6 @@ vResetCommandTimer( ...@@ -984,7 +983,6 @@ vResetCommandTimer(
pDevice->bCmdClear = false; pDevice->bCmdClear = false;
} }
#ifdef TxInSleep
void void
BSSvSecondTxData( BSSvSecondTxData(
void *hDeviceContext void *hDeviceContext
...@@ -1019,4 +1017,3 @@ BSSvSecondTxData( ...@@ -1019,4 +1017,3 @@ BSSvSecondTxData(
add_timer(&pDevice->sTimerTxData); add_timer(&pDevice->sTimerTxData);
return; return;
} }
#endif
...@@ -114,11 +114,10 @@ vCommandTimerWait( ...@@ -114,11 +114,10 @@ vCommandTimerWait(
void *hDeviceContext, void *hDeviceContext,
unsigned int MSecond unsigned int MSecond
); );
#ifdef TxInSleep
void void
BSSvSecondTxData( BSSvSecondTxData(
void *hDeviceContext void *hDeviceContext
); );
#endif
#endif //__WCMD_H__ #endif //__WCMD_H__
...@@ -388,7 +388,6 @@ vMgrTimerInit( ...@@ -388,7 +388,6 @@ vMgrTimerInit(
pDevice->sTimerCommand.function = (TimerFunction)vCommandTimer; pDevice->sTimerCommand.function = (TimerFunction)vCommandTimer;
pDevice->sTimerCommand.expires = RUN_AT(HZ); pDevice->sTimerCommand.expires = RUN_AT(HZ);
#ifdef TxInSleep
init_timer(&pDevice->sTimerTxData); init_timer(&pDevice->sTimerTxData);
pDevice->sTimerTxData.data = (unsigned long) pDevice; pDevice->sTimerTxData.data = (unsigned long) pDevice;
pDevice->sTimerTxData.function = (TimerFunction)BSSvSecondTxData; pDevice->sTimerTxData.function = (TimerFunction)BSSvSecondTxData;
...@@ -396,7 +395,6 @@ vMgrTimerInit( ...@@ -396,7 +395,6 @@ vMgrTimerInit(
pDevice->fTxDataInSleep = false; pDevice->fTxDataInSleep = false;
pDevice->IsTxDataTrigger = false; pDevice->IsTxDataTrigger = false;
pDevice->nTxDataTimeCout = 0; pDevice->nTxDataTimeCout = 0;
#endif
pDevice->cbFreeCmdQueue = CMD_Q_SIZE; pDevice->cbFreeCmdQueue = CMD_Q_SIZE;
pDevice->uCmdDequeueIdx = 0; pDevice->uCmdDequeueIdx = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment