From: David Kimdon <david.kimdon@devicescape•com>
To: netdev@vger•kernel.org
Cc: "John W. Linville" <linville@tuxdriver•com>,
Jiri Benc <jbenc@suse•cz>,
David Kimdon <david.kimdon@devicescape•com>
Subject: [patch] d80211: fix usage of capability field for ibss mode
Date: Sun, 12 Nov 2006 10:15:05 -0800 [thread overview]
Message-ID: <20061112181505.GB13434@devicescape.com> (raw)
[-- Attachment #1: bss_capability_endian.patch --]
[-- Type: text/plain, Size: 1182 bytes --]
Thanks to sparse for pointing out these errors.
'capability' is stored in struct ieee80211_sta_bss in host byte order, do not
swap bytes.
Signed-off-by: David Kimdon <david.kimdon@devicescape•com>
Index: wireless-dev/net/d80211/ieee80211_sta.c
===================================================================
--- wireless-dev.orig/net/d80211/ieee80211_sta.c 2006-11-05 14:53:19.602141912 -0800
+++ wireless-dev/net/d80211/ieee80211_sta.c 2006-11-05 15:12:52.937767784 -0800
@@ -1984,7 +1984,7 @@
sdata = IEEE80211_DEV_TO_SUB_IF(dev);
sdata->drop_unencrypted = bss->capability &
- cpu_to_le16(WLAN_CAPABILITY_PRIVACY) ? 1 : 0;
+ WLAN_CAPABILITY_PRIVACY ? 1 : 0;
memset(&rq, 0, sizeof(rq));
rq.m = bss->freq * 100000;
@@ -2153,9 +2153,9 @@
bss->channel = local->conf.channel;
bss->freq = local->conf.freq;
bss->last_update = jiffies;
- bss->capability = cpu_to_le16(WLAN_CAPABILITY_IBSS);
+ bss->capability = WLAN_CAPABILITY_IBSS;
if (sdata->default_key) {
- bss->capability |= cpu_to_le16(WLAN_CAPABILITY_PRIVACY);
+ bss->capability |= WLAN_CAPABILITY_PRIVACY;
} else
sdata->drop_unencrypted = 0;
bss->supp_rates_len = local->num_curr_rates;
--
reply other threads:[~2006-11-12 18:15 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20061112181505.GB13434@devicescape.com \
--to=david.kimdon@devicescape$(echo .)com \
--cc=jbenc@suse$(echo .)cz \
--cc=linville@tuxdriver$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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