* [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
@ 2007-07-10 18:41 Jean Tourrilhes
2007-07-10 19:25 ` Larry Finger
0 siblings, 1 reply; 7+ messages in thread
From: Jean Tourrilhes @ 2007-07-10 18:41 UTC (permalink / raw)
To: Larry Finger, Michael Buesch,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
Hi,
SoftMAC output the channel twice in the scan output. It should
display frequency and channel, but only once for each.
--------------------------------------------------------
Cell 02 - Address: A2:00:04:XX:XX:XX
ESSID:"TheESSID"
Protocol:IEEE 802.11b
Mode:Ad-Hoc
-> Channel:5
-> Frequency:2.432 GHz (Channel 5)
Encryption key:off
Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s
Quality=95/100 Signal level=-47 dBm Noise level=-65 dBm
Extra: Last beacon: 120ms ago
--------------------------------------------------------
The fix is simple, patch attached, tested for 2.6.22 with
bcm43xx. If you like it, send it to John.
Regards,
Jean
Signed-off-by: Jean Tourrilhes <jt-sDzT885Ts8HQT0dZR+AlfA@public.gmane.org>
-----------------------------------------------------------
--- linux/net/ieee80211/ieee80211_wx.j1.c 2007-07-10 11:28:55.000000000 -0700
+++ linux/net/ieee80211/ieee80211_wx.c 2007-07-10 11:31:18.000000000 -0700
@@ -90,14 +90,11 @@ static char *ieee80211_translate_scan(st
}
/* Add channel and frequency */
+ /* Note : userspace automatically computes channel using iwrange */
iwe.cmd = SIOCGIWFREQ;
- iwe.u.freq.m = network->channel;
- iwe.u.freq.e = 0;
- iwe.u.freq.i = 0;
- start = iwe_stream_add_event(start, stop, &iwe, IW_EV_FREQ_LEN);
-
iwe.u.freq.m = ieee80211_channel_to_freq(ieee, network->channel);
iwe.u.freq.e = 6;
+ iwe.u.freq.i = 0;
start = iwe_stream_add_event(start, stop, &iwe, IW_EV_FREQ_LEN);
/* Add encryption capability */
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
2007-07-10 18:41 [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan Jean Tourrilhes
@ 2007-07-10 19:25 ` Larry Finger
[not found] ` <4693DD18.1010905-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
0 siblings, 1 reply; 7+ messages in thread
From: Larry Finger @ 2007-07-10 19:25 UTC (permalink / raw)
To: jt; +Cc: Michael Buesch, linux-wireless, netdev
Jean,
Jean Tourrilhes wrote:
> Hi,
>
> SoftMAC output the channel twice in the scan output. It should
> display frequency and channel, but only once for each.
> --------------------------------------------------------
> Cell 02 - Address: A2:00:04:XX:XX:XX
> ESSID:"TheESSID"
> Protocol:IEEE 802.11b
> Mode:Ad-Hoc
> -> Channel:5
> -> Frequency:2.432 GHz (Channel 5)
The frequency output is needed by NetworkManager, which is why I added it. At that time, I thought
that some tool or other might be scanning the output looking for "Channel:", not "Channel ";
therefore I left both in. If we are sure that removing the channel-only line will not break
something, I'll be happy to send your patch upstream.
Larry
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
[not found] ` <4693DD18.1010905-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
@ 2007-07-10 19:47 ` Jean Tourrilhes
2007-07-12 3:30 ` Dan Williams
1 sibling, 0 replies; 7+ messages in thread
From: Jean Tourrilhes @ 2007-07-10 19:47 UTC (permalink / raw)
To: Larry Finger
Cc: Michael Buesch, linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
On Tue, Jul 10, 2007 at 02:25:12PM -0500, Larry Finger wrote:
> Jean,
>
> Jean Tourrilhes wrote:
> > Hi,
> >
> > SoftMAC output the channel twice in the scan output. It should
> >display frequency and channel, but only once for each.
> >--------------------------------------------------------
> > Cell 02 - Address: A2:00:04:XX:XX:XX
> > ESSID:"TheESSID"
> > Protocol:IEEE 802.11b
> > Mode:Ad-Hoc
> >-> Channel:5
> >-> Frequency:2.432 GHz (Channel 5)
>
> The frequency output is needed by NetworkManager, which is why I added it.
> At that time, I thought that some tool or other might be scanning the
> output looking for "Channel:", not "Channel "; therefore I left both in.
All of the other drivers display only a single line, and
SoftMAC is the odd one here. I think that have the info twice may
confuse some tools.
I know that there are scripts that parse iwlist output,
however I'm not keen on the practice, as there are alternatives.
> If we are sure that removing the channel-only line will not break
> something, I'll be happy to send your patch upstream.
Unfortunately, I can't guarantee that. I can only guarantee
that it will be similar to what other drivers do.
> Larry
Have fun...
Jean
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
[not found] ` <4693DD18.1010905-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
2007-07-10 19:47 ` Jean Tourrilhes
@ 2007-07-12 3:30 ` Dan Williams
[not found] ` <1184211018.9446.0.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
1 sibling, 1 reply; 7+ messages in thread
From: Dan Williams @ 2007-07-12 3:30 UTC (permalink / raw)
To: Larry Finger
Cc: jt-sDzT885Ts8HQT0dZR+AlfA, Michael Buesch,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
On Tue, 2007-07-10 at 14:25 -0500, Larry Finger wrote:
> Jean,
>
> Jean Tourrilhes wrote:
> > Hi,
> >
> > SoftMAC output the channel twice in the scan output. It should
> > display frequency and channel, but only once for each.
> > --------------------------------------------------------
> > Cell 02 - Address: A2:00:04:XX:XX:XX
> > ESSID:"TheESSID"
> > Protocol:IEEE 802.11b
> > Mode:Ad-Hoc
> > -> Channel:5
> > -> Frequency:2.432 GHz (Channel 5)
>
> The frequency output is needed by NetworkManager, which is why I added it. At that time, I thought
> that some tool or other might be scanning the output looking for "Channel:", not "Channel ";
> therefore I left both in. If we are sure that removing the channel-only line will not break
> something, I'll be happy to send your patch upstream.
Should fix NM, really, to deal with either channel or frequency and
handle each as appropriate.
Dan
> Larry
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
[not found] ` <1184211018.9446.0.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
@ 2007-07-12 16:34 ` Jean Tourrilhes
[not found] ` <20070712163440.GA13445-yAE0UhLNZJawPNPzzlOzwdBPR1lH4CV8@public.gmane.org>
0 siblings, 1 reply; 7+ messages in thread
From: Jean Tourrilhes @ 2007-07-12 16:34 UTC (permalink / raw)
To: Dan Williams
Cc: Larry Finger, Michael Buesch,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
On Wed, Jul 11, 2007 at 11:30:17PM -0400, Dan Williams wrote:
> On Tue, 2007-07-10 at 14:25 -0500, Larry Finger wrote:
> > Jean,
> >
> > Jean Tourrilhes wrote:
> > > Hi,
> > >
> > > SoftMAC output the channel twice in the scan output. It should
> > > display frequency and channel, but only once for each.
> > > --------------------------------------------------------
> > > Cell 02 - Address: A2:00:04:XX:XX:XX
> > > ESSID:"TheESSID"
> > > Protocol:IEEE 802.11b
> > > Mode:Ad-Hoc
> > > -> Channel:5
> > > -> Frequency:2.432 GHz (Channel 5)
> >
> > The frequency output is needed by NetworkManager, which is why I added it. At that time, I thought
> > that some tool or other might be scanning the output looking for "Channel:", not "Channel ";
> > therefore I left both in. If we are sure that removing the channel-only line will not break
> > something, I'll be happy to send your patch upstream.
>
> Should fix NM, really, to deal with either channel or frequency and
> handle each as appropriate.
>
> Dan
Well, I actually like forcing driver to use frequency, because
that's an absolute physical measure and contains more meaning.
Regards,
Jean
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
[not found] ` <20070712163440.GA13445-yAE0UhLNZJawPNPzzlOzwdBPR1lH4CV8@public.gmane.org>
@ 2007-07-12 16:40 ` Larry Finger
[not found] ` <46965977.7020807-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
0 siblings, 1 reply; 7+ messages in thread
From: Larry Finger @ 2007-07-12 16:40 UTC (permalink / raw)
To: jt-sDzT885Ts8HQT0dZR+AlfA
Cc: Dan Williams, Michael Buesch,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
Jean Tourrilhes wrote:
>
> Well, I actually like forcing driver to use frequency, because
> that's an absolute physical measure and contains more meaning.
Yes, but it is easier to keep a channel number in your head than a frequency.
Larry
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan
[not found] ` <46965977.7020807-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
@ 2007-07-12 16:49 ` Jean Tourrilhes
0 siblings, 0 replies; 7+ messages in thread
From: Jean Tourrilhes @ 2007-07-12 16:49 UTC (permalink / raw)
To: Larry Finger
Cc: Dan Williams, Michael Buesch,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA
On Thu, Jul 12, 2007 at 11:40:23AM -0500, Larry Finger wrote:
> Jean Tourrilhes wrote:
> >
> > Well, I actually like forcing driver to use frequency, because
> >that's an absolute physical measure and contains more meaning.
>
> Yes, but it is easier to keep a channel number in your head than a
> frequency.
That's why iwlist display both in 'iwlist freq' and 'iwlist scan'.
> Larry
Jean
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2007-07-12 16:49 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-10 18:41 [PATCH 2.6] SoftMAC : fix duplicate display of channel in scan Jean Tourrilhes
2007-07-10 19:25 ` Larry Finger
[not found] ` <4693DD18.1010905-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
2007-07-10 19:47 ` Jean Tourrilhes
2007-07-12 3:30 ` Dan Williams
[not found] ` <1184211018.9446.0.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2007-07-12 16:34 ` Jean Tourrilhes
[not found] ` <20070712163440.GA13445-yAE0UhLNZJawPNPzzlOzwdBPR1lH4CV8@public.gmane.org>
2007-07-12 16:40 ` Larry Finger
[not found] ` <46965977.7020807-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
2007-07-12 16:49 ` Jean Tourrilhes
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).