Commit 4d99952d authored by Malcolm Priestley's avatar Malcolm Priestley Committed by Greg Kroah-Hartman

staging: vt6656: checkpatch cleanup BBuGetFrameTime.

clean up white space.
Signed-off-by: default avatarMalcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 2a4ee86f
...@@ -663,53 +663,47 @@ s_vClearSQ3Value(PSDevice pDevice); ...@@ -663,53 +663,47 @@ s_vClearSQ3Value(PSDevice pDevice);
* Return Value: FrameTime * Return Value: FrameTime
* *
*/ */
unsigned int unsigned int BBuGetFrameTime(u8 byPreambleType, u8 byPktType,
BBuGetFrameTime( unsigned int cbFrameLength, u16 wRate)
u8 byPreambleType,
u8 byPktType,
unsigned int cbFrameLength,
u16 wRate
)
{ {
unsigned int uFrameTime; unsigned int uFrameTime;
unsigned int uPreamble; unsigned int uPreamble;
unsigned int uTmp; unsigned int uTmp;
unsigned int uRateIdx = (unsigned int)wRate; unsigned int uRateIdx = (unsigned int)wRate;
unsigned int uRate = 0; unsigned int uRate = 0;
if (uRateIdx > RATE_54M) {
return 0;
}
uRate = (unsigned int)awcFrameTime[uRateIdx]; if (uRateIdx > RATE_54M)
return 0;
if (uRateIdx <= 3) { //CCK mode uRate = (unsigned int)awcFrameTime[uRateIdx];
if (byPreambleType == 1) {//Short if (uRateIdx <= 3) {
uPreamble = 96; if (byPreambleType == 1)
} else { uPreamble = 96;
uPreamble = 192; else
} uPreamble = 192;
uFrameTime = (cbFrameLength * 80) / uRate; //?????
uTmp = (uFrameTime * uRate) / 80;
if (cbFrameLength != uTmp) {
uFrameTime ++;
}
return (uPreamble + uFrameTime); uFrameTime = (cbFrameLength * 80) / uRate;
} uTmp = (uFrameTime * uRate) / 80;
else {
uFrameTime = (cbFrameLength * 8 + 22) / uRate; //???????? if (cbFrameLength != uTmp)
uTmp = ((uFrameTime * uRate) - 22) / 8; uFrameTime++;
if(cbFrameLength != uTmp) {
uFrameTime ++; return uPreamble + uFrameTime;
} } else {
uFrameTime = uFrameTime * 4; //??????? uFrameTime = (cbFrameLength * 8 + 22) / uRate;
if(byPktType != PK_TYPE_11A) { uTmp = ((uFrameTime * uRate) - 22) / 8;
uFrameTime += 6;
} if (cbFrameLength != uTmp)
return (20 + uFrameTime); //?????? uFrameTime++;
}
uFrameTime = uFrameTime * 4;
if (byPktType != PK_TYPE_11A)
uFrameTime += 6;
return 20 + uFrameTime;
}
} }
/* /*
......
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