Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 171707
b: refs/heads/master
c: 2c74aa4
h: refs/heads/master
i:
  171705: 1967f18
  171703: d9e82a9
v: v3
  • Loading branch information
Luis R. Rodriguez authored and John W. Linville committed Nov 11, 2009
1 parent 181fba4 commit f6dc438
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 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: dd849782a7388e091e356373a744f8b7ae97188a
refs/heads/master: 2c74aa4d73dbed2e879e7eb5ee9de95d40e5298d
11 changes: 7 additions & 4 deletions trunk/drivers/net/wireless/ath/ath9k/recv.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,13 @@ static bool ath9k_rx_accept(struct ath_common *common,

if (!rx_stats->rs_datalen)
return false;
/*
* rs_status follows rs_datalen so if rs_datalen is too large
* we can take a hint that hardware corrupted it, so ignore
* those frames.
*/
if (rx_stats->rs_datalen > common->rx_bufsize)
return false;

if (rx_stats->rs_more) {
/*
Expand Down Expand Up @@ -801,10 +808,6 @@ int ath_rx_tasklet(struct ath_softc *sc, int flush)
if (flush)
goto requeue;

/* The status portion of the descriptor could get corrupted. */
if (common->rx_bufsize < rx_stats->rs_datalen)
goto requeue;

if (!ath_rx_prepare(common, hw, skb, rx_stats,
rxs, &decrypt_error))
goto requeue;
Expand Down

0 comments on commit f6dc438

Please sign in to comment.