Commit 63182376 authored by Marcos Paulo de Souza's avatar Marcos Paulo de Souza Committed by Greg Kroah-Hartman

staging: vt6656: 80211mgr.c: Code cleanup, removed return of void funcs.

Removed return call of void functions. Removed some code style issues.
Signed-off-by: default avatarMarcos Paulo de Souza <marcos.mage@gmail.com>
Cc: Forest Bond <forest@alittletooquiet.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent ac31e9e8
...@@ -224,8 +224,6 @@ vMgrDecodeBeacon( ...@@ -224,8 +224,6 @@ vMgrDecodeBeacon(
} }
pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len); pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len);
} }
return;
} }
...@@ -248,8 +246,6 @@ vMgrEncodeIBSSATIM( ...@@ -248,8 +246,6 @@ vMgrEncodeIBSSATIM(
{ {
pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf; pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf;
pFrame->len = WLAN_HDR_ADDR3_LEN; pFrame->len = WLAN_HDR_ADDR3_LEN;
return;
} }
...@@ -270,8 +266,6 @@ vMgrDecodeIBSSATIM( ...@@ -270,8 +266,6 @@ vMgrDecodeIBSSATIM(
) )
{ {
pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf; pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf;
return;
} }
...@@ -298,8 +292,6 @@ vMgrEncodeDisassociation( ...@@ -298,8 +292,6 @@ vMgrEncodeDisassociation(
pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_DISASSOC_OFF_REASON); + WLAN_DISASSOC_OFF_REASON);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_DISASSOC_OFF_REASON + sizeof(*(pFrame->pwReason)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_DISASSOC_OFF_REASON + sizeof(*(pFrame->pwReason));
return;
} }
...@@ -324,8 +316,6 @@ vMgrDecodeDisassociation( ...@@ -324,8 +316,6 @@ vMgrDecodeDisassociation(
/* Fixed Fields */ /* Fixed Fields */
pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_DISASSOC_OFF_REASON); + WLAN_DISASSOC_OFF_REASON);
return;
} }
/*+ /*+
...@@ -352,7 +342,6 @@ vMgrEncodeAssocRequest( ...@@ -352,7 +342,6 @@ vMgrEncodeAssocRequest(
pFrame->pwListenInterval = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwListenInterval = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_ASSOCREQ_OFF_LISTEN_INT); + WLAN_ASSOCREQ_OFF_LISTEN_INT);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_ASSOCREQ_OFF_LISTEN_INT + sizeof(*(pFrame->pwListenInterval)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_ASSOCREQ_OFF_LISTEN_INT + sizeof(*(pFrame->pwListenInterval));
return;
} }
...@@ -418,7 +407,6 @@ vMgrDecodeAssocRequest( ...@@ -418,7 +407,6 @@ vMgrDecodeAssocRequest(
} }
pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len); pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len);
} }
return;
} }
/*+ /*+
...@@ -448,8 +436,6 @@ vMgrEncodeAssocResponse( ...@@ -448,8 +436,6 @@ vMgrEncodeAssocResponse(
+ WLAN_ASSOCRESP_OFF_AID); + WLAN_ASSOCRESP_OFF_AID);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_ASSOCRESP_OFF_AID pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_ASSOCRESP_OFF_AID
+ sizeof(*(pFrame->pwAid)); + sizeof(*(pFrame->pwAid));
return;
} }
...@@ -491,10 +477,8 @@ vMgrDecodeAssocResponse( ...@@ -491,10 +477,8 @@ vMgrDecodeAssocResponse(
if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_EXTSUPP_RATES)) { if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_EXTSUPP_RATES)) {
pFrame->pExtSuppRates = (PWLAN_IE_SUPP_RATES)pItem; pFrame->pExtSuppRates = (PWLAN_IE_SUPP_RATES)pItem;
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "pFrame->pExtSuppRates=[%p].\n", pItem); DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "pFrame->pExtSuppRates=[%p].\n", pItem);
} else { } else
pFrame->pExtSuppRates = NULL; pFrame->pExtSuppRates = NULL;
}
return;
} }
...@@ -524,8 +508,6 @@ vMgrEncodeReassocRequest( ...@@ -524,8 +508,6 @@ vMgrEncodeReassocRequest(
pFrame->pAddrCurrAP = (PIEEE_ADDR)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pAddrCurrAP = (PIEEE_ADDR)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_REASSOCREQ_OFF_CURR_AP); + WLAN_REASSOCREQ_OFF_CURR_AP);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_REASSOCREQ_OFF_CURR_AP + sizeof(*(pFrame->pAddrCurrAP)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_REASSOCREQ_OFF_CURR_AP + sizeof(*(pFrame->pAddrCurrAP));
return;
} }
...@@ -578,10 +560,9 @@ vMgrDecodeReassocRequest( ...@@ -578,10 +560,9 @@ vMgrDecodeReassocRequest(
pFrame->pRSN = (PWLAN_IE_RSN)pItem; pFrame->pRSN = (PWLAN_IE_RSN)pItem;
break; break;
case WLAN_EID_RSN_WPA: case WLAN_EID_RSN_WPA:
if (pFrame->pRSNWPA == NULL) { if (pFrame->pRSNWPA == NULL)
if (WPAb_Is_RSN((PWLAN_IE_RSN_EXT)pItem) == TRUE) if (WPAb_Is_RSN((PWLAN_IE_RSN_EXT)pItem) == TRUE)
pFrame->pRSNWPA = (PWLAN_IE_RSN_EXT)pItem; pFrame->pRSNWPA = (PWLAN_IE_RSN_EXT)pItem;
}
break; break;
case WLAN_EID_EXTSUPP_RATES: case WLAN_EID_EXTSUPP_RATES:
...@@ -595,7 +576,6 @@ vMgrDecodeReassocRequest( ...@@ -595,7 +576,6 @@ vMgrDecodeReassocRequest(
} }
pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len); pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len);
} }
return;
} }
...@@ -619,7 +599,6 @@ vMgrEncodeProbeRequest( ...@@ -619,7 +599,6 @@ vMgrEncodeProbeRequest(
{ {
pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf; pFrame->pHdr = (PUWLAN_80211HDR)pFrame->pBuf;
pFrame->len = WLAN_HDR_ADDR3_LEN; pFrame->len = WLAN_HDR_ADDR3_LEN;
return;
} }
/*+ /*+
...@@ -670,7 +649,6 @@ vMgrDecodeProbeRequest( ...@@ -670,7 +649,6 @@ vMgrDecodeProbeRequest(
pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len); pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len);
} }
return;
} }
...@@ -703,8 +681,6 @@ vMgrEncodeProbeResponse( ...@@ -703,8 +681,6 @@ vMgrEncodeProbeResponse(
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_PROBERESP_OFF_CAP_INFO + pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_PROBERESP_OFF_CAP_INFO +
sizeof(*(pFrame->pwCapInfo)); sizeof(*(pFrame->pwCapInfo));
return;
} }
...@@ -818,7 +794,6 @@ vMgrDecodeProbeResponse( ...@@ -818,7 +794,6 @@ vMgrDecodeProbeResponse(
pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len); pItem = (PWLAN_IE)(((PBYTE)pItem) + 2 + pItem->len);
} }
return;
} }
...@@ -848,7 +823,6 @@ vMgrEncodeAuthen( ...@@ -848,7 +823,6 @@ vMgrEncodeAuthen(
pFrame->pwStatus = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwStatus = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_AUTHEN_OFF_STATUS); + WLAN_AUTHEN_OFF_STATUS);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_AUTHEN_OFF_STATUS + sizeof(*(pFrame->pwStatus)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_AUTHEN_OFF_STATUS + sizeof(*(pFrame->pwStatus));
return;
} }
...@@ -886,7 +860,6 @@ vMgrDecodeAuthen( ...@@ -886,7 +860,6 @@ vMgrDecodeAuthen(
if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_CHALLENGE)) if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_CHALLENGE))
pFrame->pChallenge = (PWLAN_IE_CHALLENGE)pItem; pFrame->pChallenge = (PWLAN_IE_CHALLENGE)pItem;
return;
} }
...@@ -912,7 +885,6 @@ vMgrEncodeDeauthen( ...@@ -912,7 +885,6 @@ vMgrEncodeDeauthen(
pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_DEAUTHEN_OFF_REASON); + WLAN_DEAUTHEN_OFF_REASON);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_DEAUTHEN_OFF_REASON + sizeof(*(pFrame->pwReason)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_DEAUTHEN_OFF_REASON + sizeof(*(pFrame->pwReason));
return;
} }
...@@ -937,7 +909,6 @@ vMgrDecodeDeauthen( ...@@ -937,7 +909,6 @@ vMgrDecodeDeauthen(
/* Fixed Fields */ /* Fixed Fields */
pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3)) pFrame->pwReason = (PWORD)(WLAN_HDR_A3_DATA_PTR(&(pFrame->pHdr->sA3))
+ WLAN_DEAUTHEN_OFF_REASON); + WLAN_DEAUTHEN_OFF_REASON);
return;
} }
...@@ -968,7 +939,6 @@ vMgrEncodeReassocResponse( ...@@ -968,7 +939,6 @@ vMgrEncodeReassocResponse(
+ WLAN_REASSOCRESP_OFF_AID); + WLAN_REASSOCRESP_OFF_AID);
pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_REASSOCRESP_OFF_AID + sizeof(*(pFrame->pwAid)); pFrame->len = WLAN_HDR_ADDR3_LEN + WLAN_REASSOCRESP_OFF_AID + sizeof(*(pFrame->pwAid));
return;
} }
...@@ -1010,5 +980,4 @@ vMgrDecodeReassocResponse( ...@@ -1010,5 +980,4 @@ vMgrDecodeReassocResponse(
if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_EXTSUPP_RATES)) if ((((PBYTE)pItem) < (pFrame->pBuf + pFrame->len)) && (pItem->byElementID == WLAN_EID_EXTSUPP_RATES))
pFrame->pExtSuppRates = (PWLAN_IE_SUPP_RATES)pItem; pFrame->pExtSuppRates = (PWLAN_IE_SUPP_RATES)pItem;
return;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment