staging: vt6655: Fix issue of byPacketType is not set at all.
authorMalcolm Priestley <tvboxspy@gmail.com>
Thu, 6 Nov 2014 20:02:05 +0000 (20:02 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 7 Nov 2014 17:23:29 +0000 (09:23 -0800)
set by calling CARDbyGetPktType.

change CARDbIsOFDMinBasicRate to check basic_rates.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/vt6655/card.c

index 1869557..aaa7289 100644 (file)
@@ -342,6 +342,8 @@ bool CARDbSetPhyParameter(struct vnt_private *pDevice, CARD_PHY_TYPE ePHYType,
                VNSvOutPortB(pDevice->PortOffset + MAC_REG_CWMAXMIN0, pDevice->byCWMaxMin);
        }
 
+       pDevice->byPacketType = CARDbyGetPktType(pDevice);
+
        CARDvSetRSPINF(pDevice, ePHYType);
 
        return true;
@@ -876,7 +878,7 @@ bool CARDbIsOFDMinBasicRate(struct vnt_private *pDevice)
        int ii;
 
        for (ii = RATE_54M; ii >= RATE_6M; ii--) {
-               if ((pDevice->wBasicRate) & ((unsigned short)(1 << ii)))
+               if ((pDevice->basic_rates) & ((u32)(1 << ii)))
                        return true;
        }
        return false;