Linux wireless drivers development
 help / color / mirror / Atom feed
* Re: [PATCH 1/9] [compat-2.6 and compat-stable] Export round_jiffies_up again.
From: Luis R. Rodriguez @ 2009-10-13 20:07 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: linux-wireless, larry.finger, Greg KH
In-Reply-To: <43e72e890910131239x60c3f8d7j784dcf2a3cd9de51@mail.gmail.com>

On Tue, Oct 13, 2009 at 12:39 PM, Luis R. Rodriguez
<lrodriguez@atheros.com> wrote:

> because otherwise then we have here the define so existing
> wireless-testing code maps to the backport_round_jiffies_up(), and the
> declaration of round_jiffies_up() also gets preprocessed as
> backport_round_jiffies_up() -- the only thing missing would be the
> compat exported symbol but I saw that didn't change.

Come to think of it -- because of the define you added the
compat-2.6.28 code *will* rename the code to add the backport_ prefix
so that is why this compiles. I'll leave it like that. Thanks.

  Luis

^ permalink raw reply

* Re: Current status of rt2800usb and staging/rt2870
From: Ivo van Doorn @ 2009-10-13 20:00 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz
  Cc: Ozan Çağlayan, linux-wireless, linux-kernel
In-Reply-To: <200910132121.25743.bzolnier@gmail.com>

> > The rt2800pci and rt2800usb drivers cover support for rt2860/rt2870/rt3070 devices,
> > which are present as individual drivers in the staging tree. So far it only managed
> 
> There are no longer individual drivers.
> 
> Instead there is one shared source code and two device drivers:
> 
> - rt2860 covering RT2860 and RT3090 devices
> 
> - rt2870 covering RT2870 and RT3070 devices

Cool, now you only need somebody to update those drivers to mac80211,
and you can merge those drivers to the main drivers/net/wireless/ folder.

Can't be more happy with this progress, since that means I can finally abandon
rt2800pci and rt2800usb which have been nothing more then a pain.

Ivo

P.S.
It is up to you to decide if this mail was intented as serious, sarcastic or pointless ranting.

^ permalink raw reply

* Re: [PATCH 6/9] [compat-2.6] Fix build with kernel < 2.6.27
From: Luis R. Rodriguez @ 2009-10-13 19:56 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: linux-wireless
In-Reply-To: <1255382358-20760-8-git-send-email-hauke@hauke-m.de>

On Mon, Oct 12, 2009 at 2:19 PM, Hauke Mehrtens <hauke@hauke-m.de> wrote:
> iw_handler.h have changed in kernel 2.6.27.
> For older kernel we need some extra backport code.
>
> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
> ---
>  compat/compat-2.6.27.h |   20 ++++++++++++++++++++
>  1 files changed, 20 insertions(+), 0 deletions(-)
>
> diff --git a/compat/compat-2.6.27.h b/compat/compat-2.6.27.h
> index 2543482..8cc6c22 100644
> --- a/compat/compat-2.6.27.h
> +++ b/compat/compat-2.6.27.h
> @@ -163,6 +163,26 @@ static inline void list_splice_tail_init(struct list_head *list,
>  extern unsigned int mmc_align_data_size(struct mmc_card *, unsigned int);
>  extern unsigned int sdio_align_size(struct sdio_func *func, unsigned int sz);
>
> +/** Include iw_handler.h before we redefine some methods **/
> +#include <net/iw_handler.h>
> +
> +#define iwe_stream_add_value(info, event, value, ends, iwe, event_len) iwe_stream_add_value(event, value, ends, iwe, event_len)
> +#define iwe_stream_add_point(info, stream, ends, iwe, extra) iwe_stream_add_point(stream, ends, iwe, extra)
> +#define iwe_stream_add_event(info, stream, ends, iwe, event_len) iwe_stream_add_event(stream, ends, iwe, event_len)
> +
> +/* Flags available in struct iw_request_info */
> +#define IW_REQUEST_FLAG_COMPAT 0x0001  /* Compat ioctl call */
> +
> +static inline int iwe_stream_lcp_len(struct iw_request_info *info)
> +{
> +#ifdef CONFIG_COMPAT
> +       if (info->flags & IW_REQUEST_FLAG_COMPAT)
> +               return IW_EV_COMPAT_LCP_LEN;
> +#endif
> +       return IW_EV_LCP_LEN;
> +}
> +/** source: include/net/iw_handler.h **/
> +
>  #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27)) */
>
>  #endif /* LINUX_26_27_COMPAT_H */

I guess for older releases where we copied over the iw_handler.h we
were then sending the kernel the wrong data for these callers. We
could just try to propagate the iw_handler changes to
compat-wireless-stable. This would probably fix a few unreported
issues.

  Luis

^ permalink raw reply

* Re: 2.6.31.[12] ath5k regression
From: Richard Zidlicky @ 2009-10-13 19:37 UTC (permalink / raw)
  To: Bob Copeland; +Cc: linux-wireless
In-Reply-To: <20091012235438.GA24539@hash.localnet>

On Mon, Oct 12, 2009 at 07:54:38PM -0400, Bob Copeland wrote:
> On Mon, Oct 12, 2009 at 10:23:16PM +0200, Richard Zidlicky wrote:
> > it works like in mainline and fails.
> 
> Huh, well it should be equivalent to your patch, so I'm stumped
> as to why.

mee too. I am trying to verify all variants because I do remember that adding the 
change_chan patch on top of clean 2.6.31 broke that while I do vaguely remember that
reverting this patch form 2.6.31.[23] did not make a working wlan.
However testing is time consuming - the machine requires allways a complete shutdown, 
power off reboot.

Strange things were happening even in 2.6.31 - for example my ad-hoc network was listed 
twice by iwlist scan - strangely one of the entries has 0db signal strength. Similar
listing on both ends.

Here is what the other end is reporting if that is of any help..

### ath5k end shut down here ###
[52262.000044] wlan0: expiring inactive STA 00:22:43:2c:76:0f
[52262.000050] phy6: Removed STA 00:22:43:2c:76:0f
[52262.003025] phy6: Destroyed STA 00:22:43:2c:76:0f
[52343.404540] wlan0: RX ProbeReq SA=00:60:b3:06:f4:17 DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[52345.711165] wlan0: RX ProbeReq SA=00:60:b3:06:f4:17 DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
...
...
...
...
[52350.930907] wlan0: RX ProbeReq SA=00:60:b3:06:f4:17 DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[52881.645705] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[52881.645711] wlan0: Sending ProbeResp to 00:22:43:2c:76:0f
[52883.886696] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[52883.886702] wlan0: Sending ProbeResp to 00:22:43:2c:76:0f
[52915.330070] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[52947.327315] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53011.323892] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53106.964036] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53138.613029] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53266.603257] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53298.604621] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53330.599864] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53362.598110] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53382.140098] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)
[53382.140104] wlan0: Sending ProbeResp to 00:22:43:2c:76:0f
[53413.898474] wlan0: RX ProbeReq SA=00:22:43:2c:76:0f DA=ff:ff:ff:ff:ff:ff BSSID=ff:ff:ff:ff:ff:ff (tx_last_beacon=1)

Richard

^ permalink raw reply

* Re: [PATCH 1/9] [compat-2.6 and compat-stable] Export round_jiffies_up again.
From: Luis R. Rodriguez @ 2009-10-13 19:39 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: linux-wireless, larry.finger, Greg KH
In-Reply-To: <1255382358-20760-2-git-send-email-hauke@hauke-m.de>

On Mon, Oct 12, 2009 at 2:19 PM, Hauke Mehrtens <hauke@hauke-m.de> wrote:
> The 2.6.27 mainline kernel does not export round_jiffies_up. It looks
> like the openSuse kernel 2.6.27 does export this symbol. Rename the
> compat symbol to not conflict with the openSuse kernel.
>
> CC: larry.finger@gmail.com
> Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
> ---
>  compat/compat-2.6.28.c |    2 --
>  compat/compat-2.6.28.h |    5 +++++
>  2 files changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/compat/compat-2.6.28.c b/compat/compat-2.6.28.c
> index 613b009..33871a2 100644
> --- a/compat/compat-2.6.28.c
> +++ b/compat/compat-2.6.28.c
> @@ -260,7 +260,6 @@ static unsigned long round_jiffies_common(unsigned long j, int cpu,
>        return j;
>  }
>
> -#if 0
>  /**
>  * round_jiffies_up - function to round jiffies up to a full second
>  * @j: the time in (absolute) jiffies that should be rounded
> @@ -275,6 +274,5 @@ unsigned long round_jiffies_up(unsigned long j)
>        return round_jiffies_common(j, raw_smp_processor_id(), true);
>  }
>  EXPORT_SYMBOL_GPL(round_jiffies_up);
> -#endif

Did you then mean to rename the above to backport_round_jiffies_up then?

>  #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(2,6,28) */
> diff --git a/compat/compat-2.6.28.h b/compat/compat-2.6.28.h
> index 4e5a2ef..90d080c 100644
> --- a/compat/compat-2.6.28.h
> +++ b/compat/compat-2.6.28.h
> @@ -195,6 +195,11 @@ static inline void tracepoint_update_probe_range(struct tracepoint *begin,
>
>  #endif
>
> +/* openSuse includes round_jiffies_up in it's kernel 2.6.27.
> + * This is needed to prevent conflicts with the openSuse definition.
> + */
> +#define round_jiffies_up backport_round_jiffies_up
> +
>  unsigned long round_jiffies_up(unsigned long j);
>
>  #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,28)) */

because otherwise then we have here the define so existing
wireless-testing code maps to the backport_round_jiffies_up(), and the
declaration of round_jiffies_up() also gets preprocessed as
backport_round_jiffies_up() -- the only thing missing would be the
compat exported symbol but I saw that didn't change.

  Luis

^ permalink raw reply

* Re: ar9170 network interface initialization failure
From: Luis R. Rodriguez @ 2009-10-13 19:25 UTC (permalink / raw)
  To: oshi; +Cc: linux-wireless, Christian Lamparter
In-Reply-To: <loom.20091012T120512-386@post.gmane.org>

On Mon, Oct 12, 2009 at 3:05 AM, oshi <oshi@trego.co.il> wrote:
> Hello,
>
> I am trying to enable a Ubiquity SR71 device on x86 - ubuntu 9.04 (kernel
> headers 2.6.28-15).
>
> I built and installed compat-wireless-2009-10-09 on my machine.
> ar9170 module is loaded and a network interface is created.
>
> However when I try to bring up the interface, an error occurs:
>
> ifconfig wlan3 up
> SIOCSIFFLAGS: Operation not permitted
>
> I managed to trace down the error to  a failure in usb_submit_urb() called from
> ar9170_init_mac().
>
>
> [70247.612064] usb 2-1: new high speed USB device using ehci_hcd and address 10
> [70247.779863] usb 2-1: config 1 interface 0 altsetting 0 bulk endpoint 0x4 has
> invalid maxpacket 64
> [70247.792411] usb 2-1: configuration #1 chosen from 1 choice
> [70247.910900] usb 2-1: reset high speed USB device using ehci_hcd and address 10
> [70249.084059] usb 2-1: firmware: requesting ar9170.fw
> [70249.096406] usb 2-1: ar9170.fw firmware file not found, trying old firmware...
> [70249.096416] usb 2-1: firmware: requesting ar9170-1.fw
> [70249.138585] usb 2-1: firmware: requesting ar9170-2.fw
> [70249.568392] ath: EEPROM regdomain: 0x0
> [70249.568397] ath: EEPROM indicates default country code should be used
> [70249.568402] ath: doing EEPROM country->regdmn map search
> [70249.568408] ath: country maps to regdmn code: 0x3a
> [70249.568413] ath: Country alpha2 being used: US
> [70249.568418] ath: Regpair used: 0x3a
> [70249.568792] phy2: Selected rate control algorithm 'minstrel'
> [70249.572212] ar9170_usb_exec_cmd line 399
> [70249.572488] ar9170_usb_exec_cmd line 399
> [70249.572820] Registered led device: ar9170-phy2::tx
> [70249.572883] Registered led device: ar9170-phy2::assoc
> [70249.572890] usb 2-1: Atheros AR9170 is registered as 'phy2'
> [70249.588769] udev: renamed network interface wlan0 to wlan3
> [70254.388224] ar9170_op_start 1259
> [70254.388231] ar9170_init_mac 147
> [70254.388257] ar9170_usb_exec_cmd usb_submit_urb err -1

Hm, when usb_submit_urb err() fails on  ar9170_usb_exec_cmd() I
believe you should get a dump stack and all, not sure why you are only
getting this.

But the more important question is how you managed to compile
compat-wireless for ar9170 on a 2.6.28 kernel, we enable it on
compat-wireless only for kernels >= 2.6.29. Here is the config.mk
excerpt:

ifndef CONFIG_COMPAT_WIRELESS_28
CONFIG_AR9170_USB=m
CONFIG_AR9170_LEDS=y
endif

That is -- if you don't need 2.6.28 compat stuff enable ar9170. Also
2.6.28 does not have CONFIG_AR9170_USB.. hmm. How did you compile
this?

  Luis

^ permalink raw reply

* Re: Current status of rt2800usb and staging/rt2870
From: Bartlomiej Zolnierkiewicz @ 2009-10-13 19:21 UTC (permalink / raw)
  To: Ivo van Doorn; +Cc: Ozan Çağlayan, linux-wireless, linux-kernel
In-Reply-To: <200910132017.47748.IvDoorn@gmail.com>

On Tuesday 13 October 2009 20:17:47 Ivo van Doorn wrote:
> On Tuesday 13 October 2009, Bartlomiej Zolnierkiewicz wrote:
> > On Tuesday 13 October 2009 17:52:52 Ivo van Doorn wrote:
> > 
> > > I am going to merge rt2800pci soon as well and after that I'll send a patch
> > 
> > Great, I've been waiting for this for a long time.
> > 
> > > to remove all Ralink drivers from the staging tree.
> > 
> > Till new drivers obtain support for all hardware currently covered by
> > the unified staging drivers the latter shouldn't be removed as they
> > serve well their role as a temporary solution allowing real Linux users
> > to user their real hardware and as a reference material for developers
> > willing to work on adding the missing bits to new drivers.
> 
> The rt2800pci and rt2800usb drivers cover support for rt2860/rt2870/rt3070 devices,
> which are present as individual drivers in the staging tree. So far it only managed

There are no longer individual drivers.

Instead there is one shared source code and two device drivers:

- rt2860 covering RT2860 and RT3090 devices

- rt2870 covering RT2870 and RT3070 devices

In comparison rt2800usb currently lacks RT3070 support and rt2800pci's
RT3090 support is basic at best (not to mention that it didn't work for
RT2860 last time that I tried)..

> to confuse developers which wanted to work on Ralink support, so I haven't found

I bet they are truly grateful for being shown "the one and only way"..

> a benefit for having those drivers in the staging tree yet. But I am sure there are plenty

I was able to use my Eee 901 successfully with them for a last year and I'm
pretty sure that I'm not the only.  I understand my sin now -- I should have
had help in fixing the proper and clean code before using my hardware.. [*]

> of people who like the idea of having the original Ralink drivers inside the staging tree,
> so they can continue debugging that, so I won't talk about the staging downsides further.

Well, it would be much more productive if people concentrate on improving
_their_ projects and looking at downsides of _their_ code instead of going
around and looking at _obvious_ downsides of other people's projects.


[*] [Slightly off-topic but it shows the same problem with the approach]

I now also see why some distributions keep pushing some known non-working
things on their users (Fedora maintainers -- I'm talking to you), the best
example is PulseAudio -- it simply doesn't work reliably even on modern
hardware and/or using all scheduler tricks (it seems that making Linux into
full RT OS is a prerequisite for fixing latency issues observed)..

So yeah desktop/laptop/mobile users, do not worry -- you will get your sound
support back in few years time and if you're developer: don't dare to complain
you fussy saboteur!!

^ permalink raw reply

* Re: [PATCH] crda: Cosmetic fix for udev path
From: Luis R. Rodriguez @ 2009-10-13 18:55 UTC (permalink / raw)
  To: tim.gardner; +Cc: linux-wireless@vger.kernel.org
In-Reply-To: <4AD34515.5080008@canonical.com>

On Mon, Oct 12, 2009 at 8:02 AM, Tim Gardner <tim.gardner@canonical.com> wrote:
> Luis,
>
> This patch is against
> git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/crda.git. It fixes
> some complaints about an extra '/'.

Applied, thanks.

  Luis

^ permalink raw reply

* Re: pull request: wireless-2.6 2009-10-13
From: David Miller @ 2009-10-13 18:42 UTC (permalink / raw)
  To: linville; +Cc: linux-wireless, netdev, linux-kernel
In-Reply-To: <20091013150558.GC2747@tuxdriver.com>

From: "John W. Linville" <linville@tuxdriver.com>
Date: Tue, 13 Oct 2009 11:05:58 -0400

> Here are a few (almost-)one-liners for 2.6.32.  Included are fixes for
> a use-after-free, a missing "!" in front of a memcmp when comparing
> BSSIDs, a race when using hardware-based scanning, the ieee80211_rx
> context problem, a related documentation change, and a minor build
> issue.
> 
> Please let me know if there are problems!

Pulled, thanks a lot!

^ permalink raw reply

* Re: Current status of rt2800usb and staging/rt2870
From: Ivo van Doorn @ 2009-10-13 18:17 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz
  Cc: Ozan Çağlayan, linux-wireless, linux-kernel
In-Reply-To: <200910131927.24136.bzolnier@gmail.com>

On Tuesday 13 October 2009, Bartlomiej Zolnierkiewicz wrote:
> On Tuesday 13 October 2009 17:52:52 Ivo van Doorn wrote:
> 
> > I am going to merge rt2800pci soon as well and after that I'll send a patch
> 
> Great, I've been waiting for this for a long time.
> 
> > to remove all Ralink drivers from the staging tree.
> 
> Till new drivers obtain support for all hardware currently covered by
> the unified staging drivers the latter shouldn't be removed as they
> serve well their role as a temporary solution allowing real Linux users
> to user their real hardware and as a reference material for developers
> willing to work on adding the missing bits to new drivers.

The rt2800pci and rt2800usb drivers cover support for rt2860/rt2870/rt3070 devices,
which are present as individual drivers in the staging tree. So far it only managed
to confuse developers which wanted to work on Ralink support, so I haven't found
a benefit for having those drivers in the staging tree yet. But I am sure there are plenty
of people who like the idea of having the original Ralink drivers inside the staging tree,
so they can continue debugging that, so I won't talk about the staging downsides further.
Ivo

^ permalink raw reply

* Re: [PATCH] rx51: add wl1251 wlan driver support
From: Kalle Valo @ 2009-10-13 18:16 UTC (permalink / raw)
  To: linux-omap; +Cc: linux-wireless
In-Reply-To: <20091013165812.1623.66247.stgit@tikku>

Kalle Valo <kalle.valo@iki.fi> writes:

> From: Kalle Valo <kalle.valo@nokia.com>
>
> wl1251 is connected to the SPI bus in rx51, add support for this.
>
> Signed-off-by: Kalle Valo <kalle.valo@nokia.com>

This is intended for 2.6.33. Also to really work it needs this patch:

wl1251: rename spi device to wl1251
http://www.spinics.net/lists/linux-wireless/msg40740.html

The patch should be in wireless-testing within next few days and
finally it will go to 2.6.33.

(Please note that the two patches have no compile time dependency so
they can go to mainline via separate trees.)

-- 
Kalle Valo

^ permalink raw reply

* Re: Moving drivers into staging (was Re: [GIT PULL] SCSI fixes for 2.6.32-rc3)
From: Luis R. Rodriguez @ 2009-10-13 18:08 UTC (permalink / raw)
  To: Greg KH
  Cc: Ingo Molnar, James Bottomley, Linus Torvalds, Theodore Tso,
	Andrew Morton, linux-scsi, linux-kernel, Jing Huang, netdev,
	linux-wireless
In-Reply-To: <20091012232429.GA24254@suse.de>

On Mon, Oct 12, 2009 at 4:24 PM, Greg KH <gregkh@suse.de> wrote:
> On Mon, Oct 12, 2009 at 05:42:44PM +0200, Ingo Molnar wrote:
>> Hm, i think i even gave drivers/staging/ its name?
>
> Yes you did, and I appreciate it :)
>
>> > [...] It seems that I'm the only one that has the ability to drop
>> > drivers out of the kernel tree, which is a funny situation :)
>>
>> You are the only one who has the ability to send a warning shot towards
>> drivers _without hurting users_, and by moving it into the focus of a
>> team of cleanup oriented developers.
>>
>> I think that's an important distinction ;-)
>
> Good point.
>
>> > In thinking about this a lot more, I don't really mind it.  If people
>> > want to push stuff out of "real" places in the kernel, into
>> > drivers/staging/ and give the original authors and maintainers notice
>> > about what is going on, _and_ provide a TODO file for what needs to
>> > happen to get the code back into the main portion of the kernel tree,
>> > then I'll be happy to help out with this and manage it.
>> >
>> > I think a 6-9 month window (basically 3 kernel releases) should be
>> > sufficient time to have a driver that has been in drivers/staging/ be
>> > cleaned up enough to move back into the main kernel tree.  If not, it
>> > could be easily dropped.
>> >
>> > Any objections to this?
>>
>> Sounds excellent to me!
>
> Great, I'll await the patches to move stuff to drivers/staging/ now.
>
> Wireless developers, warm up your editors :)

OK -- prism54 seems like a good candidate, instead of removing it
completely as I originally outlined on the feature removal schedule.
Do we have a file to give notices to move drivers to staging because
they are old as with the feature removal schedule? The more visible
these things become the better it is for users.

  Luis

^ permalink raw reply

* [PATCH] wl1251: rename spi device to wl1251
From: Kalle Valo @ 2009-10-13 17:41 UTC (permalink / raw)
  To: linville; +Cc: linux-wireless

From: Kalle Valo <kalle.valo@nokia.com>

During rename of the driver from wl12xx to wl1251 the spi device name
was accidentally left as wl12xx. Rename it to wl1251 which is the proper
name of the driver.

Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
---

 drivers/net/wireless/wl12xx/wl1251_main.c |    2 +-
 drivers/net/wireless/wl12xx/wl1251_spi.c  |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c
index 1103256..23ac503 100644
--- a/drivers/net/wireless/wl12xx/wl1251_main.c
+++ b/drivers/net/wireless/wl12xx/wl1251_main.c
@@ -1426,4 +1426,4 @@ EXPORT_SYMBOL_GPL(wl1251_free_hw);
 MODULE_DESCRIPTION("TI wl1251 Wireles LAN Driver Core");
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Kalle Valo <kalle.valo@nokia.com>");
-MODULE_ALIAS("spi:wl12xx");
+MODULE_ALIAS("spi:wl1251");
diff --git a/drivers/net/wireless/wl12xx/wl1251_spi.c b/drivers/net/wireless/wl12xx/wl1251_spi.c
index 14eff2b..2cf8a21 100644
--- a/drivers/net/wireless/wl12xx/wl1251_spi.c
+++ b/drivers/net/wireless/wl12xx/wl1251_spi.c
@@ -307,7 +307,7 @@ static int __devexit wl1251_spi_remove(struct spi_device *spi)
 
 static struct spi_driver wl1251_spi_driver = {
 	.driver = {
-		.name		= "wl12xx",
+		.name		= "wl1251",
 		.bus		= &spi_bus_type,
 		.owner		= THIS_MODULE,
 	},


^ permalink raw reply related

* event tracing for mac80211
From: X Xiao @ 2009-10-13 17:33 UTC (permalink / raw)
  To: linux-wireless
In-Reply-To: <1255427279-1224-22-git-send-email-luciano.coelho@nokia.com>

I'm using compat-wireless 2009-10-09 with 2.6.30, is event tracing for mac80211(CONFIG_MAC80211_DRIVER_API_TRACER) working yet? I tried to use it with no success.

thanks!
xxiao

^ permalink raw reply

* [PATCH 1/2] mac80211: add ieee80211_rx_ni()
From: Kalle Valo @ 2009-10-13 17:33 UTC (permalink / raw)
  To: linville; +Cc: johannes, linux-wireless

From: Kalle Valo <kalle.valo@nokia.com>

ieee80211_rx() must be called with bottom halves disabled. To simplify
driver development implement ieee80211_rx_ni() which disables BH. This
function must be used when in process context.

Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
---

 include/net/mac80211.h |   32 ++++++++++++++++++++++++++------
 1 files changed, 26 insertions(+), 6 deletions(-)

diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index c75b960..c42c4a8 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1665,11 +1665,11 @@ void ieee80211_restart_hw(struct ieee80211_hw *hw);
  * header if %RX_FLAG_RADIOTAP is set in the @status flags.
  *
  * This function may not be called in IRQ context. Calls to this function
- * for a single hardware must be synchronized against each other. Calls
- * to this function and ieee80211_rx_irqsafe() may not be mixed for a
- * single hardware.
+ * for a single hardware must be synchronized against each other. Calls to
+ * this function, ieee80211_rx_ni() and ieee80211_rx_irqsafe() may not be
+ * mixed for a single hardware.
  *
- * Note that right now, this function must be called with softirqs disabled.
+ * In process context use instead ieee80211_rx_ni().
  *
  * @hw: the hardware this frame came in on
  * @skb: the buffer to receive, owned by mac80211 after this call
@@ -1682,8 +1682,8 @@ void ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb);
  * Like ieee80211_rx() but can be called in IRQ context
  * (internally defers to a tasklet.)
  *
- * Calls to this function and ieee80211_rx() may not be mixed for a
- * single hardware.
+ * Calls to this function, ieee80211_rx() or ieee80211_rx_ni() may not
+ * be mixed for a single hardware.
  *
  * @hw: the hardware this frame came in on
  * @skb: the buffer to receive, owned by mac80211 after this call
@@ -1691,6 +1691,26 @@ void ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb);
 void ieee80211_rx_irqsafe(struct ieee80211_hw *hw, struct sk_buff *skb);
 
 /**
+ * ieee80211_rx_ni - receive frame (in process context)
+ *
+ * Like ieee80211_rx() but can be called in process context
+ * (internally disables bottom halves).
+ *
+ * Calls to this function, ieee80211_rx() and ieee80211_rx_irqsafe() may
+ * not be mixed for a single hardware.
+ *
+ * @hw: the hardware this frame came in on
+ * @skb: the buffer to receive, owned by mac80211 after this call
+ */
+static inline void ieee80211_rx_ni(struct ieee80211_hw *hw,
+				   struct sk_buff *skb)
+{
+	local_bh_disable();
+	ieee80211_rx(hw, skb);
+	local_bh_enable();
+}
+
+/**
  * ieee80211_tx_status - transmit status callback
  *
  * Call this function for all transmitted frames after they have been


^ permalink raw reply related

* [PATCH 2/2] wl1251: use ieee80211_rx_ni()
From: Kalle Valo @ 2009-10-13 17:33 UTC (permalink / raw)
  To: linville; +Cc: johannes, linux-wireless
In-Reply-To: <20091013173313.13021.80289.stgit@tikku>

From: Kalle Valo <kalle.valo@nokia.com>

Because of SPI and SDIO wl1251 does everything in a workqueue, including
calling ieee80211_rx() which should be called with bottom halves disabled.
An error message is emitted because of this:

NOHZ: local_softirq_pending 08

Fix this by using ieee80211_rx_ni().

Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
---

 drivers/net/wireless/wl12xx/wl1251_rx.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/wl12xx/wl1251_rx.c b/drivers/net/wireless/wl12xx/wl1251_rx.c
index 17c54b5..601fe0d 100644
--- a/drivers/net/wireless/wl12xx/wl1251_rx.c
+++ b/drivers/net/wireless/wl12xx/wl1251_rx.c
@@ -153,7 +153,7 @@ static void wl1251_rx_body(struct wl1251 *wl,
 		     beacon ? "beacon" : "");
 
 	memcpy(IEEE80211_SKB_RXCB(skb), &status, sizeof(status));
-	ieee80211_rx(wl->hw, skb);
+	ieee80211_rx_ni(wl->hw, skb);
 }
 
 static void wl1251_rx_ack(struct wl1251 *wl)


^ permalink raw reply related

* Re: Current status of rt2800usb and staging/rt2870
From: Bartlomiej Zolnierkiewicz @ 2009-10-13 17:27 UTC (permalink / raw)
  To: Ivo van Doorn; +Cc: Ozan Çağlayan, linux-wireless, linux-kernel
In-Reply-To: <200910131752.52589.IvDoorn@gmail.com>

On Tuesday 13 October 2009 17:52:52 Ivo van Doorn wrote:

> I am going to merge rt2800pci soon as well and after that I'll send a patch

Great, I've been waiting for this for a long time.

> to remove all Ralink drivers from the staging tree.

Till new drivers obtain support for all hardware currently covered by
the unified staging drivers the latter shouldn't be removed as they
serve well their role as a temporary solution allowing real Linux users
to user their real hardware and as a reference material for developers
willing to work on adding the missing bits to new drivers.

Best regards,
Bartlomiej

^ permalink raw reply

* Re: [PATCH] libertas: Check return status of command functions
From: Dan Williams @ 2009-10-13 17:26 UTC (permalink / raw)
  To: Bing Zhao; +Cc: libertas-dev, linux-wireless, Amitkumar Karwar
In-Reply-To: <1255055925-2013-1-git-send-email-bzhao@marvell.com>

On Thu, 2009-10-08 at 19:38 -0700, Bing Zhao wrote:
> From: Amitkumar Karwar <akarwar@marvell.com>
> 
> Return status of lbs_prepare_and_send_command and lbs_cmd_with_response
> functions is not checked at some places. Those checks are added.

Some of those look OK, but others didn't check the return value because
it wasn't a big deal if the calls failed.  For example, updating the
RSSI in get_wireless_stats.  I don't really have a strong feeling either
way.

Acked-by: Dan Williams <dcbw@redhat.com>

> Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
> Signed-off-by: Bing Zhao <bzhao@marvell.com>
> ---
>  drivers/net/wireless/libertas/debugfs.c |   27 ++++++++++++++++++---------
>  drivers/net/wireless/libertas/main.c    |    2 ++
>  drivers/net/wireless/libertas/scan.c    |   11 +++++++----
>  drivers/net/wireless/libertas/wext.c    |   10 +++++++---
>  4 files changed, 34 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/net/wireless/libertas/debugfs.c b/drivers/net/wireless/libertas/debugfs.c
> index 893a55c..587b0cb 100644
> --- a/drivers/net/wireless/libertas/debugfs.c
> +++ b/drivers/net/wireless/libertas/debugfs.c
> @@ -451,10 +451,12 @@ static ssize_t lbs_rdmac_read(struct file *file, char __user *userbuf,
>  				CMD_MAC_REG_ACCESS, 0,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
> -	pos += snprintf(buf+pos, len-pos, "MAC[0x%x] = 0x%08x\n",
> +	if (!ret) {
> +		pos += snprintf(buf+pos, len-pos, "MAC[0x%x] = 0x%08x\n",
>  				priv->mac_offset, priv->offsetvalue.value);
>  
> -	ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +		ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +	}
>  	free_page(addr);
>  	return ret;
>  }
> @@ -514,7 +516,8 @@ static ssize_t lbs_wrmac_write(struct file *file,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
>  
> -	res = count;
> +	if (!res)
> +		res = count;
>  out_unlock:
>  	free_page(addr);
>  	return res;
> @@ -539,10 +542,12 @@ static ssize_t lbs_rdbbp_read(struct file *file, char __user *userbuf,
>  				CMD_BBP_REG_ACCESS, 0,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
> -	pos += snprintf(buf+pos, len-pos, "BBP[0x%x] = 0x%08x\n",
> +	if (!ret) {
> +		pos += snprintf(buf+pos, len-pos, "BBP[0x%x] = 0x%08x\n",
>  				priv->bbp_offset, priv->offsetvalue.value);
>  
> -	ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +		ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +	}
>  	free_page(addr);
>  
>  	return ret;
> @@ -603,7 +608,8 @@ static ssize_t lbs_wrbbp_write(struct file *file,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
>  
> -	res = count;
> +	if (!res)
> +		res = count;
>  out_unlock:
>  	free_page(addr);
>  	return res;
> @@ -628,10 +634,12 @@ static ssize_t lbs_rdrf_read(struct file *file, char __user *userbuf,
>  				CMD_RF_REG_ACCESS, 0,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
> -	pos += snprintf(buf+pos, len-pos, "RF[0x%x] = 0x%08x\n",
> +	if (!ret) {
> +		pos += snprintf(buf+pos, len-pos, "RF[0x%x] = 0x%08x\n",
>  				priv->rf_offset, priv->offsetvalue.value);
>  
> -	ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +		ret = simple_read_from_buffer(userbuf, count, ppos, buf, pos);
> +	}
>  	free_page(addr);
>  
>  	return ret;
> @@ -692,7 +700,8 @@ static ssize_t lbs_wrrf_write(struct file *file,
>  				CMD_OPTION_WAITFORRSP, 0, &offval);
>  	mdelay(10);
>  
> -	res = count;
> +	if (!res)
> +		res = count;
>  out_unlock:
>  	free_page(addr);
>  	return res;
> diff --git a/drivers/net/wireless/libertas/main.c b/drivers/net/wireless/libertas/main.c
> index 3b14fcc..bce752c 100644
> --- a/drivers/net/wireless/libertas/main.c
> +++ b/drivers/net/wireless/libertas/main.c
> @@ -1087,6 +1087,8 @@ static void auto_deepsleep_timer_fn(unsigned long data)
>  			ret = lbs_prepare_and_send_command(priv,
>  					CMD_802_11_DEEP_SLEEP, 0,
>  					0, 0, NULL);
> +			if (ret)
> +				lbs_pr_err("Enter Deep Sleep command failed\n");
>  		}
>  	}
>  	mod_timer(&priv->auto_deepsleep_timer , jiffies +
> diff --git a/drivers/net/wireless/libertas/scan.c b/drivers/net/wireless/libertas/scan.c
> index 6c95af3..d8fc2b8 100644
> --- a/drivers/net/wireless/libertas/scan.c
> +++ b/drivers/net/wireless/libertas/scan.c
> @@ -1022,9 +1022,12 @@ int lbs_get_scan(struct net_device *dev, struct iw_request_info *info,
>  		return -EAGAIN;
>  
>  	/* Update RSSI if current BSS is a locally created ad-hoc BSS */
> -	if ((priv->mode == IW_MODE_ADHOC) && priv->adhoccreate)
> -		lbs_prepare_and_send_command(priv, CMD_802_11_RSSI, 0,
> -					     CMD_OPTION_WAITFORRSP, 0, NULL);
> +	if ((priv->mode == IW_MODE_ADHOC) && priv->adhoccreate) {
> +		err = lbs_prepare_and_send_command(priv, CMD_802_11_RSSI, 0,
> +				CMD_OPTION_WAITFORRSP, 0, NULL);
> +		if (err)
> +			goto out;
> +	}
>  
>  	mutex_lock(&priv->lock);
>  	list_for_each_entry_safe (iter_bss, safe, &priv->network_list, list) {
> @@ -1058,7 +1061,7 @@ int lbs_get_scan(struct net_device *dev, struct iw_request_info *info,
>  
>  	dwrq->length = (ev - extra);
>  	dwrq->flags = 0;
> -
> +out:
>  	lbs_deb_leave_args(LBS_DEB_WEXT, "ret %d", err);
>  	return err;
>  }
> diff --git a/drivers/net/wireless/libertas/wext.c b/drivers/net/wireless/libertas/wext.c
> index 69dd19b..4594841 100644
> --- a/drivers/net/wireless/libertas/wext.c
> +++ b/drivers/net/wireless/libertas/wext.c
> @@ -832,7 +832,7 @@ static struct iw_statistics *lbs_get_wireless_stats(struct net_device *dev)
>  	u32 rssi_qual;
>  	u32 tx_qual;
>  	u32 quality = 0;
> -	int stats_valid = 0;
> +	int ret, stats_valid = 0;
>  	u8 rssi;
>  	u32 tx_retries;
>  	struct cmd_ds_802_11_get_log log;
> @@ -881,7 +881,9 @@ static struct iw_statistics *lbs_get_wireless_stats(struct net_device *dev)
>  
>  	memset(&log, 0, sizeof(log));
>  	log.hdr.size = cpu_to_le16(sizeof(log));
> -	lbs_cmd_with_response(priv, CMD_802_11_GET_LOG, &log);
> +	ret = lbs_cmd_with_response(priv, CMD_802_11_GET_LOG, &log);
> +	if (ret)
> +		goto out;
>  
>  	tx_retries = le32_to_cpu(log.retry);
>  
> @@ -909,8 +911,10 @@ static struct iw_statistics *lbs_get_wireless_stats(struct net_device *dev)
>  	stats_valid = 1;
>  
>  	/* update stats asynchronously for future calls */
> -	lbs_prepare_and_send_command(priv, CMD_802_11_RSSI, 0,
> +	ret = lbs_prepare_and_send_command(priv, CMD_802_11_RSSI, 0,
>  					0, 0, NULL);
> +	if (ret)
> +		lbs_pr_err("RSSI command failed\n");
>  out:
>  	if (!stats_valid) {
>  		priv->wstats.miss.beacon = 0;


^ permalink raw reply

* Re: [ipw3945-devel] [PATCH 02/17 v2.6.32] iwl3945: update iwl3945_apm_init()
From: reinette chatre @ 2009-10-13 16:59 UTC (permalink / raw)
  To: Vedran Rodic
  Cc: John W. Linville, Cahill, Ben M, linux-wireless@vger.kernel.org,
	ipw3945-devel@lists.sourceforge.net
In-Reply-To: <8ccf2e9c0910130211j6f522d1ia4dc3a764896f974@mail.gmail.com>

On Tue, 2009-10-13 at 02:11 -0700, Vedran Rodic wrote:
> I don't have sophisticated power measurement devices to confirm these
> fixes, and I've only tried patch 2/17, reporting back it on bug
> http://bugzilla.intellinuxwireless.org/show_bug.cgi?id=2094 that the
> problem is still not fixed with this patch applied only.

That is why I did not provide this bug number to John :) There appears
to be two issues here, one of which we have resolved with these patches.
We know that that bug is still open.

> Can you describe your testing methodoloy? Are you testing just the
> mini PCI card usage? Are you comparing to Windows XP or Vista drivers?

What these patches fix is the power consumption when the interface is
brought down. Before this work, if the interface was already up and then
brought down then the power used the device is only reset, not stopped.
We are still investigating an issue of power consumption before the
interface is brought up in the first place. We are not comparing to
other OS, just looking at power consumption.

Reinette


^ permalink raw reply

* [PATCH] rx51: add wl1251 wlan driver support
From: Kalle Valo @ 2009-10-13 16:58 UTC (permalink / raw)
  To: linux-omap; +Cc: linux-wireless

From: Kalle Valo <kalle.valo@nokia.com>

wl1251 is connected to the SPI bus in rx51, add support for this.

Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
---

 arch/arm/mach-omap2/board-rx51-peripherals.c |   85 ++++++++++++++++++++++++++
 1 files changed, 85 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/board-rx51-peripherals.c b/arch/arm/mach-omap2/board-rx51-peripherals.c
index c1af532..ccb8656 100644
--- a/arch/arm/mach-omap2/board-rx51-peripherals.c
+++ b/arch/arm/mach-omap2/board-rx51-peripherals.c
@@ -13,6 +13,7 @@
 #include <linux/platform_device.h>
 #include <linux/input.h>
 #include <linux/spi/spi.h>
+#include <linux/spi/wl12xx.h>
 #include <linux/i2c.h>
 #include <linux/i2c/twl4030.h>
 #include <linux/clk.h>
@@ -36,6 +37,37 @@
 #define SYSTEM_REV_B_USES_VAUX3	0x1699
 #define SYSTEM_REV_S_USES_VAUX3 0x8
 
+#define RX51_WL1251_POWER_GPIO		87
+#define RX51_WL1251_IRQ_GPIO		42
+
+static void rx51_wl1251_set_power(bool enable);
+
+static struct wl12xx_platform_data wl1251_pdata = {
+	.set_power = rx51_wl1251_set_power,
+};
+
+static struct omap2_mcspi_device_config wl1251_mcspi_config = {
+	.turbo_mode	= 0,
+	.single_channel	= 1,
+};
+
+/* list all spi devices here */
+enum {
+	RX51_SPI_WL1251,
+};
+
+static struct spi_board_info rx51_peripherals_spi_board_info[] = {
+	[RX51_SPI_WL1251] = {
+		.modalias		= "wl1251",
+		.bus_num		= 4,
+		.chip_select		= 0,
+		.max_speed_hz   	= 48000000,
+		.mode                   = SPI_MODE_2,
+		.controller_data	= &wl1251_mcspi_config,
+		.platform_data		= &wl1251_pdata,
+	},
+};
+
 static int board_keymap[] = {
 	KEY(0, 0, KEY_Q),
 	KEY(0, 1, KEY_O),
@@ -257,6 +289,55 @@ static struct regulator_init_data rx51_vdac = {
 	},
 };
 
+static void rx51_wl1251_set_power(bool enable)
+{
+	gpio_set_value(RX51_WL1251_POWER_GPIO, enable);
+}
+
+static void __init rx51_init_wl1251(void)
+{
+	int irq, ret;
+
+	ret = gpio_request(RX51_WL1251_POWER_GPIO, "wl1251 power");
+	if (ret < 0)
+		goto error;
+
+	ret = gpio_direction_output(RX51_WL1251_POWER_GPIO, 0);
+	if (ret < 0)
+		goto err_power;
+
+	ret = gpio_request(RX51_WL1251_IRQ_GPIO, "wl1251 irq");
+	if (ret < 0)
+		goto err_power;
+
+	ret = gpio_direction_input(RX51_WL1251_IRQ_GPIO);
+	if (ret < 0)
+		goto err_irq;
+
+	irq = gpio_to_irq(RX51_WL1251_IRQ_GPIO);
+	if (irq < 0)
+		goto err_irq;
+
+	rx51_peripherals_spi_board_info[RX51_SPI_WL1251].irq = irq;
+
+	return;
+
+err_irq:
+	gpio_free(RX51_WL1251_IRQ_GPIO);
+
+err_power:
+	gpio_free(RX51_WL1251_POWER_GPIO);
+
+error:
+	printk(KERN_ERR "wl1251 board initialisation failed\n");
+	wl1251_pdata.set_power = NULL;
+
+	/*
+	 * Now rx51_peripherals_spi_board_info[1].irq is zero and
+	 * set_power is null, and wl1251_probe() will fail.
+	 */
+}
+
 static int rx51_twlgpio_setup(struct device *dev, unsigned gpio, unsigned n)
 {
 	/* FIXME this gpio setup is just a placeholder for now */
@@ -538,6 +619,10 @@ static inline void board_smc91x_init(void)
 
 void __init rx51_peripherals_init(void)
 {
+	rx51_init_wl1251();
+
+	spi_register_board_info(rx51_peripherals_spi_board_info,
+				ARRAY_SIZE(rx51_peripherals_spi_board_info));
 	rx51_i2c_init();
 	board_onenand_init();
 	board_smc91x_init();


^ permalink raw reply related

* Re: 2.6.32-rc4 ipw2200: oops on missing firmware
From: Frans Pop @ 2009-10-13 16:55 UTC (permalink / raw)
  To: Ferenc Wagner
  Cc: linux-kernel, ipw2100-devel, linux-wireless, Reinette Chatre
In-Reply-To: <87hbu3h023.fsf@tac.ki.iif.hu>

Adding relevant CCs. Original message follows.

==============
Hi,

See the screenshot at http://apt.niif.hu/ipw_oops.png.  During bootup,
initramfs-tools tried to load the ipw2200 module, but nobody fed it
the necessary firmware, so request_firmware timed out and the module
unload cleanup oopsed in device_pm_remove:

void device_pm_remove(struct device *dev)
{
        pr_debug("PM: Removing info for %s:%s\n",
                 dev->bus ? dev->bus->name : "No Bus",
                 kobject_name(&dev->kobj));
        mutex_lock(&dpm_list_mtx);
        list_del_init(&dev->power.entry);
        mutex_unlock(&dpm_list_mtx);
        pm_runtime_remove(dev);
}

00000a0a <device_pm_remove>:
 a0a:   55                      push   %ebp
 a0b:   89 e5                   mov    %esp,%ebp
 a0d:   53                      push   %ebx
 a0e:   89 c3                   mov    %eax,%ebx
 a10:   b8 08 00 00 00          mov    $0x8,%eax
 a15:   e8 fc ff ff ff          call   a16 <device_pm_remove+0xc>
 a1a:   8d 4b 5c                lea    0x5c(%ebx),%ecx
 a1d:   8b 53 5c                mov    0x5c(%ebx),%edx
 a20:   8b 43 60                mov    0x60(%ebx),%eax
 a23:   89 42 04                mov    %eax,0x4(%edx)
 a26:   89 10                   mov    %edx,(%eax)
 a28:   89 4b 5c                mov    %ecx,0x5c(%ebx)
 a2b:   89 4b 60                mov    %ecx,0x60(%ebx)
 a2e:   b8 08 00 00 00          mov    $0x8,%eax
 a33:   e8 fc ff ff ff          call   a34 <device_pm_remove+0x2a>
 a38:   89 d8                   mov    %ebx,%eax
 a3a:   e8 fc ff ff ff          call   a3b <device_pm_remove+0x31>
 a3f:   5b                      pop    %ebx
 a40:   5d                      pop    %ebp
 a41:   c3                      ret    

The offending IP translates to line a23, so the problem is edx being 0
at that point.  I'm not sure which struct device field has offset
0x5c, maybe power, but I'm lost at this point anyway.

I don't know whether it's a new bug or not, never did such insane
things previously.  rmmod ipw2200 definitely worked under 2.6.31, and
it's possible that it works under 2.6.32-rc4 too, I forgot to check
that (but will do so tonight).

--
Regards,
Feri.

^ permalink raw reply

* Re: Current status of rt2800usb and staging/rt2870
From: Bartlomiej Zolnierkiewicz @ 2009-10-13 16:44 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: linux-wireless, linux-kernel
In-Reply-To: <4AD46380.9020308@pardus.org.tr>


Hi,

On Tuesday 13 October 2009 13:24:48 Ozan Çağlayan wrote:
> Hi,
> 
> In 2.6.31, there are USB device IDs common between both drivers. Should
> a distribution enable both drivers? What do you suggest? Are there any
> *known issues* stuff for one of them?

My advice to distributions for such situations is to ship both but make
one driver the default one.  This provides users with better overall
hardware coverage and flexibility.  Additionally by providing the ability
for direct comparison of both drivers it makes driver authors/maintainers
try really hard at making the final solution work for everybody (instead
of just making it work for their needs only etc.).

Best regards,
Bartlomiej

^ permalink raw reply

* Re: Current status of rt2800usb and staging/rt2870
From: Ivo van Doorn @ 2009-10-13 15:52 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: linux-wireless, linux-kernel
In-Reply-To: <4AD46380.9020308@pardus.org.tr>

Hi,
 
> In 2.6.31, there are USB device IDs common between both drivers.

That is because they are drivers for the same hardware.

> Should  a distribution enable both drivers? What do you suggest? Are there any
> *known issues* stuff for one of them?

The staging/rt2870 should actually be removed from the kernel tree,
I am going to merge rt2800pci soon as well and after that I'll send a patch
to remove all Ralink drivers from the staging tree.

As for known issues:
- staging/rt2870 is a piece of crap which apparently works for some people
but isn't generally stable or reliable
- wireless/rt2800usb follows the kernel coding style/rules and uses mac80211
but isn't showing a high quality for usability.

Ivo

^ permalink raw reply

* pull request: wireless-2.6 2009-10-13
From: John W. Linville @ 2009-10-13 15:05 UTC (permalink / raw)
  To: davem; +Cc: linux-wireless, netdev, linux-kernel

Dave,

Here are a few (almost-)one-liners for 2.6.32.  Included are fixes for
a use-after-free, a missing "!" in front of a memcmp when comparing
BSSIDs, a race when using hardware-based scanning, the ieee80211_rx
context problem, a related documentation change, and a minor build
issue.

Please let me know if there are problems!

Thanks,

John

---

Individual patches are available here:

	http://www.kernel.org/pub/linux/kernel/people/linville/wireless-2.6/

---

The following changes since commit 10c435f18b8cb78a5870c08d52955594f5ec9c31:
  David S. Miller (1):
        net: Link in PHY drivers before others.

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git master

Alan Cox (1):
      libertas: fix build

Felix Fietkau (1):
      mac80211: fix logic error ibss merge bssid check

Johannes Berg (3):
      mac80211: fix ibss race
      b43: fix ieee80211_rx() context
      mac80211: document ieee80211_rx() context requirement

Wey-Yi Guy (1):
      iwlwifi: change the order of freeing memory

 drivers/net/wireless/b43/xmit.c             |    3 +++
 drivers/net/wireless/iwlwifi/iwl-agn.c      |    2 +-
 drivers/net/wireless/iwlwifi/iwl3945-base.c |    2 +-
 drivers/net/wireless/libertas/cmdresp.c     |    1 +
 include/net/mac80211.h                      |    2 ++
 net/mac80211/ibss.c                         |    4 ++--
 net/mac80211/rx.c                           |    2 ++
 7 files changed, 12 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/b43/xmit.c b/drivers/net/wireless/b43/xmit.c
index 892573b..f4e9695 100644
--- a/drivers/net/wireless/b43/xmit.c
+++ b/drivers/net/wireless/b43/xmit.c
@@ -690,7 +690,10 @@ void b43_rx(struct b43_wldev *dev, struct sk_buff *skb, const void *_rxhdr)
 	}
 
 	memcpy(IEEE80211_SKB_RXCB(skb), &status, sizeof(status));
+
+	local_bh_disable();
 	ieee80211_rx(dev->wl->hw, skb);
+	local_bh_enable();
 
 #if B43_DEBUG
 	dev->rx_count++;
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index cdc07c4..9b5ea8b 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -3105,8 +3105,8 @@ static int iwl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
  out_pci_disable_device:
 	pci_disable_device(pdev);
  out_ieee80211_free_hw:
-	ieee80211_free_hw(priv->hw);
 	iwl_free_traffic_mem(priv);
+	ieee80211_free_hw(priv->hw);
  out:
 	return err;
 }
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index c390dbd..837a193 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -4096,8 +4096,8 @@ static int iwl3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e
 	pci_set_drvdata(pdev, NULL);
 	pci_disable_device(pdev);
  out_ieee80211_free_hw:
-	ieee80211_free_hw(priv->hw);
 	iwl_free_traffic_mem(priv);
+	ieee80211_free_hw(priv->hw);
  out:
 	return err;
 }
diff --git a/drivers/net/wireless/libertas/cmdresp.c b/drivers/net/wireless/libertas/cmdresp.c
index c42d3fa..23f6843 100644
--- a/drivers/net/wireless/libertas/cmdresp.c
+++ b/drivers/net/wireless/libertas/cmdresp.c
@@ -3,6 +3,7 @@
   * responses as well as events generated by firmware.
   */
 #include <linux/delay.h>
+#include <linux/sched.h>
 #include <linux/if_arp.h>
 #include <linux/netdevice.h>
 #include <asm/unaligned.h>
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index 466859b..c75b960 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1669,6 +1669,8 @@ void ieee80211_restart_hw(struct ieee80211_hw *hw);
  * to this function and ieee80211_rx_irqsafe() may not be mixed for a
  * single hardware.
  *
+ * Note that right now, this function must be called with softirqs disabled.
+ *
  * @hw: the hardware this frame came in on
  * @skb: the buffer to receive, owned by mac80211 after this call
  */
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
index 920ec87..6eaf698 100644
--- a/net/mac80211/ibss.c
+++ b/net/mac80211/ibss.c
@@ -544,7 +544,7 @@ static void ieee80211_sta_find_ibss(struct ieee80211_sub_if_data *sdata)
 		       "%pM\n", bss->cbss.bssid, ifibss->bssid);
 #endif /* CONFIG_MAC80211_IBSS_DEBUG */
 
-	if (bss && memcmp(ifibss->bssid, bss->cbss.bssid, ETH_ALEN)) {
+	if (bss && !memcmp(ifibss->bssid, bss->cbss.bssid, ETH_ALEN)) {
 		printk(KERN_DEBUG "%s: Selected IBSS BSSID %pM"
 		       " based on configured SSID\n",
 		       sdata->dev->name, bss->cbss.bssid);
@@ -829,7 +829,7 @@ void ieee80211_ibss_notify_scan_completed(struct ieee80211_local *local)
 		if (!sdata->u.ibss.ssid_len)
 			continue;
 		sdata->u.ibss.last_scan_completed = jiffies;
-		ieee80211_sta_find_ibss(sdata);
+		mod_timer(&sdata->u.ibss.timer, 0);
 	}
 	mutex_unlock(&local->iflist_mtx);
 }
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 865fbc0..7170bf4 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -2453,6 +2453,8 @@ void ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb)
 	struct ieee80211_supported_band *sband;
 	struct ieee80211_rx_status *status = IEEE80211_SKB_RXCB(skb);
 
+	WARN_ON_ONCE(softirq_count() == 0);
+
 	if (WARN_ON(status->band < 0 ||
 		    status->band >= IEEE80211_NUM_BANDS))
 		goto drop;
-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply related

* Re: [rt2x00-users] [PATCH] rt73usb.c : more ids
From: John W. Linville @ 2009-10-13 14:56 UTC (permalink / raw)
  To: rt2x00 Users List; +Cc: linux-wireless
In-Reply-To: <880c1630910130520p30c06846k8692634ec277340@mail.gmail.com>

On Tue, Oct 13, 2009 at 01:20:17PM +0100, Luis Correia wrote:
> Hi Xose,
> 
> 2009/10/13 Xose Vazquez Perez <xose.vazquez@gmail.com>
> 
> > hi,
> >
> > stolen from windows inf file(07/17/2009, 1.03.05.0000)
> > Ovislink 0x1b75, 0x7318
> > MSI 0x0db0, 0x4600
> > WideTell 0x7167, 0x3840
> >
> >
> > -thanks-
> >
> > regards,
> >
> 
> Are you absolutely sure that these devices are really rt73usb?
> 
> By being in the windows inf file doesn't mean they would work in Linux.
> 
> Luis Correia,
> rt2x00 project admin

Please also post patches in the correct format (especially including
the Signed-off-by):

	http://linux.yyz.us/patch-format.html

-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox