Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 354051
b: refs/heads/master
c: 45c73bb
h: refs/heads/master
i:
  354049: 0b1db36
  354047: da6a08e
v: v3
  • Loading branch information
Malcolm Priestley authored and Greg Kroah-Hartman committed Jan 18, 2013
1 parent 0c2f8fc commit c611595
Show file tree
Hide file tree
Showing 9 changed files with 211 additions and 349 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: d56131def640daa8b802dd7ddbffff30846005ac
refs/heads/master: 45c73bb125eb763448c6d2d708e6a9baf0416ae5
68 changes: 28 additions & 40 deletions trunk/drivers/staging/vt6656/datarate.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,28 +188,19 @@ RATEwGetRateIdx(
* Return Value: none
*
-*/
void RATEvParseMaxRate(
void *pDeviceHandler,
PWLAN_IE_SUPP_RATES pItemRates,
PWLAN_IE_SUPP_RATES pItemExtRates,
BOOL bUpdateBasicRate,
PWORD pwMaxBasicRate,
PWORD pwMaxSuppRate,
PWORD pwSuppRate,
PBYTE pbyTopCCKRate,
PBYTE pbyTopOFDMRate
)
{
PSDevice pDevice = (PSDevice) pDeviceHandler;
unsigned int ii;
BYTE byHighSuppRate = 0;
BYTE byRate = 0;
WORD wOldBasicRate = pDevice->wBasicRate;
unsigned int uRateLen;

void RATEvParseMaxRate(struct vnt_private *pDevice,
PWLAN_IE_SUPP_RATES pItemRates, PWLAN_IE_SUPP_RATES pItemExtRates,
int bUpdateBasicRate, u16 *pwMaxBasicRate, u16 *pwMaxSuppRate,
u16 *pwSuppRate, u8 *pbyTopCCKRate, u8 *pbyTopOFDMRate)
{
int ii;
u8 byHighSuppRate = 0, byRate = 0;
u16 wOldBasicRate = pDevice->wBasicRate;
u32 uRateLen;

if (pItemRates == NULL)
return;
if (pItemRates == NULL)
return;

*pwSuppRate = 0;
uRateLen = pItemRates->len;
Expand Down Expand Up @@ -301,27 +292,24 @@ unsigned int uRateLen;
#define AUTORATE_TXCNT_THRESHOLD 20
#define AUTORATE_INC_THRESHOLD 30

void
RATEvTxRateFallBack(
void *pDeviceHandler,
PKnownNodeDB psNodeDBTable
)
void RATEvTxRateFallBack(struct vnt_private *pDevice,
PKnownNodeDB psNodeDBTable)
{
PSDevice pDevice = (PSDevice) pDeviceHandler;
PSMgmtObject pMgmt = &(pDevice->sMgmtObj);
WORD wIdxDownRate = 0;
unsigned int ii;
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;
WORD wIdxUpRate = 0;
DWORD dwTxDiff = 0;

if (pMgmt->eScanState != WMAC_NO_SCANNING) {
// Don't do Fallback when scanning Channel
return;
}
psNodeDBTable->uTimeCount ++;
struct vnt_manager *pMgmt = &pDevice->vnt_mgmt;
u16 wIdxDownRate = 0;
int ii;
int bAutoRate[MAX_RATE] = {TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE};
u32 dwThroughputTbl[MAX_RATE] = {10, 20, 55, 110, 60, 90, 120, 180,
240, 360, 480, 540};
u32 dwThroughput = 0;
u16 wIdxUpRate = 0;
u32 dwTxDiff = 0;

if (pMgmt->eScanState != WMAC_NO_SCANNING)
return; /* Don't do Fallback when scanning Channel */

psNodeDBTable->uTimeCount++;

if (psNodeDBTable->uTxFail[MAX_RATE] > psNodeDBTable->uTxOk[MAX_RATE])
dwTxDiff = psNodeDBTable->uTxFail[MAX_RATE] - psNodeDBTable->uTxOk[MAX_RATE];
Expand Down
24 changes: 7 additions & 17 deletions trunk/drivers/staging/vt6656/datarate.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
#ifndef __DATARATE_H__
#define __DATARATE_H__


/*--------------------- Export Definitions -------------------------*/

#define FALLBACK_PKT_COLLECT_TR_H 50 // pkts
Expand Down Expand Up @@ -69,24 +70,13 @@



void
RATEvParseMaxRate(
void *pDeviceHandler,
PWLAN_IE_SUPP_RATES pItemRates,
PWLAN_IE_SUPP_RATES pItemExtRates,
BOOL bUpdateBasicRate,
PWORD pwMaxBasicRate,
PWORD pwMaxSuppRate,
PWORD pwSuppRate,
PBYTE pbyTopCCKRate,
PBYTE pbyTopOFDMRate
);
void RATEvParseMaxRate(struct vnt_private *, PWLAN_IE_SUPP_RATES pItemRates,
PWLAN_IE_SUPP_RATES pItemExtRates, int bUpdateBasicRate,
u16 *pwMaxBasicRate, u16 *pwMaxSuppRate, u16 *pwSuppRate,
u8 *pbyTopCCKRate, u8 *pbyTopOFDMRate);

void
RATEvTxRateFallBack(
void *pDeviceHandler,
PKnownNodeDB psNodeDBTable
);
void RATEvTxRateFallBack(struct vnt_private *pDevice,
PKnownNodeDB psNodeDBTable);

BYTE
RATEuSetIE(
Expand Down
Loading

0 comments on commit c611595

Please sign in to comment.