diff options
author | Luis R. Rodriguez <lrodriguez@atheros.com> | 2009-11-05 17:10:07 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-11-11 17:09:11 -0500 |
commit | 748d451028ef037576b57517bc81e62f1fd92250 (patch) | |
tree | 2ba22c30d483c51f691ba72910baab883898abae /drivers | |
parent | 165864d08774823e3b88d5fcf4dad302700612e3 (diff) |
ath9k_common: clarify and correct jumbogram processing
Jumbograms are frames put together linked together through
more than one descriptor. For example ath9k_htc will use this
to send from the target a large frame split up into 2 or more
segments. The driver then would be in charge of putting the
frame back together.
When jumbograms are constructed the rx_stats->rs_more will
bet set and rx_stats->rs_status will not have any valid content
as the actual status will only be avialable at the end of
the chained descriptors.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/common.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/drivers/net/wireless/ath/ath9k/common.c b/drivers/net/wireless/ath/ath9k/common.c index 80edf7a302c..acd4bb503df 100644 --- a/drivers/net/wireless/ath/ath9k/common.c +++ b/drivers/net/wireless/ath/ath9k/common.c | |||
@@ -53,16 +53,17 @@ static bool ath9k_rx_accept(struct ath_common *common, | |||
53 | if (rx_stats->rs_datalen > common->rx_bufsize) | 53 | if (rx_stats->rs_datalen > common->rx_bufsize) |
54 | return false; | 54 | return false; |
55 | 55 | ||
56 | if (rx_stats->rs_more) { | 56 | /* |
57 | /* | 57 | * rs_more indicates chained descriptors which can be used |
58 | * Frame spans multiple descriptors; this cannot happen yet | 58 | * to link buffers together for a sort of scatter-gather |
59 | * as we don't support jumbograms. If not in monitor mode, | 59 | * operation. |
60 | * discard the frame. Enable this if you want to see | 60 | * |
61 | * error frames in Monitor mode. | 61 | * The rx_stats->rs_status will not be set until the end of the |
62 | */ | 62 | * chained descriptors so it can be ignored if rs_more is set. The |
63 | if (ah->opmode != NL80211_IFTYPE_MONITOR) | 63 | * rs_more will be false at the last element of the chained |
64 | return false; | 64 | * descriptors. |
65 | } else if (rx_stats->rs_status != 0) { | 65 | */ |
66 | if (!rx_stats->rs_more && rx_stats->rs_status != 0) { | ||
66 | if (rx_stats->rs_status & ATH9K_RXERR_CRC) | 67 | if (rx_stats->rs_status & ATH9K_RXERR_CRC) |
67 | rxs->flag |= RX_FLAG_FAILED_FCS_CRC; | 68 | rxs->flag |= RX_FLAG_FAILED_FCS_CRC; |
68 | if (rx_stats->rs_status & ATH9K_RXERR_PHY) | 69 | if (rx_stats->rs_status & ATH9K_RXERR_PHY) |