diff options
author | Charles Clément <caratorn@gmail.com> | 2010-06-24 11:02:25 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-06-24 14:23:17 -0700 |
commit | 0f4c60d61e9c10a0733eacd650c101189bdf75cd (patch) | |
tree | 88cd18c474739648e45ec68e303c0f7351ee546c /drivers/staging/vt6655 | |
parent | 17701d14b613b8495cdd8b803c22d3f33d1face8 (diff) |
Staging: vt6655: remove DWORD typedef
Replace all occurrences with unsigned long type, except for pointer fields that
should be u32 in packed structures and 8-byte-aligned 8 byte long structure
QWORD.
Thanks to Jiri Slaby for pointing out that simply replacing by unsigned long is
wrong on x86-64 arch.
Signed-off-by: Charles Clément <caratorn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/vt6655')
32 files changed, 308 insertions, 309 deletions
diff --git a/drivers/staging/vt6655/bssdb.h b/drivers/staging/vt6655/bssdb.h index 9f197c3bb57..af06c941110 100644 --- a/drivers/staging/vt6655/bssdb.h +++ b/drivers/staging/vt6655/bssdb.h @@ -207,15 +207,15 @@ typedef struct tagKnownNodeDB { BYTE byAuthSequence; unsigned long ulLastRxJiffer; BYTE bySuppRate; - DWORD dwFlags; + unsigned long dwFlags; WORD wEnQueueCnt; BOOL bOnFly; unsigned long long KeyRSC; BYTE byKeyIndex; - DWORD dwKeyIndex; + unsigned long dwKeyIndex; BYTE byCipherSuite; - DWORD dwTSC47_16; + unsigned long dwTSC47_16; WORD wTSC15_0; unsigned int uWepKeyLength; BYTE abyWepKey[WLAN_WEPMAX_KEYLEN]; diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c index 747f8d3d142..3997206668c 100644 --- a/drivers/staging/vt6655/card.c +++ b/drivers/staging/vt6655/card.c @@ -1336,7 +1336,7 @@ CARDbSetQuiet ( pDevice->sQuiet[pDevice->uQuietEnqueue].bEnable = TRUE; pDevice->sQuiet[pDevice->uQuietEnqueue].byPeriod = byQuietPeriod; pDevice->sQuiet[pDevice->uQuietEnqueue].wDuration = wQuietDuration; - pDevice->sQuiet[pDevice->uQuietEnqueue].dwStartTime = (DWORD) byQuietCount; + pDevice->sQuiet[pDevice->uQuietEnqueue].dwStartTime = (unsigned long) byQuietCount; pDevice->sQuiet[pDevice->uQuietEnqueue].dwStartTime *= pDevice->wBeaconInterval; pDevice->sQuiet[pDevice->uQuietEnqueue].dwStartTime += wQuietOffset; pDevice->uQuietEnqueue++; @@ -1372,11 +1372,11 @@ CARDbStartQuiet ( { PSDevice pDevice = (PSDevice) pDeviceHandler; unsigned int ii = 0; - DWORD dwStartTime = 0xFFFFFFFF; + unsigned long dwStartTime = 0xFFFFFFFF; unsigned int uCurrentQuietIndex = 0; - DWORD dwNextTime = 0; - DWORD dwGap = 0; - DWORD dwDuration = 0; + unsigned long dwNextTime = 0; + unsigned long dwGap = 0; + unsigned long dwDuration = 0; for(ii=0;ii<MAX_QUIET_COUNT;ii++) { if ((pDevice->sQuiet[ii].bEnable == TRUE) && @@ -1434,7 +1434,7 @@ CARDbStartQuiet ( pDevice->sQuiet[uCurrentQuietIndex].bEnable = FALSE; } else { // set next period start time - dwNextTime = (DWORD) pDevice->sQuiet[uCurrentQuietIndex].byPeriod; + dwNextTime = (unsigned long) pDevice->sQuiet[uCurrentQuietIndex].byPeriod; dwNextTime *= pDevice->wBeaconInterval; pDevice->sQuiet[uCurrentQuietIndex].dwStartTime = dwNextTime; } @@ -2063,8 +2063,8 @@ QWORD CARDqGetTSFOffset (BYTE byRxRate, QWORD qwTSF1, QWORD qwTSF2) HIDWORD(qwTSFOffset) = 0; LODWORD(qwTSFOffset) = 0; wRxBcnTSFOffst = cwRXBCNTSFOff[byRxRate%MAX_RATE]; - (qwTSF2).u.dwLowDword += (DWORD)(wRxBcnTSFOffst); - if ((qwTSF2).u.dwLowDword < (DWORD)(wRxBcnTSFOffst)) { + (qwTSF2).u.dwLowDword += (unsigned long)(wRxBcnTSFOffst); + if ((qwTSF2).u.dwLowDword < (unsigned long)(wRxBcnTSFOffst)) { (qwTSF2).u.dwHighDword++; } LODWORD(qwTSFOffset) = LODWORD(qwTSF1) - LODWORD(qwTSF2); diff --git a/drivers/staging/vt6655/datarate.c b/drivers/staging/vt6655/datarate.c index 4be933c0ad0..2a5acbea8fc 100644 --- a/drivers/staging/vt6655/datarate.c +++ b/drivers/staging/vt6655/datarate.c @@ -316,12 +316,12 @@ RATEvTxRateFallBack ( PSDevice pDevice = (PSDevice) pDeviceHandler; WORD wIdxDownRate = 0; unsigned int ii; -//DWORD dwRateTable[MAX_RATE] = {1, 2, 5, 11, 6, 9, 12, 18, 24, 36, 48, 54}; +//unsigned long dwRateTable[MAX_RATE] = {1, 2, 5, 11, 6, 9, 12, 18, 24, 36, 48, 54}; BOOL bAutoRate[MAX_RATE] = {TRUE,TRUE,TRUE,TRUE,FALSE,FALSE,TRUE,TRUE,TRUE,TRUE,TRUE,TRUE}; -DWORD dwThroughputTbl[MAX_RATE] = {10, 20, 55, 110, 60, 90, 120, 180, 240, 360, 480, 540}; -DWORD dwThroughput = 0; + unsigned long dwThroughputTbl[MAX_RATE] = {10, 20, 55, 110, 60, 90, 120, 180, 240, 360, 480, 540}; + unsigned long dwThroughput = 0; WORD wIdxUpRate = 0; -DWORD dwTxDiff = 0; + unsigned long dwTxDiff = 0; if (pDevice->pMgmt->eScanState != WMAC_NO_SCANNING) { // Don't do Fallback when scanning Channel diff --git a/drivers/staging/vt6655/desc.h b/drivers/staging/vt6655/desc.h index 9894d9e2e28..94ccfce8418 100644 --- a/drivers/staging/vt6655/desc.h +++ b/drivers/staging/vt6655/desc.h @@ -354,8 +354,8 @@ typedef struct tagDEVICE_TD_INFO{ dma_addr_t skb_dma; dma_addr_t buf_dma; dma_addr_t curr_desc; - DWORD dwReqCount; - DWORD dwHeaderLength; + unsigned long dwReqCount; + unsigned long dwHeaderLength; BYTE byFlags; } DEVICE_TD_INFO, *PDEVICE_TD_INFO; @@ -391,13 +391,13 @@ typedef const STxDesc *PCSTxDesc; typedef struct tagSTxSyncDesc { volatile STDES0 m_td0TD0; volatile STDES1 m_td1TD1; - volatile DWORD buff_addr; // pointer to logical buffer - volatile DWORD next_desc; // pointer to next logical descriptor + volatile u32 buff_addr; // pointer to logical buffer + volatile u32 next_desc; // pointer to next logical descriptor volatile WORD m_wFIFOCtl; volatile WORD m_wTimeStamp; struct tagSTxSyncDesc* next; //4 bytes volatile PDEVICE_TD_INFO pTDInfo;//4 bytes - volatile DWORD m_dwReserved2; + volatile u32 m_dwReserved2; } __attribute__ ((__packed__)) STxSyncDesc, *PSTxSyncDesc; typedef const STxSyncDesc *PCSTxSyncDesc; @@ -556,7 +556,7 @@ typedef const SCTS_FB *PCSCTS_FB; // Tx FIFO header // typedef struct tagSTxBufHead { - DWORD adwTxKey[4]; + u32 adwTxKey[4]; WORD wFIFOCtl; WORD wTimeStamp; WORD wFragCtl; @@ -636,24 +636,24 @@ typedef const STxDataHead_a_FB *PCSTxDataHead_a_FB; // MICHDR data header // typedef struct tagSMICHDRHead { - DWORD adwHDR0[4]; - DWORD adwHDR1[4]; - DWORD adwHDR2[4]; + u32 adwHDR0[4]; + u32 adwHDR1[4]; + u32 adwHDR2[4]; }__attribute__ ((__packed__)) SMICHDRHead, *PSMICHDRHead; typedef const SMICHDRHead *PCSMICHDRHead; typedef struct tagSBEACONCtl { - DWORD BufReady : 1; - DWORD TSF : 15; - DWORD BufLen : 11; - DWORD Reserved : 5; + u32 BufReady : 1; + u32 TSF : 15; + u32 BufLen : 11; + u32 Reserved : 5; }__attribute__ ((__packed__)) SBEACONCtl; typedef struct tagSSecretKey { - DWORD dwLowDword; + u32 dwLowDword; BYTE byHighByte; }__attribute__ ((__packed__)) SSecretKey; @@ -662,11 +662,11 @@ typedef struct tagSKeyEntry { BYTE abyAddrHi[2]; WORD wKCTL; BYTE abyAddrLo[4]; - DWORD dwKey0[4]; - DWORD dwKey1[4]; - DWORD dwKey2[4]; - DWORD dwKey3[4]; - DWORD dwKey4[4]; + u32 dwKey0[4]; + u32 dwKey1[4]; + u32 dwKey2[4]; + u32 dwKey3[4]; + u32 dwKey4[4]; }__attribute__ ((__packed__)) SKeyEntry; /*--------------------- Export Macros ------------------------------*/ diff --git a/drivers/staging/vt6655/device.h b/drivers/staging/vt6655/device.h index bad32562a7f..39f67007d3c 100644 --- a/drivers/staging/vt6655/device.h +++ b/drivers/staging/vt6655/device.h @@ -280,7 +280,7 @@ typedef struct tagSPMKIDCandidateEvent { typedef struct tagSQuietControl { BOOL bEnable; - DWORD dwStartTime; + unsigned long dwStartTime; BYTE byPeriod; WORD wDuration; } SQuietControl, *PSQuietControl; @@ -424,7 +424,7 @@ typedef struct __device_info { CHIP_TYPE chip_id; unsigned long PortOffset; - DWORD dwIsr; + unsigned long dwIsr; u32 memaddr; u32 ioaddr; u32 io_size; @@ -500,8 +500,8 @@ typedef struct __device_info { unsigned int uCurrRSSI; BYTE byCurrSQ; - DWORD dwTxAntennaSel; - DWORD dwRxAntennaSel; + unsigned long dwTxAntennaSel; + unsigned long dwRxAntennaSel; BYTE byAntennaCount; BYTE byRxAntennaMode; BYTE byTxAntennaMode; @@ -554,7 +554,7 @@ typedef struct __device_info { BYTE byRTSServiceField; // update while speed change BYTE byRTSSignalField; // update while speed change - DWORD dwMaxReceiveLifetime; // dot11MaxReceiveLifetime + unsigned long dwMaxReceiveLifetime; // dot11MaxReceiveLifetime BOOL bCCK; BOOL bEncryptionEnable; @@ -626,7 +626,7 @@ typedef struct __device_info { NDIS_802_11_WEP_STATUS eOldEncryptionStatus; SKeyManagement sKey; - DWORD dwIVCounter; + unsigned long dwIVCounter; QWORD qwPacketNumber; //For CCMP and TKIP as TSC(6 bytes) unsigned int uCurrentWEPMode; @@ -673,7 +673,7 @@ typedef struct __device_info { BOOL bRadioCmd; - DWORD dwDiagRefCount; + unsigned long dwDiagRefCount; // For FOE Tuning BYTE byFOETuning; @@ -756,7 +756,7 @@ typedef struct __device_info { BYTE abyBroadcastAddr[ETH_ALEN]; BYTE abySNAP_RFC1042[ETH_ALEN]; BYTE abySNAP_Bridgetunnel[ETH_ALEN]; - BYTE abyEEPROM[EEP_MAX_CONTEXT_SIZE]; //DWORD alignment + BYTE abyEEPROM[EEP_MAX_CONTEXT_SIZE]; //unsigned long alignment // Pre-Authentication & PMK cache SPMKID gsPMKID; SPMKIDCandidateEvent gsPMKIDCandidate; @@ -771,12 +771,12 @@ typedef struct __device_info { BOOL bMeasureInProgress; BYTE byOrgChannel; BYTE byOrgRCR; - DWORD dwOrgMAR0; - DWORD dwOrgMAR4; + unsigned long dwOrgMAR0; + unsigned long dwOrgMAR4; BYTE byBasicMap; BYTE byCCAFraction; BYTE abyRPIs[8]; - DWORD dwRPIs[8]; + unsigned long dwRPIs[8]; BOOL bChannelSwitch; BYTE byNewChannel; BYTE byChannelSwitchCount; @@ -784,7 +784,7 @@ typedef struct __device_info { BOOL bEnableFirstQuiet; BYTE byQuietStartCount; unsigned int uQuietEnqueue; - DWORD dwCurrentQuietEndTime; + unsigned long dwCurrentQuietEndTime; SQuietControl sQuiet[MAX_QUIET_COUNT]; // for 802.11h TPC BOOL bCountryInfo5G; diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c index 090cc94b250..1451bdc08d3 100644 --- a/drivers/staging/vt6655/device_main.c +++ b/drivers/staging/vt6655/device_main.c @@ -134,10 +134,10 @@ DEVICE_PARAM(TxDescriptors1,"Number of transmit descriptors1"); #define IP_ALIG_DEF 0 -/* IP_byte_align[] is used for IP header DWORD byte aligned - 0: indicate the IP header won't be DWORD byte aligned.(Default) . - 1: indicate the IP header will be DWORD byte aligned. - In some enviroment, the IP header should be DWORD byte aligned, +/* IP_byte_align[] is used for IP header unsigned long byte aligned + 0: indicate the IP header won't be unsigned long byte aligned.(Default) . + 1: indicate the IP header will be unsigned long byte aligned. + In some enviroment, the IP header should be unsigned long byte aligned, or the packet will be droped when we receive it. (eg: IPVS) */ DEVICE_PARAM(IP_byte_align,"Enable IP header dword aligned"); @@ -483,7 +483,7 @@ pDevice->bUpdateBBVGA = TRUE; static void s_vCompleteCurrentMeasure (PSDevice pDevice, BYTE byResult) { unsigned int ii; - DWORD dwDuration = 0; + unsigned long dwDuration = 0; BYTE byRPI0 = 0; for(ii=1;ii<8;ii++) { @@ -1022,8 +1022,8 @@ vt6655_probe(struct pci_dev *pcid, const struct pci_device_id *ent) #ifdef DEBUG //return 0 ; #endif - pDevice->PortOffset = (DWORD)ioremap(pDevice->memaddr & PCI_BASE_ADDRESS_MEM_MASK, pDevice->io_size); - //pDevice->PortOffset = (DWORD)ioremap(pDevice->ioaddr & PCI_BASE_ADDRESS_IO_MASK, pDevice->io_size); + pDevice->PortOffset = (unsigned long)ioremap(pDevice->memaddr & PCI_BASE_ADDRESS_MEM_MASK, pDevice->io_size); + //pDevice->PortOffset = (unsigned long)ioremap(pDevice->ioaddr & PCI_BASE_ADDRESS_IO_MASK, pDevice->io_size); if(pDevice->PortOffset == 0) { printk(KERN_ERR DEVICE_NAME ": Failed to IO remapping ..\n"); @@ -1996,7 +1996,7 @@ DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "call device_init_registers\n"); // Patch: if WEP key already set by iwconfig but device not yet open if ((pDevice->bEncryptionEnable == TRUE) && (pDevice->bTransmitKey == TRUE)) { KeybSetDefaultKey(&(pDevice->sKey), - (DWORD)(pDevice->byKeyIndex | (1 << 31)), + (unsigned long)(pDevice->byKeyIndex | (1 << 31)), pDevice->uKeyLength, NULL, pDevice->abyKey, @@ -2677,7 +2677,7 @@ static irqreturn_t device_intr(int irq, void *dev_instance) { PSDevice pDevice=(PSDevice) netdev_priv(dev); int max_count=0; - DWORD dwMIBCounter=0; + unsigned long dwMIBCounter=0; PSMgmtObject pMgmt = pDevice->pMgmt; BYTE byOrgPageSel=0; int handled = 0; diff --git a/drivers/staging/vt6655/dpc.c b/drivers/staging/vt6655/dpc.c index 3f3f83a8319..e994f0a9dd1 100644 --- a/drivers/staging/vt6655/dpc.c +++ b/drivers/staging/vt6655/dpc.c @@ -371,10 +371,10 @@ device_receive_frame ( unsigned int cbHeaderSize; PSKeyItem pKey = NULL; WORD wRxTSC15_0 = 0; - DWORD dwRxTSC47_16 = 0; + unsigned long dwRxTSC47_16 = 0; SKeyItem STempKey; // 802.11h RPI - DWORD dwDuration = 0; + unsigned long dwDuration = 0; long ldBm = 0; long ldBmThreshold = 0; PS802_11Header pMACHeader; @@ -802,10 +802,10 @@ device_receive_frame ( if (bIsWEP) { unsigned long *pdwMIC_L; unsigned long *pdwMIC_R; - DWORD dwMIC_Priority; - DWORD dwMICKey0 = 0, dwMICKey1 = 0; - DWORD dwLocalMIC_L = 0; - DWORD dwLocalMIC_R = 0; + unsigned long dwMIC_Priority; + unsigned long dwMICKey0 = 0, dwMICKey1 = 0; + unsigned long dwLocalMIC_L = 0; + unsigned long dwLocalMIC_R = 0; viawget_wpa_header *wpahdr; @@ -918,12 +918,12 @@ device_receive_frame ( (pKey->byCipherSuite == KEY_CTL_CCMP))) { if (bIsWEP) { WORD wLocalTSC15_0 = 0; - DWORD dwLocalTSC47_16 = 0; + unsigned long dwLocalTSC47_16 = 0; unsigned long long RSC = 0; // endian issues RSC = *((unsigned long long *) &(pKey->KeyRSC)); wLocalTSC15_0 = (WORD) RSC; - dwLocalTSC47_16 = (DWORD) (RSC>>16); + dwLocalTSC47_16 = (unsigned long) (RSC>>16); RSC = dwRxTSC47_16; RSC <<= 16; diff --git a/drivers/staging/vt6655/hostap.c b/drivers/staging/vt6655/hostap.c index 8faeb6e8a2f..1c512cede3d 100644 --- a/drivers/staging/vt6655/hostap.c +++ b/drivers/staging/vt6655/hostap.c @@ -471,7 +471,7 @@ static int hostap_set_encryption(PSDevice pDevice, int param_len) { PSMgmtObject pMgmt = pDevice->pMgmt; - DWORD dwKeyIndex = 0; + unsigned long dwKeyIndex = 0; BYTE abyKey[MAX_KEY_LEN]; BYTE abySeq[MAX_KEY_LEN]; NDIS_802_11_KEY_RSC KeyRSC; @@ -553,7 +553,7 @@ static int hostap_set_encryption(PSDevice pDevice, param->u.crypt.key_len ); - dwKeyIndex = (DWORD)(param->u.crypt.idx); + dwKeyIndex = (unsigned long)(param->u.crypt.idx); if (param->u.crypt.flags & HOSTAP_CRYPT_FLAG_SET_TX_KEY) { pDevice->byKeyIndex = (BYTE)dwKeyIndex; pDevice->bTransmitKey = TRUE; diff --git a/drivers/staging/vt6655/ioctl.c b/drivers/staging/vt6655/ioctl.c index 210ad80a329..9af6c236c88 100644 --- a/drivers/staging/vt6655/ioctl.c +++ b/drivers/staging/vt6655/ioctl.c @@ -77,7 +77,7 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq) { SCmdLinkStatus sLinkStatus; BYTE abySuppRates[] = {WLAN_EID_SUPP_RATES, 4, 0x02, 0x04, 0x0B, 0x16}; BYTE abyNullAddr[] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; - DWORD dwKeyIndex= 0; + unsigned long dwKeyIndex= 0; BYTE abyScanSSID[WLAN_IEHDR_LEN + WLAN_SSID_MAXLEN + 1]; long ldBm; @@ -717,7 +717,7 @@ if(wpa_Result.authenticated==TRUE) { void vConfigWEPKey ( PSDevice pDevice, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned char *pbyKey, unsigned long uKeyLength ) diff --git a/drivers/staging/vt6655/ioctl.h b/drivers/staging/vt6655/ioctl.h index 0de2324d15d..ba85015c11b 100644 --- a/drivers/staging/vt6655/ioctl.h +++ b/drivers/staging/vt6655/ioctl.h @@ -45,7 +45,7 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq); /* void vConfigWEPKey ( PSDevice pDevice, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned char *pbyKey, unsigned long uKeyLength ); diff --git a/drivers/staging/vt6655/iwctl.c b/drivers/staging/vt6655/iwctl.c index f3545071151..31e9d6feeda 100644 --- a/drivers/staging/vt6655/iwctl.c +++ b/drivers/staging/vt6655/iwctl.c @@ -1294,7 +1294,7 @@ int iwctl_siwencode(struct net_device *dev, { PSDevice pDevice = (PSDevice)netdev_priv(dev); PSMgmtObject pMgmt = &(pDevice->sMgmtObj); - DWORD dwKeyIndex = (DWORD)(wrq->flags & IW_ENCODE_INDEX); + unsigned long dwKeyIndex = (unsigned long)(wrq->flags & IW_ENCODE_INDEX); int ii,uu, rc = 0; int index = (wrq->flags & IW_ENCODE_INDEX); @@ -1358,7 +1358,7 @@ if((wrq->flags & IW_ENCODE_DISABLED)==0){ if (pDevice->flags & DEVICE_FLAGS_OPENED) { spin_lock_irq(&pDevice->lock); KeybSetDefaultKey(&(pDevice->sKey), - (DWORD)(dwKeyIndex | (1 << 31)), + (unsigned long)(dwKeyIndex | (1 << 31)), wrq->length, NULL, pDevice->abyKey, @@ -1450,7 +1450,7 @@ if((wrq->flags & IW_ENCODE_DISABLED)==0){ if (pDevice->flags & DEVICE_FLAGS_OPENED) { spin_lock_irq(&pDevice->lock); KeybSetDefaultKey(&(pDevice->sKey), - (DWORD)(pDevice->byKeyIndex | (1 << 31)), + (unsigned long)(pDevice->byKeyIndex | (1 << 31)), pDevice->uKeyLength, NULL, pDevice->abyKey, diff --git a/drivers/staging/vt6655/key.c b/drivers/staging/vt6655/key.c index 3fab4d5713f..0283d0f62c4 100644 --- a/drivers/staging/vt6655/key.c +++ b/drivers/staging/vt6655/key.c @@ -134,7 +134,7 @@ void KeyvInitTable (PSKeyManagement pTable, unsigned long dwIoBase) BOOL KeybGetKey ( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, PSKeyItem *pKey ) { @@ -192,7 +192,7 @@ BOOL KeybGetKey ( BOOL KeybSetKey ( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, @@ -365,7 +365,7 @@ BOOL KeybSetKey ( BOOL KeybRemoveKey ( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long dwIoBase ) { @@ -472,7 +472,7 @@ BOOL KeybRemoveAllKey ( */ void KeyvRemoveWEPKey ( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long dwIoBase ) { @@ -520,7 +520,7 @@ void KeyvRemoveAllWEPKey ( BOOL KeybGetTransmitKey ( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyType, + unsigned long dwKeyType, PSKeyItem *pKey ) { @@ -633,7 +633,7 @@ BOOL KeybCheckPairewiseKey ( */ BOOL KeybSetDefaultKey ( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, @@ -740,7 +740,7 @@ BOOL KeybSetDefaultKey ( */ BOOL KeybSetAllGroupKey ( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, diff --git a/drivers/staging/vt6655/key.h b/drivers/staging/vt6655/key.h index c9179e82e08..1af72895cd2 100644 --- a/drivers/staging/vt6655/key.h +++ b/drivers/staging/vt6655/key.h @@ -61,11 +61,11 @@ typedef struct tagSKeyItem unsigned long uKeyLength; BYTE abyKey[MAX_KEY_LEN]; QWORD KeyRSC; - DWORD dwTSC47_16; + unsigned long dwTSC47_16; WORD wTSC15_0; BYTE byCipherSuite; BYTE byReserved0; - DWORD dwKeyIndex; + unsigned long dwKeyIndex; void *pvKeyTable; } SKeyItem, *PSKeyItem; //64 @@ -75,7 +75,7 @@ typedef struct tagSKeyTable BYTE byReserved0[2]; //8 SKeyItem PairwiseKey; SKeyItem GroupKey[MAX_GROUP_KEY]; //64*5 = 320, 320+8=328 - DWORD dwGTKeyIndex; // GroupTransmitKey Index + unsigned long dwGTKeyIndex; // GroupTransmitKey Index BOOL bInUse; //2006-1116-01,<Modify> by NomadZhao //WORD wKeyCtl; @@ -106,14 +106,14 @@ void KeyvInitTable(PSKeyManagement pTable, unsigned long dwIoBase); BOOL KeybGetKey( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, PSKeyItem *pKey ); BOOL KeybSetKey( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, @@ -124,7 +124,7 @@ BOOL KeybSetKey( BOOL KeybSetDefaultKey( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, @@ -136,14 +136,14 @@ BOOL KeybSetDefaultKey( BOOL KeybRemoveKey( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long dwIoBase ); BOOL KeybGetTransmitKey( PSKeyManagement pTable, unsigned char *pbyBSSID, - DWORD dwKeyType, + unsigned long dwKeyType, PSKeyItem *pKey ); @@ -160,7 +160,7 @@ BOOL KeybRemoveAllKey( void KeyvRemoveWEPKey( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long dwIoBase ); @@ -171,7 +171,7 @@ void KeyvRemoveAllWEPKey( BOOL KeybSetAllGroupKey ( PSKeyManagement pTable, - DWORD dwKeyIndex, + unsigned long dwKeyIndex, unsigned long uKeyLength, PQWORD pKeyRSC, unsigned char *pbyKey, diff --git a/drivers/staging/vt6655/mac.c b/drivers/staging/vt6655/mac.c index 02616892bda..4971a03e74b 100644 --- a/drivers/staging/vt6655/mac.c +++ b/drivers/staging/vt6655/mac.c @@ -186,7 +186,7 @@ BOOL MACbIsRegBitsOff (unsigned long dwIoBase, BYTE byRegOfs, BYTE byTestBits) */ BOOL MACbIsIntDisable (unsigned long dwIoBase) { - DWORD dwData; + unsigned long dwData; VNSvInPortD(dwIoBase + MAC_REG_IMR, &dwData); if (dwData != 0) @@ -595,7 +595,7 @@ void MACvSetPacketFilter (unsigned long dwIoBase, WORD wFilterType) // set multicast address to accept none MACvSelectPage1(dwIoBase); VNSvOutPortD(dwIoBase + MAC_REG_MAR0, 0L); - VNSvOutPortD(dwIoBase + MAC_REG_MAR0 + sizeof(DWORD), 0L); + VNSvOutPortD(dwIoBase + MAC_REG_MAR0 + sizeof(unsigned long), 0L); MACvSelectPage0(dwIoBase); } @@ -603,7 +603,7 @@ void MACvSetPacketFilter (unsigned long dwIoBase, WORD wFilterType) // set multicast address to accept all MACvSelectPage1(dwIoBase); VNSvOutPortD(dwIoBase + MAC_REG_MAR0, 0xFFFFFFFFL); - VNSvOutPortD(dwIoBase + MAC_REG_MAR0 + sizeof(DWORD), 0xFFFFFFFFL); + VNSvOutPortD(dwIoBase + MAC_REG_MAR0 + sizeof(unsigned long), 0xFFFFFFFFL); MACvSelectPage0(dwIoBase); } @@ -730,7 +730,7 @@ void MACvRestoreContext (unsigned long dwIoBase, unsigned char *pbyCxtBuf) */ BOOL MACbCompareContext (unsigned long dwIoBase, unsigned char *pbyCxtBuf) { - DWORD dwData; + unsigned long dwData; // compare MAC context to determine if this is a power lost init, // return TRUE for power remaining init, return FALSE for power lost init @@ -842,7 +842,7 @@ BOOL MACbSafeSoftwareReset (unsigned long dwIoBase) BOOL MACbSafeRxOff (unsigned long dwIoBase) { WORD ww; - DWORD dwData; + unsigned long dwData; BYTE byData; // turn off wow temp for turn off Rx safely @@ -903,7 +903,7 @@ BOOL MACbSafeRxOff (unsigned long dwIoBase) BOOL MACbSafeTxOff (unsigned long dwIoBase) { WORD ww; - DWORD dwData; + unsigned long dwData; BYTE byData; // Clear TX DMA @@ -1079,7 +1079,7 @@ void MACvInitialize (unsigned long dwIoBase) * Return Value: none * */ -void MACvSetCurrRx0DescAddr (unsigned long dwIoBase, DWORD dwCurrDescAddr) +void MACvSetCurrRx0DescAddr (unsigned long dwIoBase, unsigned long dwCurrDescAddr) { WORD ww; BYTE byData; @@ -1117,7 +1117,7 @@ BYTE byOrgDMACtl; * Return Value: none * */ -void MACvSetCurrRx1DescAddr (unsigned long dwIoBase, DWORD dwCurrDescAddr) +void MACvSetCurrRx1DescAddr (unsigned long dwIoBase, unsigned long dwCurrDescAddr) { WORD ww; BYTE byData; @@ -1155,7 +1155,7 @@ BYTE byOrgDMACtl; * Return Value: none * */ -void MACvSetCurrTx0DescAddrEx (unsigned long dwIoBase, DWORD dwCurrDescAddr) +void MACvSetCurrTx0DescAddrEx (unsigned long dwIoBase, unsigned long dwCurrDescAddr) { WORD ww; BYTE byData; @@ -1194,7 +1194,7 @@ BYTE byOrgDMACtl; * */ //TxDMA1 = AC0DMA -void MACvSetCurrAC0DescAddrEx (unsigned long dwIoBase, DWORD dwCurrDescAddr) +void MACvSetCurrAC0DescAddrEx (unsigned long dwIoBase, unsigned long dwCurrDescAddr) { WORD ww; BYTE byData; @@ -1221,7 +1221,7 @@ BYTE byOrgDMACtl; -void MACvSetCurrTXDescAddr (int iTxType, unsigned long dwIoBase, DWORD dwCurrDescAddr) +void MACvSetCurrTXDescAddr (int iTxType, unsigned long dwIoBase, unsigned long dwCurrDescAddr) { if(iTxType == TYPE_AC0DMA){ MACvSetCurrAC0DescAddrEx(dwIoBase, dwCurrDescAddr); @@ -1309,7 +1309,7 @@ void MACvOneShotTimer1MicroSec (unsigned long dwIoBase, unsigned int uDelayTime) } -void MACvSetMISCFifo (unsigned long dwIoBase, WORD wOffset, DWORD dwData) +void MACvSetMISCFifo (unsigned long dwIoBase, WORD wOffset, unsigned long dwData) { if (wOffset > 273) return; @@ -1349,7 +1349,7 @@ unsigned int ww = 0; void MACvClearBusSusInd (unsigned long dwIoBase) { - DWORD dwOrgValue; + unsigned long dwOrgValue; unsigned int ww; // check if BcnSusInd enabled VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); @@ -1372,7 +1372,7 @@ void MACvClearBusSusInd (unsigned long dwIoBase) void MACvEnableBusSusEn (unsigned long dwIoBase) { BYTE byOrgValue; - DWORD dwOrgValue; + unsigned long dwOrgValue; unsigned int ww; // check if BcnSusInd enabled VNSvInPortB(dwIoBase + MAC_REG_CFG , &byOrgValue); @@ -1459,7 +1459,7 @@ void MACvSetKeyEntry (unsigned long dwIoBase, WORD wKeyCtl, unsigned int uEntryI unsigned int uKeyIdx, unsigned char *pbyAddr, unsigned long *pdwKey, BYTE byLocalID) { WORD wOffset; -DWORD dwData; +unsigned long dwData; int ii; if (byLocalID <= 1) @@ -1554,7 +1554,7 @@ void MACvSetDefaultKeyEntry (unsigned long dwIoBase, unsigned int uKeyLen, unsigned int uKeyIdx, unsigned long *pdwKey, BYTE byLocalID) { WORD wOffset; -DWORD dwData; +unsigned long dwData; int ii; if (byLocalID <= 1) @@ -1604,7 +1604,7 @@ int ii; void MACvEnableDefaultKey (unsigned long dwIoBase, BYTE byLocalID) { WORD wOffset; -DWORD dwData; +unsigned long dwData; if (byLocalID <= 1) @@ -1639,7 +1639,7 @@ DWORD dwData; void MACvDisableDefaultKey (unsigned long dwIoBase) { WORD wOffset; -DWORD dwData; +unsigned long dwData; wOffset = MISCFIFO_KEYETRY0; @@ -1670,7 +1670,7 @@ void MACvSetDefaultTKIPKeyEntry (unsigned long dwIoBase, unsigned int uKeyLen, unsigned int uKeyIdx, unsigned long *pdwKey, BYTE byLocalID) { WORD wOffset; -DWORD dwData; +unsigned long dwData; int ii; if (byLocalID <= 1) @@ -1726,7 +1726,7 @@ int ii; void MACvSetDefaultKeyCtl (unsigned long dwIoBase, WORD wKeyCtl, unsigned int uEntryIdx, BYTE byLocalID) { WORD wOffset; -DWORD dwData; +unsigned long dwData; if (byLocalID <= 1) return; diff --git a/drivers/staging/vt6655/mac.h b/drivers/staging/vt6655/mac.h index 96653a4d33d..3573b23b9f4 100644 --- a/drivers/staging/vt6655/mac.h +++ b/drivers/staging/vt6655/mac.h @@ -677,7 +677,7 @@ #define MACvDWordRegBitsOn(dwIoBase, byRegOfs, dwBits) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + byRegOfs, &dwData); \ VNSvOutPortD(dwIoBase + byRegOfs, dwData | (dwBits)); \ } @@ -706,7 +706,7 @@ #define MACvDWordRegBitsOff(dwIoBase, byRegOfs, dwBits) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + byRegOfs, &dwData); \ VNSvOutPortD(dwIoBase + byRegOfs, dwData & ~(dwBits)); \ } @@ -873,7 +873,7 @@ #define MACvReceive0(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_RXDMACTL0, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_RXDMACTL0, DMACTL_WAKE);\ @@ -885,7 +885,7 @@ #define MACvReceive1(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_RXDMACTL1, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_RXDMACTL1, DMACTL_WAKE);\ @@ -902,7 +902,7 @@ #define MACvTransmit0(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_TXDMACTL0, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_TXDMACTL0, DMACTL_WAKE);\ @@ -914,7 +914,7 @@ #define MACvTransmitAC0(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_AC0DMACTL, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_AC0DMACTL, DMACTL_WAKE);\ @@ -926,7 +926,7 @@ #define MACvTransmitSYNC(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_SYNCDMACTL, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_SYNCDMACTL, DMACTL_WAKE);\ @@ -938,7 +938,7 @@ #define MACvTransmitATIM(dwIoBase) \ { \ - DWORD dwData; \ + unsigned long dwData; \ VNSvInPortD(dwIoBase + MAC_REG_ATIMDMACTL, &dwData); \ if (dwData & DMACTL_RUN) { \ VNSvOutPortD(dwIoBase + MAC_REG_ATIMDMACTL, DMACTL_WAKE);\ @@ -1002,7 +1002,7 @@ #define MACvEnableProtectMD(dwIoBase) \ { \ - DWORD dwOrgValue; \ + unsigned long dwOrgValue; \ VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); \ dwOrgValue = dwOrgValue | EnCFG_ProtectMd; \ VNSvOutPortD(dwIoBase + MAC_REG_ENCFG, dwOrgValue); \ @@ -1010,7 +1010,7 @@ #define MACvDisableProtectMD(dwIoBase) \ { \ - DWORD dwOrgValue; \ + unsigned long dwOrgValue; \ VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); \ dwOrgValue = dwOrgValue & ~EnCFG_ProtectMd; \ VNSvOutPortD(dwIoBase + MAC_REG_ENCFG, dwOrgValue); \ @@ -1018,7 +1018,7 @@ #define MACvEnableBarkerPreambleMd(dwIoBase) \ { \ - DWORD dwOrgValue; \ + unsigned long dwOrgValue; \ VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); \ dwOrgValue = dwOrgValue | EnCFG_BarkerPream; \ VNSvOutPortD(dwIoBase + MAC_REG_ENCFG, dwOrgValue); \ @@ -1026,7 +1026,7 @@ #define MACvDisableBarkerPreambleMd(dwIoBase) \ { \ - DWORD dwOrgValue; \ + unsigned long dwOrgValue; \ VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); \ dwOrgValue = dwOrgValue & ~EnCFG_BarkerPream; \ VNSvOutPortD(dwIoBase + MAC_REG_ENCFG, dwOrgValue); \ @@ -1034,10 +1034,10 @@ #define MACvSetBBType(dwIoBase, byTyp) \ { \ - DWORD dwOrgValue; \ + unsigned long dwOrgValue; \ VNSvInPortD(dwIoBase + MAC_REG_ENCFG , &dwOrgValue); \ dwOrgValue = dwOrgValue & ~EnCFG_BBType_MASK; \ - dwOrgValue = dwOrgValue | (DWORD) byTyp; \ + dwOrgValue = dwOrgValue | (unsigned long) byTyp; \ VNSvOutPortD(dwIoBase + MAC_REG_ENCFG, dwOrgValue); \ } @@ -1118,18 +1118,18 @@ BOOL MACbSafeTxOff(unsigned long dwIoBase); BOOL MACbSafeStop(unsigned long dwIoBase); BOOL MACbShutdown(unsigned long dwIoBase); void MACvInitialize(unsigned long dwIoBase); -void MACvSetCurrRx0DescAddr(unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrRx1DescAddr(unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrTXDescAddr(int iTxType, unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrTx0DescAddrEx(unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrAC0DescAddrEx(unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrSyncDescAddrEx(unsigned long dwIoBase, DWORD dwCurrDescAddr); -void MACvSetCurrATIMDescAddrEx(unsigned long dwIoBase, DWORD dwCurrDescAddr); +void MACvSetCurrRx0DescAddr(unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrRx1DescAddr(unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrTXDescAddr(int iTxType, unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrTx0DescAddrEx(unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrAC0DescAddrEx(unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrSyncDescAddrEx(unsigned long dwIoBase, unsigned long dwCurrDescAddr); +void MACvSetCurrATIMDescAddrEx(unsigned long dwIoBase, unsigned long dwCurrDescAddr); void MACvTimer0MicroSDelay(unsigned long dwIoBase, unsigned int uDelay); void MACvOneShotTimer0MicroSec(unsigned long dwIoBase, unsigned int uDelayTime); void MACvOneShotTimer1MicroSec(unsigned long dwIoBase, unsigned int uDelayTime); -void MACvSetMISCFifo(unsigned long dwIoBase, WORD wOffset, DWORD dwData); +void MACvSetMISCFifo(unsigned long dwIoBase, WORD wOffset, unsigned long dwData); BOOL MACbTxDMAOff (unsigned long dwIoBase, unsigned int idx); diff --git a/drivers/staging/vt6655/mib.c b/drivers/staging/vt6655/mib.c index 867d8d26192..a96343665f1 100644 --- a/drivers/staging/vt6655/mib.c +++ b/drivers/staging/vt6655/mib.c @@ -90,7 +90,7 @@ void STAvClearAllCounter (PSStatCounter pStatistic) * Return Value: none * */ -void STAvUpdateIsrStatCounter (PSStatCounter pStatistic, DWORD dwIsr) +void STAvUpdateIsrStatCounter (PSStatCounter pStatistic, unsigned long dwIsr) { /**********************/ /* ABNORMAL interrupt */ @@ -523,7 +523,7 @@ void STAvUpdateTDStatCounterEx ( PSStatCounter pStatistic, unsigned char *pbyBuffer, - DWORD cbFrameLength + unsigned long cbFrameLength ) { unsigned int uPktLength; @@ -555,7 +555,7 @@ void STAvUpdate802_11Counter( PSDot11Counters p802_11Counter, PSStatCounter pStatistic, - DWORD dwCounter + unsigned long dwCounter ) { //p802_11Counter->TransmittedFragmentCount diff --git a/drivers/staging/vt6655/mib.h b/drivers/staging/vt6655/mib.h index 35bb7c48eff..3e86245f274 100644 --- a/drivers/staging/vt6655/mib.h +++ b/drivers/staging/vt6655/mib.h @@ -77,24 +77,24 @@ typedef struct tagSMib2Counter { // e.g. "interface 1" long ifType; long ifMtu; - DWORD ifSpeed; + unsigned long ifSpeed; BYTE ifPhysAddress[ETH_ALEN]; long ifAdminStatus; long ifOperStatus; - DWORD ifLastChange; - DWORD ifInOctets; - DWORD ifInUcastPkts; - DWORD ifInNUcastPkts; - DWORD ifInDiscards; - DWORD ifInErrors; - DWORD ifInUnknownProtos; - DWORD ifOutOctets; - DWORD ifOutUcastPkts; - DWORD ifOutNUcastPkts; - DWORD ifOutDiscards; - DWORD ifOutErrors; - DWORD ifOutQLen; - DWORD ifSpecific; + unsigned long ifLastChange; + unsigned long ifInOctets; + unsigned long ifInUcastPkts; + unsigned long ifInNUcastPkts; + unsigned long ifInDiscards; + unsigned long ifInErrors; + unsigned long ifInUnknownProtos; + unsigned long ifOutOctets; + unsigned long ifOutUcastPkts; + unsigned long ifOutNUcastPkts; + unsigned long ifOutDiscards; + unsigned long ifOutErrors; + unsigned long ifOutQLen; + unsigned long ifSpecific; } SMib2Counter, *PSMib2Counter; // Value in the ifType entry @@ -112,26 +112,26 @@ typedef struct tagSMib2Counter { // typedef struct tagSRmonCounter { long etherStatsIndex; - DWORD etherStatsDataSource; - DWORD etherStatsDropEvents; - DWORD etherStatsOctets; - DWORD etherStatsPkts; - DWORD etherStatsBroadcastPkts; - DWORD etherStatsMulticastPkts; - DWORD etherStatsCRCAlignErrors; - DWORD etherStatsUndersizePkts; - DWORD etherStatsOversizePkts; - DWORD etherStatsFragments; - DWORD etherStatsJabbers; - DWORD etherStatsCollisions; - DWORD etherStatsPkt64Octets; - DWORD etherStatsPkt65to127Octets; - DWORD etherStatsPkt128to255Octets; - DWORD etherStatsPkt256to511Octets; - DWORD etherStatsPkt512to1023Octets; - DWORD etherStatsPkt1024to1518Octets; - DWORD etherStatsOwners; - DWORD etherStatsStatus; + unsigned long etherStatsDataSource; + unsigned long etherStatsDropEvents; + unsigned long etherStatsOctets; + unsigned long etherStatsPkts; + unsigned long etherStatsBroadcastPkts; + unsigned long etherStatsMulticastPkts; + unsigned long etherStatsCRCAlignErrors; + unsigned long etherStatsUndersizePkts; + unsigned long etherStatsOversizePkts; + unsigned long etherStatsFragments; + unsigned long etherStatsJabbers; + unsigned long etherStatsCollisions; + unsigned long etherStatsPkt64Octets; + unsigned long etherStatsPkt65to127Octets; + unsigned long etherStatsPkt128to255Octets; + unsigned long etherStatsPkt256to511Octets; + unsigned long etherStatsPkt512to1023Octets; + unsigned long etherStatsPkt1024to1518Octets; + unsigned long etherStatsOwners; + unsigned long etherStatsStatus; } SRmonCounter, *PSRmonCounter; // @@ -179,27 +179,27 @@ typedef struct tagSCustomCounters { typedef struct tagSISRCounters { unsigned long Length; - DWORD dwIsrTx0OK; - DWORD dwIsrAC0TxOK; - DWORD dwIsrBeaconTxOK; - DWORD dwIsrRx0OK; - DWORD dwIsrTBTTInt; - DWORD dwIsrSTIMERInt; - DWORD dwIsrWatchDog; - DWORD dwIsrUnrecoverableError; - DWORD dwIsrSoftInterrupt; - DWORD dwIsrMIBNearfull; - DWORD dwIsrRxNoBuf; - - DWORD dwIsrUnknown; // unknown interrupt count - - DWORD dwIsrRx1OK; - DWORD dwIsrATIMTxOK; - DWORD dwIsrSYNCTxOK; - DWORD dwIsrCFPEnd; - DWORD dwIsrATIMEnd; - DWORD dwIsrSYNCFlushOK; - DWORD dwIsrSTIMER1Int; + unsigned long dwIsrTx0OK; + unsigned long dwIsrAC0TxOK; + unsigned long dwIsrBeaconTxOK; + unsigned long dwIsrRx0OK; + unsigned long dwIsrTBTTInt; + unsigned long dwIsrSTIMERInt; + unsigned long dwIsrWatchDog; + unsigned long dwIsrUnrecoverableError; + unsigned long dwIsrSoftInterrupt; + unsigned long dwIsrMIBNearfull; + unsigned long dwIsrRxNoBuf; + + unsigned long dwIsrUnknown; // unknown interrupt count + + unsigned long dwIsrRx1OK; + unsigned long dwIsrATIMTxOK; + unsigned long dwIsrSYNCTxOK; + unsigned long dwIsrCFPEnd; + unsigned long dwIsrATIMEnd; + unsigned long dwIsrSYNCFlushOK; + unsigned long dwIsrSTIMER1Int; ///////////////////////////////////// } SISRCounters, *PSISRCounters; @@ -222,34 +222,34 @@ typedef struct tagSStatCounter { // RSR status count // - DWORD dwRsrFrmAlgnErr; - DWORD dwRsrErr; - DWORD dwRsrCRCErr; - DWORD dwRsrCRCOk; - DWORD dwRsrBSSIDOk; - DWORD dwRsrADDROk; - DWORD dwRsrBCNSSIDOk; - DWORD dwRsrLENErr; - DWORD dwRsrTYPErr; - - DWORD dwNewRsrDECRYPTOK; - DWORD dwNewRsrCFP; - DWORD dwNewRsrUTSF; - DWORD dwNewRsrHITAID; - DWORD dwNewRsrHITAID0; - - DWORD dwRsrLong; - DWORD dwRsrRunt; - - DWORD dwRsrRxControl; - DWORD dwRsrRxData; - DWORD dwRsrRxManage; - - DWORD dwRsrRxPacket; - DWORD dwRsrRxOctet; - DWORD dwRsrBroadcast; - DWORD dwRsrMulticast; - DWORD dwRsrDirected; + unsigned long dwRsrFrmAlgnErr; + unsigned long dwRsrErr; + unsigned long dwRsrCRCErr; + unsigned long dwRsrCRCOk; + unsigned long dwRsrBSSIDOk; + unsigned long dwRsrADDROk; + unsigned long dwRsrBCNSSIDOk; + unsigned long dwRsrLENErr; + unsigned long dwRsrTYPErr; + + unsigned long dwNewRsrDECRYPTOK; + unsigned long dwNewRsrCFP; + unsigned long dwNewRsrUTSF; + unsigned long dwNewRsrHITAID; + unsigned long dwNewRsrHITAID0; + + unsigned long dwRsrLong; + unsigned long dwRsrRunt; + + unsigned long dwRsrRxControl; + unsigned long dwRsrRxData; + unsigned long dwRsrRxManage; + + unsigned long dwRsrRxPacket; + unsigned long dwRsrRxOctet; + unsigned long dwRsrBroadcast; + unsigned long dwRsrMulticast; + unsigned long dwRsrDirected; // 64-bit OID unsigned long long ullRsrOK; @@ -261,36 +261,36 @@ typedef struct tagSStatCounter { unsigned long long ullRxMulticastFrames; unsigned long long ullRxDirectedFrames; - DWORD dwRsrRxFragment; - DWORD dwRsrRxFrmLen64; - DWORD dwRsrRxFrmLen65_127; - DWORD dwRsrRxFrmLen128_255; - DWORD dwRsrRxFrmLen256_511; - DWORD dwRsrRxFrmLen512_1023; - DWORD dwRsrRxFrmLen1024_1518; + unsigned long dwRsrRxFragment; + unsigned long dwRsrRxFrmLen64; + unsigned long dwRsrRxFrmLen65_127; + unsigned long dwRsrRxFrmLen128_255; + unsigned long dwRsrRxFrmLen256_511; + unsigned long dwRsrRxFrmLen512_1023; + unsigned long dwRsrRxFrmLen1024_1518; // TSR status count // - DWORD dwTsrTotalRetry[TYPE_MAXTD]; // total collision retry count - DWORD dwTsrOnceRetry[TYPE_MAXTD]; // this packet only occur one collision - DWORD dwTsrMoreThanOnceRetry[TYPE_MAXTD]; // this packet occur more than one collision - DWORD dwTsrRetry[TYPE_MAXTD]; // this packet has ever occur collision, + unsigned long dwTsrTotalRetry[TYPE_MAXTD]; // total collision retry count + unsigned long dwTsrOnceRetry[TYPE_MAXTD]; // this packet only occur one collision + unsigned long dwTsrMoreThanOnceRetry[TYPE_MAXTD]; // this packet occur more than one collision + unsigned long dwTsrRetry[TYPE_MAXTD]; // this packet has ever occur collision, // that is (dwTsrOnceCollision0 + dwTsrMoreThanOnceCollision0) - DWORD dwTsrACKData[TYPE_MAXTD]; - DWORD dwTsrErr[TYPE_MAXTD]; - DWORD dwAllTsrOK[TYPE_MAXTD]; - DWORD dwTsrRetryTimeout[TYPE_MAXTD]; - DWORD dwTsrTransmitTimeout[TYPE_MAXTD]; - - DWORD dwTsrTxPacket[TYPE_MAXTD]; - DWORD dwTsrTxOctet[TYPE_MAXTD]; - DWORD dwTsrBroadcast[TYPE_MAXTD]; - DWORD dwTsrMulticast[TYPE_MAXTD]; - DWORD dwTsrDirected[TYPE_MAXTD]; + unsigned long dwTsrACKData[TYPE_MAXTD]; + unsigned long dwTsrErr[TYPE_MAXTD]; + unsigned long dwAllTsrOK[TYPE_MAXTD]; + unsigned long dwTsrRetryTimeout[TYPE_MAXTD]; + unsigned long dwTsrTransmitTimeout[TYPE_MAXTD]; + + unsigned long dwTsrTxPacket[TYPE_MAXTD]; + unsigned long dwTsrTxOctet[TYPE_MAXTD]; + unsigned long dwTsrBroadcast[TYPE_MAXTD]; + unsigned long dwTsrMulticast[TYPE_MAXTD]; + unsigned long dwTsrDirected[TYPE_MAXTD]; // RD/TD count - DWORD dwCntRxFrmLength; - DWORD dwCntTxBufLength; + unsigned long dwCntRxFrmLength; + unsigned long dwCntTxBufLength; BYTE abyCntRxPattern[16]; BYTE abyCntTxPattern[16]; @@ -298,9 +298,9 @@ typedef struct tagSStatCounter { // Software check.... - DWORD dwCntRxDataErr; // rx buffer data software compare CRC err count - DWORD dwCntDecryptErr; // rx buffer data software compare CRC err count - DWORD dwCntRxICVErr; // rx buffer data software compare CRC err count + unsigned long dwCntRxDataErr; // rx buffer data software compare CRC err count + unsigned long dwCntDecryptErr; // rx buffer data software compare CRC err count + unsigned long dwCntRxICVErr; // rx buffer data software compare CRC err count unsigned int idxRxErrorDesc[TYPE_MAXRD]; // index for rx data error RD // 64-bit OID @@ -314,7 +314,7 @@ typedef struct tagSStatCounter { unsigned long long ullTxMulticastBytes[TYPE_MAXTD]; unsigned long long ullTxDirectedBytes[TYPE_MAXTD]; -// DWORD dwTxRetryCount[8]; +// unsigned long dwTxRetryCount[8]; // // ISR status count // @@ -344,7 +344,7 @@ typedef struct tagSStatCounter { void STAvClearAllCounter(PSStatCounter pStatistic); -void STAvUpdateIsrStatCounter(PSStatCounter pStatistic, DWORD dwIsr); +void STAvUpdateIsrStatCounter(PSStatCounter pStatistic, unsigned long dwIsr); void STAvUpdateRDStatCounter(PSStatCounter pStatistic, BYTE byRSR, BYTE byNewRSR, BYTE byRxRate, @@ -360,13 +360,13 @@ void STAvUpdateTDStatCounter(PSStatCounter pStatistic, BYTE byTSR0, BYTE byTSR1, void STAvUpdateTDStatCounterEx( PSStatCounter pStatistic, unsigned char *pbyBuffer, - DWORD cbFrameLength + unsigned long cbFrameLength ); void STAvUpdate802_11Counter( PSDot11Counters p802_11Counter, PSStatCounter pStatistic, - DWORD dwCounter + unsigned long dwCounter ); void STAvClear802_11Counter(PSDot11Counters p802_11Counter); diff --git a/drivers/staging/vt6655/michael.c b/drivers/staging/vt6655/michael.c index 74c66b56498..ad02166b9f9 100644 --- a/drivers/staging/vt6655/michael.c +++ b/drivers/staging/vt6655/michael.c @@ -26,8 +26,8 @@ * Date: Sep 4, 2002 * * Functions: - * s_dwGetUINT32 - Convert from BYTE[] to DWORD in a portable way - * s_vPutUINT32 - Convert from DWORD to BYTE[] in a portable way + * s_dwGetUINT32 - Convert from BYTE[] to unsigned long in a portable way + * s_vPutUINT32 - Convert from unsigned long to BYTE[] in a portable way * s_vClear - Reset the state to the empty message. * s_vSetKey - Set the key. * MIC_vInit - Set the key. @@ -48,28 +48,28 @@ /*--------------------- Static Functions --------------------------*/ /* -static DWORD s_dwGetUINT32(BYTE * p); // Get DWORD from 4 bytes LSByte first -static void s_vPutUINT32(BYTE* p, DWORD val); // Put DWORD into 4 bytes LSByte first +static unsigned long s_dwGetUINT32(BYTE * p); // Get unsigned long from 4 bytes LSByte first +static void s_vPutUINT32(BYTE* p, unsigned long val); // Put unsigned long into 4 bytes LSByte first */ static void s_vClear(void); // Clear the internal message, // resets the object to the state just after construction. -static void s_vSetKey(DWORD dwK0, DWORD dwK1); +static void s_vSetKey(unsigned long dwK0, unsigned long dwK1); static void s_vAppendByte(BYTE b); // Add a single byte to the internal message /*--------------------- Export Variables --------------------------*/ -static DWORD L, R; // Current state +static unsigned long L, R; // Current state -static DWORD K0, K1; // Key -static DWORD M; // Message accumulator (single word) +static unsigned long K0, K1; // Key +static unsigned long M; // Message accumulator (single word) static unsigned int nBytesInM; // # bytes in M /*--------------------- Export Functions --------------------------*/ /* -static DWORD s_dwGetUINT32 (BYTE * p) -// Convert from BYTE[] to DWORD in a portable way +static unsigned long s_dwGetUINT32 (BYTE * p) +// Convert from BYTE[] to unsigned long in a portable way { - DWORD res = 0; + unsigned long res = 0; unsigned int i; for(i=0; i<4; i++ ) { @@ -78,8 +78,8 @@ static DWORD s_dwGetUINT32 (BYTE * p) return res; } -static void s_vPutUINT32 (BYTE* p, DWORD val) -// Convert from DWORD to BYTE[] in a portable way +static void s_vPutUINT32 (BYTE* p, unsigned long val) +// Convert from unsigned long to BYTE[] in a portable way { unsigned int i; for(i=0; i<4; i++ ) @@ -99,7 +99,7 @@ static void s_vClear (void) M = 0; } -static void s_vSetKey (DWORD dwK0, DWORD dwK1) +static void s_vSetKey (unsigned long dwK0, unsigned long dwK1) { // Set the key K0 = dwK0; @@ -131,7 +131,7 @@ static void s_vAppendByte (BYTE b) } } -void MIC_vInit (DWORD dwK0, DWORD dwK1) +void MIC_vInit (unsigned long dwK0, unsigned long dwK1) { // Set the key s_vSetKey(dwK0, dwK1); diff --git a/drivers/staging/vt6655/michael.h b/drivers/staging/vt6655/michael.h index be399494aaa..3131b161d6a 100644 --- a/drivers/staging/vt6655/michael.h +++ b/drivers/staging/vt6655/michael.h @@ -35,7 +35,7 @@ /*--------------------- Export Types ------------------------------*/ -void MIC_vInit(DWORD dwK0, DWORD dwK1); +void MIC_vInit(unsigned long dwK0, unsigned long dwK1); void MIC_vUnInit(void); diff --git a/drivers/staging/vt6655/rf.c b/drivers/staging/vt6655/rf.c index 63e5e5044e1..c126e26e0b5 100644 --- a/drivers/staging/vt6655/rf.c +++ b/drivers/staging/vt6655/rf.c @@ -94,7 +94,7 @@ -const DWORD dwAL2230InitTable[CB_AL2230_INIT_SEQ] = { +const unsigned long dwAL2230InitTable[CB_AL2230_INIT_SEQ] = { 0x03F79000+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // 0x03333100+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // 0x01A00200+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // @@ -112,7 +112,7 @@ const DWORD dwAL2230InitTable[CB_AL2230_INIT_SEQ] = { 0x00580F00+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW }; -const DWORD dwAL2230ChannelTable0[CB_MAX_CHANNEL] = { +const unsigned long dwAL2230ChannelTable0[CB_MAX_CHANNEL] = { 0x03F79000+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 1, Tf = 2412MHz 0x03F79000+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 2, Tf = 2417MHz 0x03E79000+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 3, Tf = 2422MHz @@ -129,7 +129,7 @@ const DWORD dwAL2230ChannelTable0[CB_MAX_CHANNEL] = { 0x03E7C000+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW // channel = 14, Tf = 2412M }; -const DWORD dwAL2230ChannelTable1[CB_MAX_CHANNEL] = { +const unsigned long dwAL2230ChannelTable1[CB_MAX_CHANNEL] = { 0x03333100+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 1, Tf = 2412MHz 0x0B333100+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 2, Tf = 2417MHz 0x03333100+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 3, Tf = 2422MHz @@ -146,7 +146,7 @@ const DWORD dwAL2230ChannelTable1[CB_MAX_CHANNEL] = { 0x06666100+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW // channel = 14, Tf = 2412M }; -DWORD dwAL2230PowerTable[AL2230_PWR_IDX_LEN] = { +unsigned long dwAL2230PowerTable[AL2230_PWR_IDX_LEN] = { 0x04040900+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, 0x04041900+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, 0x04042900+(BY_AL2230_REG_LEN<<3)+IFREGCTL_REGW, @@ -216,7 +216,7 @@ DWORD dwAL2230PowerTable[AL2230_PWR_IDX_LEN] = { //{{ RobertYu:20050104 // 40MHz reference frequency // Need to Pull PLLON(PE3) low when writing channel registers through 3-wire. -const DWORD dwAL7230InitTable[CB_AL7230_INIT_SEQ] = { +const unsigned long dwAL7230InitTable[CB_AL7230_INIT_SEQ] = { 0x00379000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Channel1 // Need modify for 11a 0x13333100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Channel1 // Need modify for 11a 0x841FF200+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Need modify for 11a: 451FE2 @@ -239,7 +239,7 @@ const DWORD dwAL7230InitTable[CB_AL7230_INIT_SEQ] = { 0x1ABA8F00+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW // Need modify for 11a: 12BACF }; -const DWORD dwAL7230InitTableAMode[CB_AL7230_INIT_SEQ] = { +const unsigned long dwAL7230InitTableAMode[CB_AL7230_INIT_SEQ] = { 0x0FF52000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Channel184 // Need modify for 11b/g 0x00000100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Channel184 // Need modify for 11b/g 0x451FE200+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // Need modify for 11b/g @@ -259,7 +259,7 @@ const DWORD dwAL7230InitTableAMode[CB_AL7230_INIT_SEQ] = { }; -const DWORD dwAL7230ChannelTable0[CB_MAX_CHANNEL] = { +const unsigned long dwAL7230ChannelTable0[CB_MAX_CHANNEL] = { 0x00379000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 1, Tf = 2412MHz 0x00379000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 2, Tf = 2417MHz 0x00379000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 3, Tf = 2422MHz @@ -325,7 +325,7 @@ const DWORD dwAL7230ChannelTable0[CB_MAX_CHANNEL] = { 0x0FF61000+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW // channel = 165, Tf = 5825MHz (56) }; -const DWORD dwAL7230ChannelTable1[CB_MAX_CHANNEL] = { +const unsigned long dwAL7230ChannelTable1[CB_MAX_CHANNEL] = { 0x13333100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 1, Tf = 2412MHz 0x1B333100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 2, Tf = 2417MHz 0x03333100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 3, Tf = 2422MHz @@ -389,7 +389,7 @@ const DWORD dwAL7230ChannelTable1[CB_MAX_CHANNEL] = { 0x02AAA100+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW // channel = 165, Tf = 5825MHz (56) }; -const DWORD dwAL7230ChannelTable2[CB_MAX_CHANNEL] = { +const unsigned long dwAL7230ChannelTable2[CB_MAX_CHANNEL] = { 0x7FD78400+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 1, Tf = 2412MHz 0x7FD78400+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 2, Tf = 2417MHz 0x7FD78400+(BY_AL7230_REG_LEN<<3)+IFREGCTL_REGW, // channel = 3, Tf = 2422MHz @@ -622,10 +622,10 @@ BOOL s_bAL7230SelectChannel (unsigned long dwIoBase, BYTE byChannel) * Return Value: TRUE if succeeded; FALSE if failed. * */ -BOOL IFRFbWriteEmbeded (unsigned long dwIoBase, DWORD dwData) +BOOL IFRFbWriteEmbeded (unsigned long dwIoBase, unsigned long dwData) { WORD ww; - DWORD dwValue; + unsigned long dwValue; VNSvOutPortD(dwIoBase + MAC_REG_IFREGCTL, dwData); @@ -978,7 +978,7 @@ BOOL RFvWriteWakeProgSyn (unsigned long dwIoBase, BYTE byRFType, unsigned int uC break; } - MACvSetMISCFifo(dwIoBase, MISCFIFO_SYNINFO_IDX, (DWORD)MAKEWORD(bySleepCount, byInitCount)); + MACvSetMISCFifo(dwIoBase, MISCFIFO_SYNINFO_IDX, (unsigned long )MAKEWORD(bySleepCount, byInitCount)); return TRUE; } @@ -1142,7 +1142,7 @@ BOOL RFbRawSetPower ( ) { BOOL bResult = TRUE; -DWORD dwMax7230Pwr = 0; +unsigned long dwMax7230Pwr = 0; if (byPwr >= pDevice->byMaxPwrLevel) { return (FALSE); diff --git a/drivers/staging/vt6655/rf.h b/drivers/staging/vt6655/rf.h index b2895733bf6..77e2e33895a 100644 --- a/drivers/staging/vt6655/rf.h +++ b/drivers/staging/vt6655/rf.h @@ -76,7 +76,7 @@ /*--------------------- Export Functions --------------------------*/ -BOOL IFRFbWriteEmbeded(unsigned long dwIoBase, DWORD dwData); +BOOL IFRFbWriteEmbeded(unsigned long dwIoBase, unsigned long dwData); BOOL RFbSelectChannel(unsigned long dwIoBase, BYTE byRFType, BYTE byChannel); BOOL RFbInit ( PSDevice pDevice diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 478c140be11..6664d78e8db 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -225,7 +225,7 @@ s_vFillTxKey ( unsigned long *pdwExtIV = (unsigned long *) ((unsigned char *)pbyIVHead+4); WORD wValue; PS802_11Header pMACHeader = (PS802_11Header)pbyHdrBuf; - DWORD dwRevIVCounter; + unsigned long dwRevIVCounter; BYTE byKeyIndex = 0; @@ -337,7 +337,7 @@ s_vSWencryption ( ) { unsigned int cbICVlen = 4; - DWORD dwICV = 0xFFFFFFFFL; + unsigned long dwICV = 0xFFFFFFFFL; unsigned long *pdwICV; if (pTransmitKey == NULL) @@ -1355,13 +1355,13 @@ s_cbFillTxBufHead ( unsigned int uLength = 0; unsigned int uTmpLen = 0; // BYTE abyTmp[8]; -// DWORD dwCRC; +// unsigned long dwCRC; unsigned int cbMICHDR = 0; - DWORD dwMICKey0, dwMICKey1; - DWORD dwMIC_Priority; + unsigned long dwMICKey0, dwMICKey1; + unsigned long dwMIC_Priority; unsigned long *pdwMIC_L; unsigned long *pdwMIC_R; - DWORD dwSafeMIC_L, dwSafeMIC_R; //Fix "Last Frag Size" < "MIC length". + unsigned long dwSafeMIC_L, dwSafeMIC_R; //Fix "Last Frag Size" < "MIC length". BOOL bMIC2Frag = FALSE; unsigned int uMICFragLen = 0; unsigned int uMACfragNum = 1; @@ -2850,8 +2850,8 @@ vDMA0_tx_80211(PSDevice pDevice, struct sk_buff *skb, unsigned char *pbMPDU, un unsigned int uPadding = 0; unsigned int cbMICHDR = 0; unsigned int uLength = 0; - DWORD dwMICKey0, dwMICKey1; - DWORD dwMIC_Priority; + unsigned long dwMICKey0, dwMICKey1; + unsigned long dwMIC_Priority; unsigned long *pdwMIC_L; unsigned long *pdwMIC_R; WORD wTxBufSize; diff --git a/drivers/staging/vt6655/rxtx.h b/drivers/staging/vt6655/rxtx.h index 1e5e31f77ca..64d30b5c18b 100644 --- a/drivers/staging/vt6655/rxtx.h +++ b/drivers/staging/vt6655/rxtx.h @@ -42,7 +42,7 @@ /* void vGenerateMACHeader( PSDevice pDevice, - DWORD dwTxBufferAddr, + unsigned long dwTxBufferAddr, unsigned char *pbySkbData, unsigned int cbPacketSize, BOOL bDMA0Used, @@ -52,7 +52,7 @@ void vGenerateMACHeader( void vProcessRxMACHeader ( PSDevice pDevice, - DWORD dwRxBufferAddr, + unsigned long dwRxBufferAddr, unsigned int cbPacketSize, BOOL bIsWEP, PUINT pcbHeadSize diff --git a/drivers/staging/vt6655/tcrc.c b/drivers/staging/vt6655/tcrc.c index d48777a8e4b..2d5504ba8ab 100644 --- a/drivers/staging/vt6655/tcrc.c +++ b/drivers/staging/vt6655/tcrc.c @@ -42,7 +42,7 @@ /*--------------------- Static Variables --------------------------*/ // 32-bit CRC table -static const DWORD s_adwCrc32Table[256] = { +static const unsigned long s_adwCrc32Table[256] = { 0x00000000L, 0x77073096L, 0xEE0E612CL, 0x990951BAL, 0x076DC419L, 0x706AF48FL, 0xE963A535L, 0x9E6495A3L, 0x0EDB8832L, 0x79DCB8A4L, 0xE0D5E91EL, 0x97D2D988L, @@ -132,9 +132,9 @@ static const DWORD s_adwCrc32Table[256] = { * Return Value: CRC-32 * -*/ -DWORD CRCdwCrc32 (unsigned char *pbyData, unsigned int cbByte, DWORD dwCrcSeed) +unsigned long CRCdwCrc32 (unsigned char *pbyData, unsigned int cbByte, unsigned long dwCrcSeed) { - DWORD dwCrc; + unsigned long dwCrc; dwCrc = dwCrcSeed; while (cbByte--) { @@ -164,7 +164,7 @@ DWORD CRCdwCrc32 (unsigned char *pbyData, unsigned int cbByte, DWORD dwCrcSeed) * Return Value: CRC-32 * -*/ -DWORD CRCdwGetCrc32 (unsigned char *pbyData, unsigned int cbByte) +unsigned long CRCdwGetCrc32 (unsigned char *pbyData, unsigned int cbByte) { return ~CRCdwCrc32(pbyData, cbByte, 0xFFFFFFFFL); } @@ -190,7 +190,7 @@ DWORD CRCdwGetCrc32 (unsigned char *pbyData, unsigned int cbByte) * Return Value: CRC-32 * -*/ -DWORD CRCdwGetCrc32Ex(unsigned char *pbyData, unsigned int cbByte, DWORD dwPreCRC) +unsigned long CRCdwGetCrc32Ex(unsigned char *pbyData, unsigned int cbByte, unsigned long dwPreCRC) { return CRCdwCrc32(pbyData, cbByte, dwPreCRC); } diff --git a/drivers/staging/vt6655/tcrc.h b/drivers/staging/vt6655/tcrc.h index 7d5cd89ed43..d0449855beb 100644 --- a/drivers/staging/vt6655/tcrc.h +++ b/drivers/staging/vt6655/tcrc.h @@ -43,9 +43,9 @@ /*--------------------- Export Functions --------------------------*/ -DWORD CRCdwCrc32(unsigned char *pbyData, unsigned int cbByte, DWORD dwCrcSeed); -DWORD CRCdwGetCrc32(unsigned char *pbyData, unsigned int cbByte); -DWORD CRCdwGetCrc32Ex(unsigned char *pbyData, unsigned int cbByte, DWORD dwPreCRC); +unsigned long CRCdwCrc32(unsigned char *pbyData, unsigned int cbByte, unsigned long dwCrcSeed); +unsigned long CRCdwGetCrc32(unsigned char *pbyData, unsigned int cbByte); +unsigned long CRCdwGetCrc32Ex(unsigned char *pbyData, unsigned int cbByte, unsigned long dwPreCRC); #endif // __TCRC_H__ diff --git a/drivers/staging/vt6655/tether.c b/drivers/staging/vt6655/tether.c index f654a718279..003625989c4 100644 --- a/drivers/staging/vt6655/tether.c +++ b/drivers/staging/vt6655/tether.c @@ -98,7 +98,7 @@ BYTE ETHbyGetHashIndexByCrc32 (unsigned char *pbyMultiAddr) */ BOOL ETHbIsBufferCrc32Ok (unsigned char *pbyBuffer, unsigned int cbFrameLength) { - DWORD dwCRC; + unsigned long dwCRC; dwCRC = CRCdwGetCrc32(pbyBuffer, cbFrameLength - 4); if (cpu_to_le32(*((unsigned long *)(pbyBuffer + cbFrameLength - 4))) != dwCRC) { diff --git a/drivers/staging/vt6655/tkip.c b/drivers/staging/vt6655/tkip.c index 569c911193c..a215866100f 100644 --- a/drivers/staging/vt6655/tkip.c +++ b/drivers/staging/vt6655/tkip.c @@ -187,7 +187,7 @@ void TKIPvMixKey( unsigned char *pbyTKey, unsigned char *pbyTA, WORD wTSC15_0, - DWORD dwTSC47_16, + unsigned long dwTSC47_16, unsigned char *pbyRC4Key ) { diff --git a/drivers/staging/vt6655/tkip.h b/drivers/staging/vt6655/tkip.h index cdadf66746f..30c25d0676f 100644 --- a/drivers/staging/vt6655/tkip.h +++ b/drivers/staging/vt6655/tkip.h @@ -50,7 +50,7 @@ void TKIPvMixKey( unsigned char *pbyTKey, unsigned char *pbyTA, WORD wTSC15_0, - DWORD dwTSC47_16, + unsigned long dwTSC47_16, unsigned char *pbyRC4Key ); diff --git a/drivers/staging/vt6655/tmacro.h b/drivers/staging/vt6655/tmacro.h index e96c140de05..99c86fef5e7 100644 --- a/drivers/staging/vt6655/tmacro.h +++ b/drivers/staging/vt6655/tmacro.h @@ -44,7 +44,7 @@ #define LOWORD(d) ((WORD)(d)) #endif #if !defined(HIWORD) -#define HIWORD(d) ((WORD)((((DWORD)(d)) >> 16) & 0xFFFF)) +#define HIWORD(d) ((WORD)((((unsigned long)(d)) >> 16) & 0xFFFF)) #endif #define LODWORD(q) ((q).u.dwLowDword) @@ -54,7 +54,7 @@ #define MAKEWORD(lb, hb) ((WORD)(((BYTE)(lb)) | (((WORD)((BYTE)(hb))) << 8))) #endif #if !defined(MAKEDWORD) -#define MAKEDWORD(lw, hw) ((DWORD)(((WORD)(lw)) | (((DWORD)((WORD)(hw))) << 16))) +#define MAKEDWORD(lw, hw) ((unsigned long)(((WORD)(lw)) | (((unsigned long)((WORD)(hw))) << 16))) #endif #endif // __TMACRO_H__ diff --git a/drivers/staging/vt6655/ttype.h b/drivers/staging/vt6655/ttype.h index 69319a3c94c..11493e1be90 100644 --- a/drivers/staging/vt6655/ttype.h +++ b/drivers/staging/vt6655/ttype.h @@ -70,15 +70,14 @@ typedef int BOOL; typedef unsigned char BYTE; // 8-bit typedef unsigned short WORD; // 16-bit -typedef unsigned long DWORD; // 32-bit // QWORD is for those situation that we want // an 8-byte-aligned 8 byte long structure // which is NOT really a floating point number. typedef union tagUQuadWord { struct { - DWORD dwLowDword; - DWORD dwHighDword; + unsigned int dwLowDword; + unsigned int dwHighDword; } u; double DoNotUseThisField; } UQuadWord; diff --git a/drivers/staging/vt6655/upc.h b/drivers/staging/vt6655/upc.h index 7abd231c4d5..fc97a30f340 100644 --- a/drivers/staging/vt6655/upc.h +++ b/drivers/staging/vt6655/upc.h @@ -87,7 +87,7 @@ } #define VNSvInPortD(dwIOAddress, pdwData) { \ - volatile DWORD* pdwAddr = ((unsigned long *)(dwIOAddress)); \ + volatile unsigned long *pdwAddr = ((unsigned long *)(dwIOAddress)); \ *(pdwData) = readl(pdwAddr); \ } @@ -104,8 +104,8 @@ } #define VNSvOutPortD(dwIOAddress, dwData) { \ - volatile DWORD* pdwAddr = ((unsigned long *)(dwIOAddress)); \ - writel((DWORD)dwData, pdwAddr); \ + volatile unsigned long *pdwAddr = ((unsigned long *)(dwIOAddress)); \ + writel((unsigned long)dwData, pdwAddr); \ } #endif diff --git a/drivers/staging/vt6655/wpactl.c b/drivers/staging/vt6655/wpactl.c index 714364388c5..2c2d5906097 100644 --- a/drivers/staging/vt6655/wpactl.c +++ b/drivers/staging/vt6655/wpactl.c @@ -203,7 +203,7 @@ int wpa_set_wpadev(PSDevice pDevice, int val) { struct viawget_wpa_param *param=ctx; PSMgmtObject pMgmt = pDevice->pMgmt; - DWORD dwKeyIndex = 0; + unsigned long dwKeyIndex = 0; BYTE abyKey[MAX_KEY_LEN]; BYTE abySeq[MAX_KEY_LEN]; QWORD KeyRSC; @@ -243,7 +243,7 @@ int wpa_set_wpadev(PSDevice pDevice, int val) spin_lock_irq(&pDevice->lock); } - dwKeyIndex = (DWORD)(param->u.wpa_key.key_index); + dwKeyIndex = (unsigned long)(param->u.wpa_key.key_index); if (param->u.wpa_key.alg_name == WPA_ALG_WEP) { if (dwKeyIndex > 3) { |