From: Reinette Chatre <reinette.chatre@intel.com>
To: linville@tuxdriver.com, johannes@sipsolutions.net
Cc: linux-wireless@vger.kernel.org,
ipw3945-devel@lists.sourceforge.net,
Tomas Winkler <tomas.winkler@intel.com>,
Gregory Greenman <gregory.greenman@intel.com>
Subject: [PATCH 3/4] mac80211: add association capabilty and timing info into bss_conf
Date: Fri, 28 Mar 2008 16:33:34 -0700 [thread overview]
Message-ID: <1206747215-10640-4-git-send-email-reinette.chatre@intel.com> (raw)
In-Reply-To: <1206747215-10640-3-git-send-email-reinette.chatre@intel.com>
From: Tomas Winkler <tomas.winkler@intel.com>
This patch adds assocation capability, timestamp (tsf) and beacon interval
to bss_conf. This is required for successful assocation of iwlwifi drivers
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
---
include/net/mac80211.h | 6 ++++++
net/mac80211/ieee80211_sta.c | 9 ++++++++-
2 files changed, 14 insertions(+), 1 deletions(-)
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index dddc69b..cd1865f 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -211,6 +211,9 @@ enum ieee80211_bss_change {
* @aid: association ID number, valid only when @assoc is true
* @use_cts_prot: use CTS protection
* @use_short_preamble: use 802.11b short preamble
+ * @timestamp: beacon timestamp
+ * @beacon_int: beacon interval
+ * @assoc_capability: capabbilities taken from assoc resp
* @assoc_ht: association in HT mode
* @ht_conf: ht capabilities
* @ht_bss_conf: ht extended capabilities
@@ -222,6 +225,9 @@ struct ieee80211_bss_conf {
/* erp related data */
bool use_cts_prot;
bool use_short_preamble;
+ u16 beacon_int;
+ u16 assoc_capability;
+ u64 timestamp;
/* ht related data */
bool assoc_ht;
struct ieee80211_ht_info *ht_conf;
diff --git a/net/mac80211/ieee80211_sta.c b/net/mac80211/ieee80211_sta.c
index 59d1060..fbae79f 100644
--- a/net/mac80211/ieee80211_sta.c
+++ b/net/mac80211/ieee80211_sta.c
@@ -511,9 +511,14 @@ static void ieee80211_set_associated(struct net_device *dev,
conf->channel->center_freq,
ifsta->ssid, ifsta->ssid_len);
if (bss) {
+ /* set timing information */
+ sdata->bss_conf.beacon_int = bss->beacon_int;
+ sdata->bss_conf.timestamp = bss->timestamp;
+
if (bss->has_erp_value)
changed |= ieee80211_handle_erp_ie(
sdata, bss->erp_value);
+
ieee80211_rx_bss_put(dev, bss);
}
@@ -2037,8 +2042,10 @@ static void ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_if_data *sdata,
} else
rcu_read_unlock();
- /* set AID, ieee80211_set_associated() will tell the driver */
+ /* set AID and assoc capability,
+ * ieee80211_set_associated() will tell the driver */
bss_conf->aid = aid;
+ bss_conf->assoc_capability = capab_info;
ieee80211_set_associated(dev, ifsta, 1);
ieee80211_associated(dev, ifsta);
--
1.5.3.4
next prev parent reply other threads:[~2008-03-28 23:33 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-28 23:33 [PATCH 0/4] mac80211 and iwlwifi driver updates Reinette Chatre
2008-03-28 23:33 ` [PATCH 1/4] mac80211: eliminate conf_ht Reinette Chatre
2008-03-28 23:33 ` [PATCH 2/4] iwlwifi: " Reinette Chatre
2008-03-28 23:33 ` Reinette Chatre [this message]
2008-03-28 23:33 ` [PATCH 4/4] iwlwifi: Eliminate association from beacon Reinette Chatre
2008-04-02 21:00 ` [PATCH 0/4] mac80211 and iwlwifi driver updates Chatre, Reinette
2008-04-03 10:46 ` 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=1206747215-10640-4-git-send-email-reinette.chatre@intel.com \
--to=reinette.chatre@intel.com \
--cc=gregory.greenman@intel.com \
--cc=ipw3945-devel@lists.sourceforge.net \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=tomas.winkler@intel.com \
/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