diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c index e49bb258b5c3e26a1053627eecf41974894d0142..24b6d4507db66d1c0016f209b3cbab8197998ea1 100644 --- a/drivers/staging/vt6655/device_main.c +++ b/drivers/staging/vt6655/device_main.c @@ -2307,7 +2307,7 @@ static int device_xmit(struct sk_buff *skb, struct net_device *dev) { spin_unlock_irq(&pDevice->lock); return 0; } - if (IS_MULTICAST_ADDRESS((PBYTE)(skb->data))) { + if (is_multicast_ether_addr((PBYTE)(skb->data))) { uNodeIndex = 0; bNodeExist = TRUE; if (pMgmt->sNodeDBTable[0].bPSEnable) { diff --git a/drivers/staging/vt6655/dpc.c b/drivers/staging/vt6655/dpc.c index 6b758a8c1af364f2556b848454109713bbeed578..addbd4d1989d6e2b70dae9574b70af4ca1d094c3 100644 --- a/drivers/staging/vt6655/dpc.c +++ b/drivers/staging/vt6655/dpc.c @@ -463,7 +463,7 @@ device_receive_frame ( return FALSE; } - if (!IS_MULTICAST_ADDRESS(pbyFrame) && !IS_BROADCAST_ADDRESS(pbyFrame)) { + if (!is_multicast_ether_addr(pbyFrame) && !IS_BROADCAST_ADDRESS(pbyFrame)) { if (WCTLbIsDuplicate(&(pDevice->sDupRxCache), (PS802_11Header) (skb->data + 4))) { pDevice->s802_11Counter.FrameDuplicateCount++; return FALSE; @@ -1460,7 +1460,7 @@ static BOOL s_bAPModeRxData ( if (FrameSize > CB_MAX_BUF_SIZE) return FALSE; // check DA - if(IS_MULTICAST_ADDRESS((PBYTE)(skb->data+cbHeaderOffset))) { + if(is_multicast_ether_addr((PBYTE)(skb->data+cbHeaderOffset))) { if (pMgmt->sNodeDBTable[0].bPSEnable) { skbcpy = dev_alloc_skb((int)pDevice->rx_buf_sz); diff --git a/drivers/staging/vt6655/mib.c b/drivers/staging/vt6655/mib.c index 2f390ab5ed9d944680345854127ba4668cdc55ea..1300f06aae9af7c7359c56b84d39dcb1a15280a8 100644 --- a/drivers/staging/vt6655/mib.c +++ b/drivers/staging/vt6655/mib.c @@ -475,7 +475,7 @@ STAvUpdateTDStatCounter ( pStatistic->ullTxBroadcastFrames[uIdx]++; pStatistic->ullTxBroadcastBytes[uIdx] += (ULONGLONG)cbFrameLength; } - else if (IS_MULTICAST_ADDRESS(pbyDestAddr)) { + else if (is_multicast_ether_addr(pbyDestAddr)) { pStatistic->ullTxMulticastFrames[uIdx]++; pStatistic->ullTxMulticastBytes[uIdx] += (ULONGLONG)cbFrameLength; } @@ -497,7 +497,7 @@ STAvUpdateTDStatCounter ( if (IS_BROADCAST_ADDRESS(pbyDestAddr)) pStatistic->dwTsrBroadcast[uIdx]++; - else if (IS_MULTICAST_ADDRESS(pbyDestAddr)) + else if (is_multicast_ether_addr(pbyDestAddr)) pStatistic->dwTsrMulticast[uIdx]++; else pStatistic->dwTsrDirected[uIdx]++; diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index a0445c3427ea266335c410400dc3ef6be875552f..253ca249e3df4a671803c98f80c4702df2cf673e 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -1394,7 +1394,7 @@ s_cbFillTxBufHead ( if ((pDevice->eOPMode == OP_MODE_ADHOC) || (pDevice->eOPMode == OP_MODE_AP)) { - if (IS_MULTICAST_ADDRESS(&(psEthHeader->abyDstAddr[0])) || + if (is_multicast_ether_addr(&(psEthHeader->abyDstAddr[0])) || IS_BROADCAST_ADDRESS(&(psEthHeader->abyDstAddr[0]))) { bNeedACK = FALSE; } @@ -2123,7 +2123,7 @@ vGenerateFIFOHeader ( if ((pDevice->eOPMode == OP_MODE_ADHOC) || (pDevice->eOPMode == OP_MODE_AP)) { - if (IS_MULTICAST_ADDRESS(&(psEthHeader->abyDstAddr[0])) || + if (is_multicast_ether_addr(&(psEthHeader->abyDstAddr[0])) || IS_BROADCAST_ADDRESS(&(psEthHeader->abyDstAddr[0]))) { bNeedACK = FALSE; pTxBufHead->wFIFOCtl = pTxBufHead->wFIFOCtl & (~FIFOCTL_NEEDACK); @@ -2424,7 +2424,7 @@ CMD_STATUS csMgmt_xmit(PSDevice pDevice, PSTxMgmtPacket pPacket) { pTxBufHead->wTimeStamp = cpu_to_le16(DEFAULT_MGN_LIFETIME_RES_64us); - if (IS_MULTICAST_ADDRESS(&(pPacket->p80211Header->sA3.abyAddr1[0])) || + if (is_multicast_ether_addr(&(pPacket->p80211Header->sA3.abyAddr1[0])) || IS_BROADCAST_ADDRESS(&(pPacket->p80211Header->sA3.abyAddr1[0]))) { bNeedACK = FALSE; } @@ -2760,7 +2760,7 @@ cbGetFragCount ( if ((pDevice->eOPMode == OP_MODE_ADHOC) || (pDevice->eOPMode == OP_MODE_AP)) { - if (IS_MULTICAST_ADDRESS(&(psEthHeader->abyDstAddr[0])) || + if (is_multicast_ether_addr(&(psEthHeader->abyDstAddr[0])) || IS_BROADCAST_ADDRESS(&(psEthHeader->abyDstAddr[0]))) { bNeedACK = FALSE; } @@ -2938,7 +2938,7 @@ vDMA0_tx_80211(PSDevice pDevice, struct sk_buff *skb, PBYTE pbMPDU, UINT cbMPDU pTxBufHead->wTimeStamp = cpu_to_le16(DEFAULT_MGN_LIFETIME_RES_64us); - if (IS_MULTICAST_ADDRESS(&(p80211Header->sA3.abyAddr1[0])) || + if (is_multicast_ether_addr(&(p80211Header->sA3.abyAddr1[0])) || IS_BROADCAST_ADDRESS(&(p80211Header->sA3.abyAddr1[0]))) { bNeedACK = FALSE; if (pDevice->bEnableHostWEP) { diff --git a/drivers/staging/vt6655/tether.h b/drivers/staging/vt6655/tether.h index 99fdc032d47ab17b7fa1d9276e330b093236d9f7..5365e7fadeab4e223fb1e2b1dd362d0bb6b7326c 100644 --- a/drivers/staging/vt6655/tether.h +++ b/drivers/staging/vt6655/tether.h @@ -29,7 +29,7 @@ #ifndef __TETHER_H__ #define __TETHER_H__ -#include +#include #include "ttype.h" /*--------------------- Export Definitions -------------------------*/ @@ -188,9 +188,6 @@ S802_11Header, *PS802_11Header; /*--------------------- Export Macros ------------------------------*/ // Frame type macro -#define IS_MULTICAST_ADDRESS(pbyEtherAddr) \ - ((*(PBYTE)(pbyEtherAddr) & 0x01) == 1) - #define IS_BROADCAST_ADDRESS(pbyEtherAddr) ( \ (*(PDWORD)(pbyEtherAddr) == 0xFFFFFFFFL) && \ (*(PWORD)((PBYTE)(pbyEtherAddr) + 4) == 0xFFFF) \