From: Andrew Lunn <andrew@lunn.ch>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Johannes Berg <johannes@sipsolutions.net>,
flamingice@sourmilk.net, linux-wireless@vger.kernel.org,
linville@tuxdriver.com
Subject: Re: [PATCH] try 2: mac80211: Fix swapped parameters to ieee80211_set_channel()
Date: Thu, 13 Dec 2007 13:37:53 +0100 [thread overview]
Message-ID: <20071213123753.GC501@lunn.ch> (raw)
In-Reply-To: <20071213120904.GB501@lunn.ch>
On Thu, Dec 13, 2007 at 01:09:04PM +0100, Andrew Lunn wrote:
> On Thu, Dec 13, 2007 at 01:16:14AM +0100, Johannes Berg wrote:
> > > Acked-by: Johannes Berg <johannes@sipsolutions.net>
> >
> > Actually, I take that back.
> >
> > The code is correct, as per the comment above it. Stupid wext :/
> >
> > /* freq->e == 0: freq->m = channel; otherwise freq = m * 10^e */
> > if (freq->e == 0) {
> > if (freq->m < 0) {
> > if (sdata->type == IEEE80211_IF_TYPE_STA)
> > sdata->u.sta.flags |=
> > IEEE80211_STA_AUTO_CHANNEL_SEL;
> > return 0;
> > } else
> > return ieee80211_set_channel(local, freq->m, -1);
> >
>
> Probably a stupid question, but are you sure the comment is correct?
>
> I added a printk for freq->e and freq->m. When i do
>
> iwconfig wlan0 freq 5240
O.K. I'm stupid!
That command line should be
iwconfig wlan0 freq 5240M
Otherwise it tries to use 5240 HZ, which results in e == 0!
Maybe i should add a helpful hint to iwconfig. if setting the frequency
fails, and the frequency is < 2GHz, give the user a hit that maybe
they are missing postfix?
Patch withdraw, brain upgrade requested instead.
Andrew
prev parent reply other threads:[~2007-12-13 12:38 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-12 15:31 [PATCH] mac80211: Fix swapped parameters to ieee80211_set_channel() Andrew Lunn
2007-12-12 17:43 ` Johannes Berg
2007-12-12 18:02 ` [PATCH] try 2: " Andrew Lunn
2007-12-12 18:09 ` Johannes Berg
2007-12-13 0:16 ` Johannes Berg
2007-12-13 12:09 ` Andrew Lunn
2007-12-13 12:30 ` Johannes Berg
2007-12-13 12:50 ` Andrew Lunn
2007-12-13 12:53 ` Johannes Berg
2007-12-13 13:07 ` [PATCH] wirelesstools: More user space validation of channel/frequency Andrew Lunn
2007-12-13 12:37 ` Andrew Lunn [this message]
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=20071213123753.GC501@lunn.ch \
--to=andrew@lunn.ch \
--cc=flamingice@sourmilk.net \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.