From 4e8a7e5fc29697f881f5c358f84df52914908703 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guido=20Mart=C3=ADnez?= Date: Sat, 19 Apr 2014 16:44:59 -0300 Subject: staging: vt6655: remove dead code MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Remove dead code in many places on this driver. Signed-off-by: Guido Martínez Signed-off-by: Greg Kroah-Hartman --- drivers/staging/vt6655/power.c | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) (limited to 'drivers/staging/vt6655/power.c') diff --git a/drivers/staging/vt6655/power.c b/drivers/staging/vt6655/power.c index 4bd1ccb..bc6186d 100644 --- a/drivers/staging/vt6655/power.c +++ b/drivers/staging/vt6655/power.c @@ -95,14 +95,12 @@ PSvEnablePowerSaving( if (wListenInterval >= 2) { // clear always listen beacon MACvRegBitsOff(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN); - //pDevice->wCFG &= ~CFG_ALB; // first time set listen next beacon MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_LNBCN); pMgmt->wCountToWakeUp = wListenInterval; } else { // always listen beacon MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN); - //pDevice->wCFG |= CFG_ALB; pMgmt->wCountToWakeUp = 0; } @@ -110,13 +108,10 @@ PSvEnablePowerSaving( MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN); pDevice->bEnablePSMode = true; - if (pDevice->eOPMode == OP_MODE_ADHOC) { -// bMgrPrepareBeaconToSend((void *)pDevice, pMgmt); - } - // We don't send null pkt in ad hoc mode since beacon will handle this. - else if (pDevice->eOPMode == OP_MODE_INFRASTRUCTURE) { + /* We don't send null pkt in ad hoc mode since beacon will handle this. */ + if (pDevice->eOPMode != OP_MODE_ADHOC && pDevice->eOPMode == OP_MODE_INFRASTRUCTURE) PSbSendNullPacket(pDevice); - } + pDevice->bPWBitOn = true; DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "PS:Power Saving Mode Enable... \n"); return; @@ -138,7 +133,6 @@ PSvDisablePowerSaving( ) { PSDevice pDevice = (PSDevice)hDeviceContext; -// PSMgmtObject pMgmt = pDevice->pMgmt; // disable power saving hw function MACbPSWakeup(pDevice->PortOffset); @@ -258,8 +252,6 @@ PSvSendPSPOLL( // send the frame if (csMgmt_xmit(pDevice, pTxPacket) != CMD_STATUS_PENDING) { DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Send PS-Poll packet failed..\n"); - } else { -// DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Send PS-Poll packet success..\n"); } return; @@ -336,8 +328,6 @@ PSbSendNullPacket( if (csMgmt_xmit(pDevice, pTxPacket) != CMD_STATUS_PENDING) { DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Send Null Packet failed !\n"); return false; - } else { -// DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "Send Null Packet success....\n"); } return true; -- cgit v1.1