Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 220251
b: refs/heads/master
c: 697d600
h: refs/heads/master
i:
  220249: 5f8a398
  220247: 69f6e82
v: v3
  • Loading branch information
Greg Kroah-Hartman committed Oct 8, 2010
1 parent 28a9a03 commit f812a7e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 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: e9e6727fcc6ef9aee763eaa35cc980f5b3a2a68c
refs/heads/master: 697d600d8fa9d383626041a8dde86555fb758b76
10 changes: 5 additions & 5 deletions trunk/drivers/staging/brcm80211/sys/wlc_ampdu.c
Original file line number Diff line number Diff line change
Expand Up @@ -290,11 +290,11 @@ static void scb_ampdu_update_config(ampdu_info_t *ampdu, struct scb *scb)
if (ampdu->max_pdu != AUTO)
scb_ampdu->max_pdu = (u8) ampdu->max_pdu;

scb_ampdu->release = min(scb_ampdu->max_pdu, AMPDU_SCB_MAX_RELEASE);
scb_ampdu->release = min_t(u8, scb_ampdu->max_pdu, AMPDU_SCB_MAX_RELEASE);

if (scb_ampdu->max_rxlen)
scb_ampdu->release =
min(scb_ampdu->release, scb_ampdu->max_rxlen / 1600);
min_t(u8, scb_ampdu->release, scb_ampdu->max_rxlen / 1600);

scb_ampdu->release = min(scb_ampdu->release,
ampdu->fifo_tb[TX_AC_BE_FIFO].
Expand Down Expand Up @@ -396,7 +396,7 @@ static int wlc_ffpld_check_txfunfl(wlc_info_t *wlc, int fid)
return 0;
}
max_mpdu =
min(fifo->mcs2ampdu_table[FFPLD_MAX_MCS], AMPDU_NUM_MPDU_LEGACY);
min_t(u8, fifo->mcs2ampdu_table[FFPLD_MAX_MCS], AMPDU_NUM_MPDU_LEGACY);

/* In case max value max_pdu is already lower than
the fifo depth, there is nothing more we can do.
Expand Down Expand Up @@ -462,7 +462,7 @@ static void wlc_ffpld_calc_mcs2ampdu_table(ampdu_info_t *ampdu, int f)
/* recompute the dma rate */
/* note : we divide/multiply by 100 to avoid integer overflows */
max_mpdu =
min(fifo->mcs2ampdu_table[FFPLD_MAX_MCS], AMPDU_NUM_MPDU_LEGACY);
min_t(u8, fifo->mcs2ampdu_table[FFPLD_MAX_MCS], AMPDU_NUM_MPDU_LEGACY);
phy_rate = MCS_RATE(FFPLD_MAX_MCS, TRUE, FALSE);
dma_rate =
(((phy_rate / 100) *
Expand All @@ -478,7 +478,7 @@ static void wlc_ffpld_calc_mcs2ampdu_table(ampdu_info_t *ampdu, int f)
if (phy_rate > dma_rate) {
tmp = ((fifo->ampdu_pld_size * phy_rate) /
((phy_rate - dma_rate) * FFPLD_MPDU_SIZE)) + 1;
tmp = min(tmp, 255);
tmp = min_t(u32, tmp, 255);
fifo->mcs2ampdu_table[i] = (u8) tmp;
}
}
Expand Down

0 comments on commit f812a7e

Please sign in to comment.