From: Ivo van Doorn <ivdoorn@gmail.com>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linux-wireless@vger.kernel.org, rt2400-devel@lists.sourceforge.net
Subject: [PATCH 1/5] rt2x00: use rate index in TX control
Date: Sat, 10 May 2008 13:49:49 +0200 [thread overview]
Message-ID: <200805101349.49618.IvDoorn@gmail.com> (raw)
In-Reply-To: <200805101349.19481.IvDoorn@gmail.com>
Use the new functions ieee80211_get_tx_rate() and
ieee80211_get_rts_cts_rate() provided by patch:
mac80211: use rate index in TX control
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
---
drivers/net/wireless/rt2x00/rt2x00queue.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.c b/drivers/net/wireless/rt2x00/rt2x00queue.c
index 19c1062..5cf4c2f 100644
--- a/drivers/net/wireless/rt2x00/rt2x00queue.c
+++ b/drivers/net/wireless/rt2x00/rt2x00queue.c
@@ -33,8 +33,10 @@ void rt2x00queue_create_tx_descriptor(struct queue_entry *entry,
struct txentry_desc *txdesc,
struct ieee80211_tx_control *control)
{
+ struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)entry->skb->data;
- struct ieee80211_rate *rate = control->tx_rate;
+ struct ieee80211_rate *rate =
+ ieee80211_get_tx_rate(rt2x00dev->hw, control);
const struct rt2x00_rate *hwrate;
unsigned int data_length;
unsigned int duration;
@@ -77,8 +79,9 @@ void rt2x00queue_create_tx_descriptor(struct queue_entry *entry,
__set_bit(ENTRY_TXD_CTS_FRAME, &txdesc->flags);
__clear_bit(ENTRY_TXD_ACK, &txdesc->flags);
}
- if (control->rts_cts_rate)
- rate = control->rts_cts_rate;
+ if (control->rts_cts_rate_idx >= 0)
+ rate =
+ ieee80211_get_rts_cts_rate(rt2x00dev->hw, control);
}
/*
--
1.5.5.1
next prev parent reply other threads:[~2008-05-10 12:10 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-10 11:49 [PATCH 0/5] mac80211 & rt2x00 updates Ivo van Doorn
2008-05-10 11:49 ` Ivo van Doorn [this message]
2008-05-10 11:50 ` [PATCH 3/5] rt2x00: use multi-queue master netdevice Ivo van Doorn
2008-05-10 11:50 ` [PATCH 2/5] mac80211: Initialize sta pointer Ivo van Doorn
2008-05-10 16:22 ` Johannes Berg
2008-05-10 11:51 ` [PATCH 4/5] rt2x00: Convert rt2x00 to read control info from skb->cb Ivo van Doorn
2008-05-10 21:20 ` Johannes Berg
2008-05-11 9:13 ` Ivo van Doorn
2008-05-11 11:33 ` Ivo van Doorn
2008-05-11 11:49 ` Johannes Berg
2008-05-11 12:13 ` Ivo van Doorn
2008-05-10 11:51 ` [PATCH 5/5] mac80211: Match define names in comments with actual defines Ivo van Doorn
2008-05-10 16:21 ` Johannes Berg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200805101349.49618.IvDoorn@gmail.com \
--to=ivdoorn@gmail.com \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=rt2400-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).