diff options
author | Jim Lieb <lieb@canonical.com> | 2009-07-30 13:27:21 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-09-15 15:02:07 -0400 |
commit | 7e809a9b10ab5ee985e23dea537e0236f026d1ca (patch) | |
tree | 450b5cda1963436a6202cc88661875e6250753b0 /drivers/staging/vt6655/wpa.c | |
parent | d899d403862863cf2230432e18e7b294a517fd96 (diff) |
Staging: vt6655 textual cleanup in prep for driver merge
The vt6655 and vt6656 drivers are from a common origin but
have drifted apart with minor textual differences. There
are two changes:
s/DEVICE_PRT/DBG_PRT/g
and
s/byPktTyp/byPktType/g
This significantly reduces the differences between the two file sets
in preparation to merging the common code. A few whitespace and text bits were
also adjusted.
Signed-off-by: Jim Lieb <lieb@canonical.com>
Cc: Forest Bond <forest@alittletooquiet.net>
Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/vt6655/wpa.c')
-rw-r--r-- | drivers/staging/vt6655/wpa.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/staging/vt6655/wpa.c b/drivers/staging/vt6655/wpa.c index 87abae46472..93614a06efe 100644 --- a/drivers/staging/vt6655/wpa.c +++ b/drivers/staging/vt6655/wpa.c | |||
@@ -139,14 +139,14 @@ WPA_ParseRSN ( | |||
139 | 139 | ||
140 | WPA_ClearRSN(pBSSList); | 140 | WPA_ClearRSN(pBSSList); |
141 | 141 | ||
142 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"WPA_ParseRSN: [%d]\n", pRSN->len); | 142 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"WPA_ParseRSN: [%d]\n", pRSN->len); |
143 | 143 | ||
144 | // information element header makes sense | 144 | // information element header makes sense |
145 | if ((pRSN->len >= 6) // oui1(4)+ver(2) | 145 | if ((pRSN->len >= 6) // oui1(4)+ver(2) |
146 | && (pRSN->byElementID == WLAN_EID_RSN_WPA) && MEMEqualMemory(pRSN->abyOUI, abyOUI01, 4) | 146 | && (pRSN->byElementID == WLAN_EID_RSN_WPA) && MEMEqualMemory(pRSN->abyOUI, abyOUI01, 4) |
147 | && (pRSN->wVersion == 1)) { | 147 | && (pRSN->wVersion == 1)) { |
148 | 148 | ||
149 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"Legal RSN\n"); | 149 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"Legal RSN\n"); |
150 | // update each variable if pRSN is long enough to contain the variable | 150 | // update each variable if pRSN is long enough to contain the variable |
151 | if (pRSN->len >= 10) //oui1(4)+ver(2)+GKSuite(4) | 151 | if (pRSN->len >= 10) //oui1(4)+ver(2)+GKSuite(4) |
152 | { | 152 | { |
@@ -164,13 +164,13 @@ WPA_ParseRSN ( | |||
164 | // any vendor checks here | 164 | // any vendor checks here |
165 | pBSSList->byGKType = WPA_NONE; | 165 | pBSSList->byGKType = WPA_NONE; |
166 | 166 | ||
167 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"byGKType: %x\n", pBSSList->byGKType); | 167 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"byGKType: %x\n", pBSSList->byGKType); |
168 | } | 168 | } |
169 | 169 | ||
170 | if (pRSN->len >= 12) //oui1(4)+ver(2)+GKS(4)+PKSCnt(2) | 170 | if (pRSN->len >= 12) //oui1(4)+ver(2)+GKS(4)+PKSCnt(2) |
171 | { | 171 | { |
172 | j = 0; | 172 | j = 0; |
173 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wPKCount: %d, sizeof(pBSSList->abyPKType): %ld\n", pRSN->wPKCount, sizeof(pBSSList->abyPKType)); | 173 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wPKCount: %d, sizeof(pBSSList->abyPKType): %ld\n", pRSN->wPKCount, sizeof(pBSSList->abyPKType)); |
174 | for(i = 0; (i < pRSN->wPKCount) && (j < sizeof(pBSSList->abyPKType)/sizeof(BYTE)); i++) { | 174 | for(i = 0; (i < pRSN->wPKCount) && (j < sizeof(pBSSList->abyPKType)/sizeof(BYTE)); i++) { |
175 | if(pRSN->len >= 12+i*4+4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*i) | 175 | if(pRSN->len >= 12+i*4+4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*i) |
176 | if (MEMEqualMemory(pRSN->PKSList[i].abyOUI, abyOUI00, 4)) | 176 | if (MEMEqualMemory(pRSN->PKSList[i].abyOUI, abyOUI00, 4)) |
@@ -190,18 +190,18 @@ WPA_ParseRSN ( | |||
190 | //DBG_PRN_GRP14(("abyPKType[%d]: %X\n", j-1, pBSSList->abyPKType[j-1])); | 190 | //DBG_PRN_GRP14(("abyPKType[%d]: %X\n", j-1, pBSSList->abyPKType[j-1])); |
191 | } //for | 191 | } //for |
192 | pBSSList->wPKCount = (WORD)j; | 192 | pBSSList->wPKCount = (WORD)j; |
193 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wPKCount: %d\n", pBSSList->wPKCount); | 193 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wPKCount: %d\n", pBSSList->wPKCount); |
194 | } | 194 | } |
195 | 195 | ||
196 | m = pRSN->wPKCount; | 196 | m = pRSN->wPKCount; |
197 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"m: %d\n", m); | 197 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"m: %d\n", m); |
198 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"14+m*4: %d\n", 14+m*4); | 198 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"14+m*4: %d\n", 14+m*4); |
199 | 199 | ||
200 | if (pRSN->len >= 14+m*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2) | 200 | if (pRSN->len >= 14+m*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2) |
201 | // overlay IE_RSN_Auth structure into correct place | 201 | // overlay IE_RSN_Auth structure into correct place |
202 | pIE_RSN_Auth = (PWLAN_IE_RSN_AUTH) pRSN->PKSList[m].abyOUI; | 202 | pIE_RSN_Auth = (PWLAN_IE_RSN_AUTH) pRSN->PKSList[m].abyOUI; |
203 | j = 0; | 203 | j = 0; |
204 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wAuthCount: %d, sizeof(pBSSList->abyAuthType): %ld\n", | 204 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wAuthCount: %d, sizeof(pBSSList->abyAuthType): %ld\n", |
205 | pIE_RSN_Auth->wAuthCount, sizeof(pBSSList->abyAuthType)); | 205 | pIE_RSN_Auth->wAuthCount, sizeof(pBSSList->abyAuthType)); |
206 | for(i = 0; (i < pIE_RSN_Auth->wAuthCount) && (j < sizeof(pBSSList->abyAuthType)/sizeof(BYTE)); i++) { | 206 | for(i = 0; (i < pIE_RSN_Auth->wAuthCount) && (j < sizeof(pBSSList->abyAuthType)/sizeof(BYTE)); i++) { |
207 | if(pRSN->len >= 14+4+(m+i)*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2)+AKS(4*i) | 207 | if(pRSN->len >= 14+4+(m+i)*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2)+AKS(4*i) |
@@ -219,15 +219,15 @@ WPA_ParseRSN ( | |||
219 | } | 219 | } |
220 | if(j > 0) | 220 | if(j > 0) |
221 | pBSSList->wAuthCount = (WORD)j; | 221 | pBSSList->wAuthCount = (WORD)j; |
222 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wAuthCount: %d\n", pBSSList->wAuthCount); | 222 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"wAuthCount: %d\n", pBSSList->wAuthCount); |
223 | } | 223 | } |
224 | 224 | ||
225 | if (pIE_RSN_Auth != NULL) { | 225 | if (pIE_RSN_Auth != NULL) { |
226 | 226 | ||
227 | n = pIE_RSN_Auth->wAuthCount; | 227 | n = pIE_RSN_Auth->wAuthCount; |
228 | 228 | ||
229 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"n: %d\n", n); | 229 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"n: %d\n", n); |
230 | DEVICE_PRT(MSG_LEVEL_DEBUG, KERN_INFO"14+4+(m+n)*4: %d\n", 14+4+(m+n)*4); | 230 | DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"14+4+(m+n)*4: %d\n", 14+4+(m+n)*4); |
231 | 231 | ||
232 | if(pRSN->len+2 >= 14+4+(m+n)*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2)+AKS(4*n)+Cap(2) | 232 | if(pRSN->len+2 >= 14+4+(m+n)*4) { //oui1(4)+ver(2)+GKS(4)+PKSCnt(2)+PKS(4*m)+AKC(2)+AKS(4*n)+Cap(2) |
233 | pbyCaps = (PBYTE)pIE_RSN_Auth->AuthKSList[n].abyOUI; | 233 | pbyCaps = (PBYTE)pIE_RSN_Auth->AuthKSList[n].abyOUI; |