staging: vt6655: Fix loss of distant/weak access points on channel change.

If the asssocated access point is strong byBBVGACurrent will be adjusted
accordingly.

Users will nolonger see distant access points without taking down interface.

When changing channel reset byBBVGACurrent back to pDevice->abyBBVGA[0] for
max sensitivity.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Malcolm Priestley 2014-12-21 12:56:35 +00:00 committed by Greg Kroah-Hartman
parent b5745290af
commit 3a9dda7925

View File

@ -182,6 +182,14 @@ bool set_channel(void *pDeviceHandler, unsigned int uConnectionChannel)
if (pDevice->byCurrentCh == uConnectionChannel)
return bResult;
/* Set VGA to max sensitivity */
if (pDevice->bUpdateBBVGA &&
pDevice->byBBVGACurrent != pDevice->abyBBVGA[0]) {
pDevice->byBBVGACurrent = pDevice->abyBBVGA[0];
BBvSetVGAGainOffset(pDevice, pDevice->byBBVGACurrent);
}
/* clear NAV */
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_MACCR, MACCR_CLRNAV);