diff options
Diffstat (limited to 'drivers/staging/vt6656/mac.c')
-rw-r--r-- | drivers/staging/vt6656/mac.c | 83 |
1 files changed, 41 insertions, 42 deletions
diff --git a/drivers/staging/vt6656/mac.c b/drivers/staging/vt6656/mac.c index 8fddc7b3930b..dd732bcb9092 100644 --- a/drivers/staging/vt6656/mac.c +++ b/drivers/staging/vt6656/mac.c @@ -68,11 +68,11 @@ static int msglevel =MSG_LEVEL_INFO; * Return Value: none * */ -void MACvSetMultiAddrByHash (PSDevice pDevice, BYTE byHashIdx) +void MACvSetMultiAddrByHash(struct vnt_private *pDevice, u8 byHashIdx) { - unsigned int uByteIdx; - BYTE byBitMask; - BYTE pbyData[2]; + u8 uByteIdx; + u8 byBitMask; + u8 pbyData[2]; // calculate byte position @@ -110,9 +110,9 @@ void MACvSetMultiAddrByHash (PSDevice pDevice, BYTE byHashIdx) * Return Value: none * */ -void MACvWriteMultiAddr(PSDevice pDevice, unsigned int uByteIdx, BYTE byData) +void MACvWriteMultiAddr(struct vnt_private *pDevice, u32 uByteIdx, u8 byData) { - BYTE byData1; + u8 byData1; byData1 = byData; CONTROLnsRequestOut(pDevice, @@ -135,7 +135,7 @@ void MACvWriteMultiAddr(PSDevice pDevice, unsigned int uByteIdx, BYTE byData) * * */ -void MACbShutdown(PSDevice pDevice) +void MACbShutdown(struct vnt_private *pDevice) { CONTROLnsRequestOutAsyn(pDevice, MESSAGE_TYPE_MACSHUTDOWN, @@ -146,9 +146,9 @@ void MACbShutdown(PSDevice pDevice) ); } -void MACvSetBBType(PSDevice pDevice,BYTE byType) +void MACvSetBBType(struct vnt_private *pDevice, u8 byType) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = byType; @@ -163,9 +163,9 @@ BYTE pbyData[2]; ); } -void MACvSetMISCFifo (PSDevice pDevice, WORD wOffset, DWORD dwData) +void MACvSetMISCFifo(struct vnt_private *pDevice, u16 wOffset, u32 dwData) { -BYTE pbyData[4]; + u8 pbyData[4]; if (wOffset > 273) return; @@ -197,10 +197,10 @@ BYTE pbyData[4]; * Return Value: none * */ -void MACvDisableKeyEntry(PSDevice pDevice, unsigned int uEntryIdx) +void MACvDisableKeyEntry(struct vnt_private *pDevice, u32 uEntryIdx) { -WORD wOffset; -BYTE byData; + u16 wOffset; + u8 byData; byData = (BYTE) uEntryIdx; @@ -237,15 +237,14 @@ BYTE byData; * Return Value: none * */ -void MACvSetKeyEntry(PSDevice pDevice, WORD wKeyCtl, - unsigned int uEntryIdx, unsigned int uKeyIdx, - PBYTE pbyAddr, PDWORD pdwKey) +void MACvSetKeyEntry(struct vnt_private *pDevice, u16 wKeyCtl, u32 uEntryIdx, + u32 uKeyIdx, u8 *pbyAddr, u32 *pdwKey) { -PBYTE pbyKey; -WORD wOffset; -DWORD dwData1,dwData2; -int ii; -BYTE pbyData[24]; + u8 *pbyKey; + u16 wOffset; + u32 dwData1, dwData2; + int ii; + u8 pbyData[24]; if ( pDevice->byLocalID <= MAC_REVISION_A1 ) { if ( pDevice->sMgmtObj.byCSSPK == KEY_CTL_CCMP ) @@ -321,9 +320,9 @@ BYTE pbyData[24]; } -void MACvRegBitsOff(PSDevice pDevice, BYTE byRegOfs, BYTE byBits) +void MACvRegBitsOff(struct vnt_private *pDevice, u8 byRegOfs, u8 byBits) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = 0; pbyData[1] = byBits; @@ -338,9 +337,9 @@ BYTE pbyData[2]; } -void MACvRegBitsOn(PSDevice pDevice, BYTE byRegOfs, BYTE byBits) +void MACvRegBitsOn(struct vnt_private *pDevice, u8 byRegOfs, u8 byBits) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = byBits; @@ -355,9 +354,9 @@ BYTE pbyData[2]; ); } -void MACvWriteWord(PSDevice pDevice, BYTE byRegOfs, WORD wData) +void MACvWriteWord(struct vnt_private *pDevice, u8 byRegOfs, u16 wData) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = (BYTE)(wData & 0xff); @@ -373,9 +372,9 @@ BYTE pbyData[2]; } -void MACvWriteBSSIDAddress(PSDevice pDevice, PBYTE pbyEtherAddr) +void MACvWriteBSSIDAddress(struct vnt_private *pDevice, u8 *pbyEtherAddr) { -BYTE pbyData[6]; + u8 pbyData[6]; pbyData[0] = *((PBYTE)pbyEtherAddr); @@ -394,9 +393,9 @@ BYTE pbyData[6]; ); } -void MACvEnableProtectMD(PSDevice pDevice) +void MACvEnableProtectMD(struct vnt_private *pDevice) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = EnCFG_ProtectMd; @@ -411,9 +410,9 @@ BYTE pbyData[2]; ); } -void MACvDisableProtectMD(PSDevice pDevice) +void MACvDisableProtectMD(struct vnt_private *pDevice) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = 0; @@ -428,9 +427,9 @@ BYTE pbyData[2]; ); } -void MACvEnableBarkerPreambleMd(PSDevice pDevice) +void MACvEnableBarkerPreambleMd(struct vnt_private *pDevice) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = EnCFG_BarkerPream; @@ -445,9 +444,9 @@ BYTE pbyData[2]; ); } -void MACvDisableBarkerPreambleMd(PSDevice pDevice) +void MACvDisableBarkerPreambleMd(struct vnt_private *pDevice) { -BYTE pbyData[2]; + u8 pbyData[2]; pbyData[0] = 0; @@ -463,12 +462,12 @@ BYTE pbyData[2]; } -void MACvWriteBeaconInterval(PSDevice pDevice, WORD wInterval) +void MACvWriteBeaconInterval(struct vnt_private *pDevice, u16 wInterval) { -BYTE pbyData[2]; + u8 pbyData[2]; - pbyData[0] = (BYTE) (wInterval & 0xff); - pbyData[1] = (BYTE) (wInterval >> 8); + pbyData[0] = (u8)(wInterval & 0xff); + pbyData[1] = (u8)(wInterval >> 8); CONTROLnsRequestOut(pDevice, MESSAGE_TYPE_WRITE, |