Linux wireless drivers development
 help / color / mirror / Atom feed
* [RFC/RFT 0/5] mac80211: implement background scan
From: Helmut Schaa @ 2009-07-16  9:04 UTC (permalink / raw)
  To: linux-wireless; +Cc: Johannes Berg

Hi,

this patch series implements basic background scanning in mac80211
by interrupting the scan after each scanned channel to allow RX/TX.

I only tested the patches on current wireless-testing with iwlagn
in sw-scan mode and it works fine already. One thing I noticed but
seems to be unrelated is: in sw-scan mode the connection sometimes
stalls and no data is transferred anymore although the connection is
still available and I found no way to recover it without setting
it up again.

So, it would be great if somebody could test the patches on other
hardware as well.

Thanks a lot,
Helmut

^ permalink raw reply

* [PATCH 7/8] rt2x00: Use %pM conversion specifier
From: Tobias Klauser @ 2009-07-16  9:00 UTC (permalink / raw)
  To: linville, IvDoorn, netdev, linux-wireless, users; +Cc: Tobias Klauser

Use the %pM conversion specifier for printk instead of print_mac.

Signed-off-by: Tobias Klauser <klto@zhaw.ch>
---
 drivers/net/wireless/rt2x00/rt2800usb.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/rt2x00/rt2800usb.c b/drivers/net/wireless/rt2x00/rt2800usb.c
index 3756166..da84afb 100644
--- a/drivers/net/wireless/rt2x00/rt2800usb.c
+++ b/drivers/net/wireless/rt2x00/rt2800usb.c
@@ -2224,10 +2224,8 @@ static int rt2800usb_validate_eeprom(struct rt2x00_dev *rt2x00dev)
 	 */
 	mac = rt2x00_eeprom_addr(rt2x00dev, EEPROM_MAC_ADDR_0);
 	if (!is_valid_ether_addr(mac)) {
-		DECLARE_MAC_BUF(macbuf);
-
 		random_ether_addr(mac);
-		EEPROM(rt2x00dev, "MAC: %s\n", print_mac(macbuf, mac));
+		EEPROM(rt2x00dev, "MAC: %pM\n", mac);
 	}
 
 	rt2x00_eeprom_read(rt2x00dev, EEPROM_ANTENNA, &word);
-- 
1.6.0.4


^ permalink raw reply related

* [PATCH 2/8] ar9170: Remove unused DECLARE_MAC_BUF
From: Tobias Klauser @ 2009-07-16  8:53 UTC (permalink / raw)
  To: chunkeey, linville, johannes, lrodriguez, yi.zhu, linux-wireless,
	netdev
  Cc: Tobias Klauser

Is not needed anymore because of the %pM printk conversion specifier.

Signed-off-by: Tobias Klauser <klto@zhaw.ch>
---
 drivers/net/wireless/ath/ar9170/main.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/ath/ar9170/main.c b/drivers/net/wireless/ath/ar9170/main.c
index 9d38cf6..3d6373a 100644
--- a/drivers/net/wireless/ath/ar9170/main.c
+++ b/drivers/net/wireless/ath/ar9170/main.c
@@ -2085,7 +2085,6 @@ static int ar9170_read_eeprom(struct ar9170 *ar)
 {
 #define RW	8	/* number of words to read at once */
 #define RB	(sizeof(u32) * RW)
-	DECLARE_MAC_BUF(mbuf);
 	u8 *eeprom = (void *)&ar->eeprom;
 	u8 *addr = ar->eeprom.mac_address;
 	__le32 offsets[RW];
-- 
1.6.0.4


^ permalink raw reply related

* Re: ath5k and Atheros AR242x - No scan results
From: Johannes Berg @ 2009-07-16  8:46 UTC (permalink / raw)
  To: Joel Roth; +Cc: Bob Copeland, linux-wireless
In-Reply-To: <20090716061457.GA1576@sprite>

[-- Attachment #1: Type: text/plain, Size: 249 bytes --]

On Wed, 2009-07-15 at 20:14 -1000, Joel Roth wrote:

> # iwlist wlan0 ap
> 
> wlan0     Interface doesn't have a list of Peers/Access-Points

# iwlist wlan0 scan

should have worked, but I'm glad you're making good use of iw :)

johannes

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

^ permalink raw reply

* Re: [PATCH v3] cfg80211: rework key operation
From: Johannes Berg @ 2009-07-16  8:41 UTC (permalink / raw)
  To: Zhu Yi; +Cc: John Linville, linux-wireless
In-Reply-To: <1247713627.3695.60.camel@debian>

[-- Attachment #1: Type: text/plain, Size: 876 bytes --]

On Thu, 2009-07-16 at 11:07 +0800, Zhu Yi wrote:

> > As discussed with Samuel, there's a possibility to pass _all_ WEP keys
> > directly to connect(), if desirable, instead of adding them with the
> > key hooks later.
> 
> I think this should be the right way to go. Currently we have no way to
> connect to WEP APs (both open and shared) with iwconfig. Because the
> driver needs to set the correct cipher before connect. But the key
> callbacks are only called after connected... IWAUTH is expected to be
> the place to set the cipher here, but unfortunately iwconfig doesn't use
> it. Passing the WEP keys to connect() can solve this issue. The driver
> can at least parsing the connect parameters to set the correct cipher
> before connect.

We could also check the keys and pass the right cipher from cfg80211, in
this case. Should be easy.

johannes

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

^ permalink raw reply

* PCI express card that does AP mode? (abit wlp-01?)
From: Jon Fairbairn @ 2009-07-16  8:02 UTC (permalink / raw)
  To: linux-wireless


A machine I want to set up as an AP has only PCI express slots free...

I've tried looking at the wiki, but I can't easily find an inexpensive
pci express card that will do AP mode. It's the usual problem: shops
don't say what the PCI ids of the device are, and the quoted
manufacturer isn't the manufacturer in the sense needed by the kernel.

I've seen adverts for the Abit WLP-01, and elsewhere on the net seen
implications that it's 168c:001c, which isn't listed at
<http://wireless.kernel.org/en/users/Devices/PCI>, but
<http://wireless.kernel.org/en/users/Drivers/ath5k> does list it and
says AP mode not working, but mentions
<http://madwifi-project.org/wiki/Compatibility/Abit>, which suggest AP
mode works with madwifi. What's the current status?

Alternatively, can anyone recommend a card?

-- 
Jón Fairbairn                                 Jon.Fairbairn@cl.cam.ac.uk



^ permalink raw reply

* Re: ath5k and Atheros AR242x - No scan results
From: Joel Roth @ 2009-07-16  6:54 UTC (permalink / raw)
  To: Bob Copeland, linux-wireless
In-Reply-To: <20090716061457.GA1576@sprite>

On Wed, Jul 15, 2009 at 08:14:57PM -1000, Joel Roth wrote:
> On Mon, Jul 13, 2009 at 10:08:52AM -0400, Bob Copeland wrote:
> > On Sun, Jul 12, 2009 at 4:34 PM, Joel Roth<joelz@pobox.com> wrote:
> > > Vista advised me to:
> > >
> > > 1) turn on the hardware wifi switch <blush>
> > >
> > > 2) use the hotkey combination to enable wifi
> > 
> > It might be worth trying compat-wireless or 2.6.31-rcX.  Support
> > for reading the card's internal rfkill state was added in the
> > post-2.6.30 time-frame.
>  
> I installed compat-wireless against my 2.6.30.1 kernel,
> and also the iw command.
> 
> I've read some docs, however I'm not sure what the next step should be. 
> 
> My general idea is that I should be able to see a list of
> access points, however iwlist doesn't tell me anything new.
> 
> # iwlist wlan0 ap
> 
> wlan0     Interface doesn't have a list of Peers/Access-Points

After some RTFM'ing,

# iw wlan0 scan

BSS 00:40:05:c5:4f:19 (on wlan0) -- associated
	TSF: 9251942689 usec (0d, 02:34:11)
	freq: 2412
	beacon interval: 100
	capability: ESS PBCC (0x0041)
	signal: -40.00 dBm
	SSID: default
	Supported rates: 1.0* 2.0* 5.5* 11.0* 22.0 
	DS Paramater set: channel 1
BSS 00:16:b6:db:fd:78 (on wlan0)
	TSF: 629448825249 usec (7d, 06:50:48)
	freq: 2437
	beacon interval: 100
	capability: ESS ShortSlotTime (0x0401)
	signal: -105.00 dBm
	SSID: linksys
	Supported rates: 1.0* 2.0* 5.5* 11.0* 18.0 24.0 36.0 54.0 
	DS Paramater set: channel 6
	ERP: Barker_Preamble_Mode
	Extended supported rates: 6.0 9.0 12.0 48.0 

# iw wlan0 connect default 

# dhclient wlan0

And voila! I have an IP address on wlan0.
I can't think of anything more that I need. :-)

Oh, maybe a pointer for others.

Perhaps I was just missing the iw 'connect' incantation?
'iwlist' was a complete red herring; didn't help me 
find my AP.

http://linuxwireless.org/en/users/Documentation was the only
site of several I visited mentioning 'iw' at all! 

And at linuxwireless, I find no example of using 'iw' to set
up a connection.  I'd be glad to contribute one.

Thanks Bob, Nick and others for your tips.


-- 
Joel Roth

^ permalink raw reply

* Re: [PATCH 3/3] ath9k: Add support for AR9287 based chipsets.
From: Vivek Natarajan @ 2009-07-16  6:53 UTC (permalink / raw)
  To: Joe Perches; +Cc: linville, linux-wireless
In-Reply-To: <1247628512.3669.13.camel@Joe-Laptop.home>

On Wed, Jul 15, 2009 at 8:58 AM, Joe Perches<joe@perches.com> wrote:
> On Wed, 2009-07-15 at 08:54 +0530, Vivek Natarajan wrote:
>> Signed-off-by: Vivek Natarajan <vnatarajan@atheros.com>
>> diff --git a/drivers/net/wireless/ath/ath9k/calib.c b/drivers/net/wireless/ath/ath9k/calib.c
>> index 1f0c5fe..d1bbb02 100644
>> --- a/drivers/net/wireless/ath/ath9k/calib.c
>> +++ b/drivers/net/wireless/ath/ath9k/calib.c
>> @@ -116,7 +116,7 @@ static void ath9k_hw_do_getnf(struct ath_hw *ah,
>>                               "NF calibrated [ctl] [chain 1] is %d\n", nf);
>>               nfarray[1] = nf;
>>
>> -             if (!AR_SREV_9280(ah)) {
>> +             if (!AR_SREV_9280(ah) && !AR_SREV_9287(ah)) {
>
> This looks like it needs a helper function like IS_AR_SREV_928x(ah)

928X is not needed in this case as there is some other chipset AR9285
which has different capabilities compared to AR9280 and AR9287.

Vivek.

^ permalink raw reply

* Re: any controller working in AP mode ?
From: Ram kumar @ 2009-07-16  6:38 UTC (permalink / raw)
  To: Javier Cardona, andrey; +Cc: linux-wireless
In-Reply-To: <445f43ac0907151344q6d80ddeckc0c586b34d8ca7c5@mail.gmail.com>

hi,

> The thin firmware that allows using the 8383 with mac80211 and
> implement an AP with hostapd is available here:
> http://dev.laptop.org/pub/firmware/libertas/thinfirm/

Thanks for the reply.It looks like currently there are only two
devices support AP mode with USB as an interface.

1.MARVELL 8388.
2.RALINK - RT73USB.

But in the linux wireless website it says RT73USB doesn't support AP
mode.I am assuming that site is not updated with recent
information,please correct me if i am wrong.

It would be very helpful if anyone can guide me,how to get the
hardware for MARVELL 8388.I am aware that the XO OLPC laptop is fitted
with the MARVEL 8388 controller with USB interface.But i am assuming
that the controller is not plug play and it is physically soldered to
the motherboard.

Ofcourse i will try my level best to get the hardware from Marvel also.

I am not sure how to buy the laptop and i am not sure whether we can
detach the wifi marvel 8388 module from the laptop and use it in my
target board.

Please guide me how to get the hardware for marvel 8388 chip.

Regards,
Ram

^ permalink raw reply

* Re: ath5k and Atheros AR242x - No scan results
From: Joel Roth @ 2009-07-16  6:14 UTC (permalink / raw)
  To: Bob Copeland, linux-wireless
In-Reply-To: <20090714065414.GA16708@sprite>

On Mon, Jul 13, 2009 at 10:08:52AM -0400, Bob Copeland wrote:
> On Sun, Jul 12, 2009 at 4:34 PM, Joel Roth<joelz@pobox.com> wrote:
> > Vista advised me to:
> >
> > 1) turn on the hardware wifi switch <blush>
> >
> > 2) use the hotkey combination to enable wifi
> 
> It might be worth trying compat-wireless or 2.6.31-rcX.  Support
> for reading the card's internal rfkill state was added in the
> post-2.6.30 time-frame.
 
I installed compat-wireless against my 2.6.30.1 kernel,
and also the iw command.

I've read some docs, however I'm not sure what the next step should be. 

My general idea is that I should be able to see a list of
access points, however iwlist doesn't tell me anything new.

# iwlist wlan0 ap

wlan0     Interface doesn't have a list of Peers/Access-Points


I'm appending some diagnostics.

Here's what dmesg tells me after 'modprobe ath5k'

[256888.841092] cfg80211: Using static regulatory domain info
[256888.841098] cfg80211: Regulatory domain: US
[256888.841101] 	(start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[256888.841105] 	(2402000 KHz - 2472000 KHz @ 40000 KHz), (600 mBi, 2700 mBm)
[256888.841109] 	(5170000 KHz - 5190000 KHz @ 40000 KHz), (600 mBi, 2300 mBm)
[256888.841112] 	(5190000 KHz - 5210000 KHz @ 40000 KHz), (600 mBi, 2300 mBm)
[256888.841116] 	(5210000 KHz - 5230000 KHz @ 40000 KHz), (600 mBi, 2300 mBm)
[256888.841119] 	(5230000 KHz - 5330000 KHz @ 40000 KHz), (600 mBi, 2300 mBm)
[256888.841123] 	(5735000 KHz - 5835000 KHz @ 40000 KHz), (600 mBi, 3000 mBm)
[256888.841134] cfg80211: Calling CRDA for country: US
[256888.870476] ath5k 0000:05:00.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18
[256888.870492] ath5k 0000:05:00.0: setting latency timer to 64
[256888.870563] ath5k 0000:05:00.0: registered as 'phy0'
[256888.943464] ath: EEPROM regdomain: 0x65
[256888.943466] ath: EEPROM indicates we should expect a direct regpair map
[256888.943471] ath: Country alpha2 being used: 00
[256888.943474] ath: Regpair used: 0x65
[256888.947007] phy0: Selected rate control algorithm 'minstrel'
[256888.947904] ath5k phy0: Atheros AR2425 chip found (MAC: 0xe2, PHY: 0x70)


# iw list


Wiphy phy0
	Band 1:
		Frequencies:
			* 2412 MHz [1] (20.0 dBm)
			* 2417 MHz [2] (20.0 dBm)
			* 2422 MHz [3] (20.0 dBm)
			* 2427 MHz [4] (20.0 dBm)
			* 2432 MHz [5] (20.0 dBm)
			* 2437 MHz [6] (20.0 dBm)
			* 2442 MHz [7] (20.0 dBm)
			* 2447 MHz [8] (20.0 dBm)
			* 2452 MHz [9] (20.0 dBm)
			* 2457 MHz [10] (20.0 dBm)
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm) (passive scanning)
			* 2472 MHz [13] (20.0 dBm) (passive scanning)
			* 2484 MHz [14] (disabled)
		Bitrates (non-HT):
			* 1.0 Mbps
			* 2.0 Mbps (short preamble supported)
			* 5.5 Mbps (short preamble supported)
			* 11.0 Mbps (short preamble supported)
			* 6.0 Mbps
			* 9.0 Mbps
			* 12.0 Mbps
			* 18.0 Mbps
			* 24.0 Mbps
			* 36.0 Mbps
			* 48.0 Mbps
			* 54.0 Mbps
	max # scan SSIDs: 4
	Supported interface modes:
		 * IBSS
		 * managed
		 * AP
		 * AP/VLAN
		 * monitor
		 * mesh point

# iw wlan0 scan

BSS 00:40:05:c5:4f:19 (on wlan0)
        TSF: 5703065889 usec (0d, 01:35:03)
        freq: 2412
        beacon interval: 100
        capability: ESS PBCC (0x0041)
        signal: -92.00 dBm
        SSID: default
        Supported rates: 1.0* 2.0* 5.5* 11.0* 22.0 
        DS Paramater set: channel 1
BSS 00:16:b6:db:fd:78 (on wlan0)
        TSF: 625899182784 usec (7d, 05:51:39)
        freq: 2437
        beacon interval: 100
        capability: ESS ShortSlotTime (0x0401)
        signal: -101.00 dBm
        SSID: linksys
        Supported rates: 1.0* 2.0* 5.5* 11.0* 18.0 24.0 36.0
54.0 
        DS Paramater set: channel 6
        ERP: Barker_Preamble_Mode
        Extended supported rates: 6.0 9.0 12.0 48.0 

# iw wlan0 info
Interface wlan0
        ifindex 6
        type managed




-- 
Joel Roth

^ permalink raw reply

* Re: Unable to load iwlagn module: Failed to register hw (error -17)
From: John Ranson @ 2009-07-16  3:58 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: Johannes Berg, reinette chatre, linux-wireless@vger.kernel.org
In-Reply-To: <43e72e890907150925p51c1a019r95266cbdc1e762e4@mail.gmail.com>

The release is master-2009-07-08-3-g3615cdf

/sys/class/ieee80211/ is empty

I'm running Gentoo on an Lenovo R61. I don't think that there is
anything too special about my configuration.

Is there any more information that I can provide that will help debug?

Thanks,

John


On Wed, Jul 15, 2009 at 9:25 AM, Luis R. Rodriguez<mcgrof@gmail.com> wrote:
> On Wed, Jul 15, 2009 at 9:11 AM, Johannes Berg<johannes@sipsolutions.net> wrote:
>> Hi,
>>
>>> On Tue, 2009-07-14 at 21:25 -0700, John Ranson wrote:
>>> > [    4.252445] iwlagn 0000:03:00.0: Tunable channels: 11 802.11bg, 13
>>> > 802.11a channels
>>> > [    4.252556] iwlagn 0000:03:00.0: irq 30 for MSI/MSI-X
>>> > [    4.252945] iwlagn 0000:03:00.0: Failed to register hw (error -17)
>>> > [    4.253255] iwlagn 0000:03:00.0: PCI INT A disabled
>>> > [    4.253263] iwlagn: probe of 0000:03:00.0 failed with error -17
>>>
>>> This is ieee80211_register_hw() returning error 17 (EEXIST). One spot I
>>> saw where this can happen is if you are trying to register with the same
>>> name (wlanX) already used by another netdevice. Does this sound possible
>>> in your setup?
>>>
>>> Johannes - do you perhaps have an idea when this can happen?
>>
>> This is strange -- I've had one report of this with 3945 which went away
>> and seemed to have been a compat only issue, I suspect this is also just
>> a compat-wireless issue, but I have no idea.
>
> We've had a lot of changes to compat-wireless recently so this is possible.
>
> John, can you cat compat-release on your compat-wireless directory?
>
>  Luis
>

^ permalink raw reply

* [PATCH] hostap_cs: Enable shared interrupts
From: Larry Finger @ 2009-07-16  3:49 UTC (permalink / raw)
  To: John W Linville, j; +Cc: puck, linux-wireless

The hostap_cs driver is programmed for exclusive rather that shared
interrupts.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Reported-and-Tested-by: Jack Schneider <puck@dp-indexing.com>
---

John,

This is an original bug. It doesn't make much difference which
kernel first gets the fix.

Larry
---

Index: wireless-testing/drivers/net/wireless/hostap/hostap_cs.c
===================================================================
--- wireless-testing.orig/drivers/net/wireless/hostap/hostap_cs.c
+++ wireless-testing/drivers/net/wireless/hostap/hostap_cs.c
@@ -666,7 +666,8 @@ static int prism2_config(struct pcmcia_d
 	 * irq structure is initialized.
 	 */
 	if (link->conf.Attributes & CONF_ENABLE_IRQ) {
-		link->irq.Attributes = IRQ_TYPE_EXCLUSIVE | IRQ_HANDLE_PRESENT;
+		link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING |
+				       IRQ_HANDLE_PRESENT;
 		link->irq.IRQInfo1 = IRQ_LEVEL_ID;
 		link->irq.Handler = prism2_interrupt;
 		link->irq.Instance = dev;

^ permalink raw reply

* Re: [PATCH v3] cfg80211: rework key operation
From: Zhu Yi @ 2009-07-16  3:07 UTC (permalink / raw)
  To: Johannes Berg; +Cc: John Linville, linux-wireless
In-Reply-To: <1247669030.10754.1.camel@johannes.local>

On Wed, 2009-07-15 at 22:43 +0800, Johannes Berg wrote:
> I should also note that you can now get rid of the stuff in iwm that
> caches the keys etc -- key callbacks will only be called after
> connecting.

Thanks. Patches are queued. Will send out later.

> As discussed with Samuel, there's a possibility to pass _all_ WEP keys
> directly to connect(), if desirable, instead of adding them with the
> key hooks later.

I think this should be the right way to go. Currently we have no way to
connect to WEP APs (both open and shared) with iwconfig. Because the
driver needs to set the correct cipher before connect. But the key
callbacks are only called after connected... IWAUTH is expected to be
the place to set the cipher here, but unfortunately iwconfig doesn't use
it. Passing the WEP keys to connect() can solve this issue. The driver
can at least parsing the connect parameters to set the correct cipher
before connect.

Thanks,
-yi


^ permalink raw reply

* Can't cross-compile iw-0.9.15
From: Philip A. Prindeville @ 2009-07-16  2:27 UTC (permalink / raw)
  To: linux-wireless

I'm trying to add the "iw" package to astlinux (http://www.astlinux.org)
but it doesn't seem to be very cross-compilation friendly.

It wants to use pkg-config a lot, for instance...

Does anyone have a patched version that lets me pass in all my settings
brute force by hand?

Thanks,

-Philip



^ permalink raw reply

* Re: Build instructions for cross-compilation environment
From: Philip A. Prindeville @ 2009-07-15 22:40 UTC (permalink / raw)
  To: Bob Copeland; +Cc: linux-wireless, mcgrof
In-Reply-To: <b6c5339f0907151451r2ae9e3bcvcafd921b300fb040@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 13827 bytes --]

Bob Copeland wrote:
> On Wed, Jul 15, 2009 at 4:09 PM, Philip A.
> Prindeville<philipp_subx@redfish-solutions.com> wrote:
>> Also, a list of what CONFIG_xxx symbols I need to turn off to ensure
>> that there is no "residue" left over from the kernel build to interfere
>> with the compat-wireless build would be helpful (or alternatively,
>> what's the bare essential list of CONFIG_xxx symbols that need to be
>> enabled to "hook" compat-wireless into an existing kernel).
> 
> At least CONFIG_{CFG80211,MAC80211}=m but you'll likely need to experiment.
> 
>> Looking at the Makefiles, it doesn't seem that cross-compilation is
>> ready out-of-the-box:
> 
> Perhaps it isn't for the installation stuff, but I've had no problems
> building the modules with a cross compiler.  And you said you wanted to
> customize installation anyway (just copy the built modules under 'kernel'
> if that's what you want.  It doesn't matter where they live as long as
> depmod finds them;'updates' is nice for rollback, however.)
> 
> Here's my dumb cross compilation script, make-arm.sh:
> 
> #!/bin/bash
> 
> DIR=/home/bob/ext/linux-2.6
> XGCC=/home/bob/projects/xgcc
> export PATH="$XGCC/arm-2008q3/bin/:$PATH"
> make ARCH=arm CROSS_COMPILE=arm-none-eabi- KLIB=$DIR KLIB_BUILD=$DIR "$@"
> 
>> Please reply to me directly (or even on Cc).  I tried to join the list a
>> couple of weeks ago, but my request hasn't yet been processed.
> 
> Perhaps try again?  majordomo can be slow but two weeks slow sounds
> off...
> 


Hmmmm...  Found that a certain amount of patching was in order...  attached.

Now when I build, however, I'm getting some linkage warnings (below).  Is there an easy way to skip the PC-card/PCMCIA-based drivers?

Also, built my kernel with CONFIG_RFKILL=m ... that seems to be an issue.  Do I need to build it with =y instead?

Ditto with CONFIG_CRC_ITU_T=m

Logs:

make -j5 -C /home/philipp/kernel/build_i586/compat-wireless-2.6.30 \
		HOSTCC=gcc CC=/home/philipp/kernel/build_i586/staging_dir/bin/i586-linux-uclibc-gcc ARCH=i386 \
		KLIB=/lib/modules/2.6.27.26-astlinux KLIB_BUILD=/home/philipp/kernel/build_i586/linux-2.6.27.26-astlinux \
		MODPROBE='true' PWD=/home/philipp/kernel/build_i586/compat-wireless-2.6.30 \
		KMODDIR= \
		KMODPATH_ARG='INSTALL_MOD_PATH=/home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux' \
		install-modules
make[1]: Entering directory `/home/philipp/kernel/build_i586/compat-wireless-2.6.30'
make -C /home/philipp/kernel/build_i586/linux-2.6.27.26-astlinux M=/home/philipp/kernel/build_i586/compat-wireless-2.6.30 "INSTALL_MOD_DIR=" INSTALL_MOD_PATH=/home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux \
		modules_install
make[2]: Entering directory `/home/philipp/kernel/build_i586/linux-2.6.27.26-astlinux'
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/b44.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/usb/rndis_host.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/usb/cdc_ether.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/misc/eeprom/eeprom_93cx6.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/usb/usbnet.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/at76c50x-usb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/adm8211.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/ath5k/ath5k.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/ath9k/ath9k.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/b43legacy/b43legacy.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/b43/b43.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/ipw2x00/ipw2100.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/ipw2x00/libipw.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/ipw2x00/ipw2200.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/iwlwifi/iwl3945.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/iwlwifi/iwlcore.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/libertas/libertas.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/iwlwifi/iwlagn.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/libertas/usb8xxx.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/mac80211_hwsim.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/mwl8k.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/p54/p54common.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/p54/p54pci.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/p54/p54usb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rndis_wlan.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2400pci.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2500pci.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2500usb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2x00pci.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2x00lib.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt2x00usb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt73usb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rt2x00/rt61pci.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rtl818x/rtl8180.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/rtl818x/rtl8187.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/net/wireless/zd1211rw/zd1211rw.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/mac80211/mac80211.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/drivers/ssb/ssb.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/wireless/cfg80211.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/wireless/lib80211.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/wireless/lib80211_crypt_ccmp.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/wireless/lib80211_crypt_wep.ko
  INSTALL /home/philipp/kernel/build_i586/compat-wireless-2.6.30/net/wireless/lib80211_crypt_tkip.ko
  DEPMOD  2.6.27.26-astlinux
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/rt2x00/rt73usb.ko needs unknown symbol crc_itu_t_table
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/rt2x00/rt73usb.ko needs unknown symbol crc_itu_t
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/rt2x00/rt61pci.ko needs unknown symbol crc_itu_t_table
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/rt2x00/rt61pci.ko needs unknown symbol crc_itu_t
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/ath9k/ath9k.ko needs unknown symbol rfkill_force_state
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/ath9k/ath9k.ko needs unknown symbol rfkill_unregister
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/ath9k/ath9k.ko needs unknown symbol rfkill_free
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/ath9k/ath9k.ko needs unknown symbol rfkill_allocate
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/ath9k/ath9k.ko needs unknown symbol rfkill_register
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_disable_device
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_unregister_driver
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_map_mem_page
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_get_first_tuple
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_window
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_configuration
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_get_tuple_data
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_register_driver
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_parse_tuple
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_irq
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/ssb/ssb.ko needs unknown symbol pccard_get_first_tuple
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/ssb/ssb.ko needs unknown symbol pcmcia_access_configuration_register
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/ssb/ssb.ko needs unknown symbol pccard_get_tuple_data
WARNING: /home/philipp/kernel/build_i586/root//lib/modules/2.6.27.26-astlinux/lib/modules/2.6.27.26-astlinux/drivers/ssb/ssb.ko needs unknown symbol pccard_get_next_tuple
make[2]: Leaving directory `/home/philipp/kernel/build_i586/linux-2.6.27.26-astlinux'
make[1]: Leaving directory `/home/philipp/kernel/build_i586/compat-wireless-2.6.30'
/sbin/depmod -ae -F /home/philipp/kernel/build_i586/linux-2.6.27.26-astlinux/System.map -b /home/philipp/kernel/build_i586/root -r 2.6.27.26-astlinux
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_disable_device
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_unregister_driver
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_map_mem_page
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_get_first_tuple
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_window
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_configuration
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_get_tuple_data
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_register_driver
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pccard_parse_tuple
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/net/wireless/b43/b43.ko needs unknown symbol pcmcia_request_irq
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/ssb/ssb.ko needs unknown symbol pccard_get_first_tuple
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/ssb/ssb.ko needs unknown symbol pcmcia_access_configuration_register
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/ssb/ssb.ko needs unknown symbol pccard_get_tuple_data
WARNING: /home/philipp/kernel/build_i586/root/lib/modules/2.6.27.26-astlinux/extra/drivers/ssb/ssb.ko needs unknown symbol pccard_get_next_tuple


[-- Attachment #2: compat-wireless-makefile.patch --]
[-- Type: text/plain, Size: 2453 bytes --]

--- compat-wireless-2.6.30/Makefile.orig	2009-06-10 17:24:42.000000000 -0700
+++ compat-wireless-2.6.30/Makefile	2009-07-15 14:13:21.000000000 -0700
@@ -1,6 +1,6 @@
 export KMODDIR?=       updates
 KMODDIR_ARG:=   "INSTALL_MOD_DIR=$(KMODDIR)"
-ifneq ($(origin $(KLIB)), undefined)
+ifneq ($(origin KLIB), undefined)
 KMODPATH_ARG:=  "INSTALL_MOD_PATH=$(KLIB)"
 else
 export KLIB:=          /lib/modules/$(shell uname -r)
@@ -11,6 +11,8 @@ MODPROBE := /sbin/modprobe
 MADWIFI=$(shell $(MODPROBE) -l ath_pci)
 OLD_IWL=$(shell $(MODPROBE) -l iwl4965)
 
+DESTDIR?=
+
 ifneq ($(KERNELRELEASE),)
 
 include $(M)/$(COMPAT_CONFIG)
@@ -58,21 +60,25 @@ $(CREL_CHECK):
 	@touch $@
 	@md5sum $(COMPAT_CONFIG) > $(CONFIG_CHECK)
 
-install: uninstall modules
+install: uninstall install-modules install-scripts
+
+install-modules: modules
 	$(MAKE) -C $(KLIB_BUILD) M=$(PWD) $(KMODDIR_ARG) $(KMODPATH_ARG) \
 		modules_install
+
+install-scripts:
 	@# All the scripts we can use
-	@mkdir -p /usr/lib/compat-wireless/
-	@install scripts/modlib.sh	/usr/lib/compat-wireless/
-	@install scripts/madwifi-unload	/usr/sbin/
+	@mkdir -p $(DESTDIR)/usr/lib/compat-wireless/
+	@install scripts/modlib.sh	$(DESTDIR)/usr/lib/compat-wireless/
+	@install scripts/madwifi-unload	$(DESTDIR)/usr/sbin/
 	@# This is to allow switching between drivers without blacklisting
-	@install scripts/athenable	/usr/sbin/
-	@install scripts/b43enable	/usr/sbin/
-	@install scripts/iwl-enable	/usr/sbin/
-	@install scripts/athload	/usr/sbin/
-	@install scripts/b43load	/usr/sbin/
-	@install scripts/iwl-load	/usr/sbin/
-	@if [ ! -z $(MADWIFI) ]; then \
+	@install scripts/athenable	$(DESTDIR)/usr/sbin/
+	@install scripts/b43enable	$(DESTDIR)/usr/sbin/
+	@install scripts/iwl-enable	$(DESTDIR)/usr/sbin/
+	@install scripts/athload	$(DESTDIR)/usr/sbin/
+	@install scripts/b43load	$(DESTDIR)/usr/sbin/
+	@install scripts/iwl-load	$(DESTDIR)/usr/sbin/
+	@if [ ! -z $(MADWIFI) && -z "$(DESTDIR)" ]; then \
 		echo ;\
 		echo -n "Note: madwifi detected, we're going to disable it. "  ;\
 		echo "If you would like to enable it later you can run:"  ;\
@@ -81,7 +88,7 @@ install: uninstall modules
 		echo Running athenable ath5k...;\
 		/usr/sbin/athenable ath5k ;\
 	fi
-	@if [ ! -z $(OLD_IWL) ]; then \
+	@if [ ! -z $(OLD_IWL) && -z "$(DESTDIR)" ]; then \
 		echo ;\
 		echo -n "Note: iwl4965 detected, we're going to disable it. "  ;\
 		echo "If you would like to enable it later you can run:"  ;\

^ permalink raw reply

* Re: Build instructions for cross-compilation environment
From: Luis R. Rodriguez @ 2009-07-15 22:11 UTC (permalink / raw)
  To: Bob Copeland; +Cc: Philip A. Prindeville, linux-wireless
In-Reply-To: <b6c5339f0907151451r2ae9e3bcvcafd921b300fb040@mail.gmail.com>

On Wed, Jul 15, 2009 at 2:51 PM, Bob Copeland<me@bobcopeland.com> wrote:
> On Wed, Jul 15, 2009 at 4:09 PM, Philip A.
> Prindeville<philipp_subx@redfish-solutions.com> wrote:
>> Also, a list of what CONFIG_xxx symbols I need to turn off to ensure
>> that there is no "residue" left over from the kernel build to interfere
>> with the compat-wireless build would be helpful (or alternatively,
>> what's the bare essential list of CONFIG_xxx symbols that need to be
>> enabled to "hook" compat-wireless into an existing kernel).
>
> At least CONFIG_{CFG80211,MAC80211}=m but you'll likely need to experiment.

I take it you mean on your currently running kernel?

Your own kernel requirements aren't dramatic. Its actually very
simple. Enable networking (duh), PCI if you want PCI drivers, USB if
you want USB drivers, etc.

Wext is now optional but IIRC I haven't removed that requirement from
compat-wireless. So for now enable that.

  Luis

^ permalink raw reply

* Re: Build instructions for cross-compilation environment
From: Bob Copeland @ 2009-07-15 21:51 UTC (permalink / raw)
  To: Philip A. Prindeville; +Cc: linux-wireless, mcgrof
In-Reply-To: <4A5E377E.6090705@redfish-solutions.com>

On Wed, Jul 15, 2009 at 4:09 PM, Philip A.
Prindeville<philipp_subx@redfish-solutions.com> wrote:
> Also, a list of what CONFIG_xxx symbols I need to turn off to ensure
> that there is no "residue" left over from the kernel build to interfere
> with the compat-wireless build would be helpful (or alternatively,
> what's the bare essential list of CONFIG_xxx symbols that need to be
> enabled to "hook" compat-wireless into an existing kernel).

At least CONFIG_{CFG80211,MAC80211}=m but you'll likely need to experiment.

> Looking at the Makefiles, it doesn't seem that cross-compilation is
> ready out-of-the-box:

Perhaps it isn't for the installation stuff, but I've had no problems
building the modules with a cross compiler.  And you said you wanted to
customize installation anyway (just copy the built modules under 'kernel'
if that's what you want.  It doesn't matter where they live as long as
depmod finds them;'updates' is nice for rollback, however.)

Here's my dumb cross compilation script, make-arm.sh:

#!/bin/bash

DIR=/home/bob/ext/linux-2.6
XGCC=/home/bob/projects/xgcc
export PATH="$XGCC/arm-2008q3/bin/:$PATH"
make ARCH=arm CROSS_COMPILE=arm-none-eabi- KLIB=$DIR KLIB_BUILD=$DIR "$@"

> Please reply to me directly (or even on Cc).  I tried to join the list a
> couple of weeks ago, but my request hasn't yet been processed.

Perhaps try again?  majordomo can be slow but two weeks slow sounds
off...

-- 
Bob Copeland %% www.bobcopeland.com

^ permalink raw reply

* Re: any controller working in AP mode ?
From: Javier Cardona @ 2009-07-15 20:44 UTC (permalink / raw)
  To: Ram kumar; +Cc: linux-wireless
In-Reply-To: <6306c640907142221o27c257aaw12f73da8118376f@mail.gmail.com>

Ram,

On Tue, Jul 14, 2009 at 10:21 PM, Ram kumar<ramkumar.research@gmail.com> wrote:
> 2.Marvell 8388 controller supports AP mode,but it seems marvell has
> not released the AP mode firmware.

The thin firmware that allows using the 8383 with mac80211 and
implement an AP with hostapd is available here:
http://dev.laptop.org/pub/firmware/libertas/thinfirm/

Javier

^ permalink raw reply

* Re: [PATCH 16/21] mac80211: add helper for management / no-ack frame rate decision
From: reinette chatre @ 2009-07-15 20:33 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: linville@tuxdriver.com, johannes@sipsolutions.net,
	linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
	Zhu, Yi, ipw3945-devel@lists.sourceforge.net, Gabor Juhos,
	Felix Fietkau, Derek Smithies, Chittajit Mitra
In-Reply-To: <1247616853-11221-17-git-send-email-lrodriguez@atheros.com>

Hi Luis,

On Tue, 2009-07-14 at 17:14 -0700, Luis R. Rodriguez wrote:
> All current rate control algorithms agree to send management and no-ack
> frames at the lowest rate. They also agree to do this when sta
> and the private rate control data is NULL. We add a hlper to mac80211
> for this and simplify the rate control algorithm code.
> 
> Developers wishing to make enhancements to rate control algorithms
> are for broadcast/multicast can opt to not use this in their
> gate_rate() mac80211 callback.
> 
> Cc: Zhu Yi <yi.zhu@intel.com>
> Cc: Reinette Chatre <reinette.chatre@intel.com>
> Cc: ipw3945-devel@lists.sourceforge.net
> Cc: Gabor Juhos <juhosg@openwrt.org>
> Cc: Felix Fietkau <nbd@openwrt.org>
> Cc: Derek Smithies <derek@indranet.co.nz>
> Cc: Chittajit Mitra <Chittajit.Mitra@Atheros.com>
> Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
> ---
>  drivers/net/wireless/ath/ath9k/rc.c        |   14 +------------
>  drivers/net/wireless/iwlwifi/iwl-3945-rs.c |   13 ++---------
>  drivers/net/wireless/iwlwifi/iwl-agn-rs.c  |    7 +-----
>  include/net/mac80211.h                     |   23 ++++++++++++++++++++++
>  net/mac80211/rate.c                        |   29 ++++++++++++++++++++++++++++
>  net/mac80211/rc80211_minstrel.c            |   22 +--------------------
>  net/mac80211/rc80211_pid_algo.c            |   11 +---------
>  7 files changed, 59 insertions(+), 60 deletions(-)
> 

> diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c
> index 3fea027..695a841 100644
> --- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c
> +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c
> @@ -2481,13 +2481,8 @@ static void rs_get_rate(void *priv_r, struct ieee80211_sta *sta, void *priv_sta,
>  	}
>  
>  	/* Send management frames and NO_ACK data using lowest rate. */
> -	if (!ieee80211_is_data(hdr->frame_control) ||
> -	    info->flags & IEEE80211_TX_CTL_NO_ACK || !sta || !lq_sta) {
> -		info->control.rates[0].idx = rate_lowest_index(sband, sta);
> -		if (info->flags & IEEE80211_TX_CTL_NO_ACK)
> -			info->control.rates[0].count = 1;
> +	if (rate_control_send_low(sta, priv_r, txrc))

I think it should be priv_sta instead of priv_r here.

The rest looks good for iwlwifi.

Reinette




^ permalink raw reply

* Re: [PATCH 15/21] iwlwifi: use ieee80211_is_data(fc)
From: reinette chatre @ 2009-07-15 20:33 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: linville@tuxdriver.com, johannes@sipsolutions.net,
	linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
	Zhu, Yi, ipw3945-devel@lists.sourceforge.net
In-Reply-To: <1247616853-11221-16-git-send-email-lrodriguez@atheros.com>

Hi Luis,

On Tue, 2009-07-14 at 17:14 -0700, Luis R. Rodriguez wrote:
> iwl-agn-rs.c already uses this.
> 
> Cc: Zhu Yi <yi.zhu@intel.com>
> Cc: Reinette Chatre <reinette.chatre@intel.com>
> Cc: ipw3945-devel@lists.sourceforge.net
> Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
> ---

Acked-by: Reinette Chatre <reinette.chatre@intel.com>

Thank you

Reinette




^ permalink raw reply

* Re: [PATCH 03/21] iwlwifi: remove rs_get_rate workaround
From: reinette chatre @ 2009-07-15 20:32 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: linville@tuxdriver.com, johannes@sipsolutions.net,
	linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
	Abbas, Mohamed
In-Reply-To: <1247616853-11221-4-git-send-email-lrodriguez@atheros.com>

Hi Luis,

On Tue, 2009-07-14 at 17:13 -0700, Luis R. Rodriguez wrote:
> This removes the work around implemented for transmitting on
> an unsupported band on iwlwifi. This was added via the patch:
> 
> 8e1856e82cb8f541e925738bebfbc473420cda68:
> iwlwifi: fix rs_get_rate WARN_ON()
> 
> Cc: Mohamed Abbas <mohamed.abbas@intel.com>
> Cc: Reinette Chatre <reinette.chatre@intel.com>
> Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>

I tried this patch with and without first applying 1/21 "mac80211: drop
frames for sta with no valid rate" but could not reproduce that bug
([1]) anymore. 

Even so ...

Acked-by: Reinette Chatre <reinette.chatre@intel.com

Thank you

Reinette


[1] http://www.intellinuxwireless.org/bugzilla/show_bug.cgi?id=1822



^ permalink raw reply

* Build instructions for cross-compilation environment
From: Philip A. Prindeville @ 2009-07-15 20:09 UTC (permalink / raw)
  To: linux-wireless; +Cc: mcgrof

Hi.

I'm the lead developer for Astlinux.

We're doing a kernel bump from 2.6.26.8 to 2.6.27.26, and wanted to take
the opportunity to start using compat-wireless at the same time, because
we need (amongst other things) better mac80211/cfg80211/nl80211 and
AP-mode for the Ath5k chipset (AR5413, et al).

The README included in the tarball (compat-wireless-2.6.30.tar.bz2)
discusses building replacement drivers on the same system and placing
them into updates/.

I'd like to cross-compile this on a system and replace the drivers that
have been deposited by the plain-vanilla kernel build.

Also, a list of what CONFIG_xxx symbols I need to turn off to ensure
that there is no "residue" left over from the kernel build to interfere
with the compat-wireless build would be helpful (or alternatively,
what's the bare essential list of CONFIG_xxx symbols that need to be
enabled to "hook" compat-wireless into an existing kernel).

Looking at the Makefiles, it doesn't seem that cross-compilation is
ready out-of-the-box:

MADWIFI=$(shell $(MODPROBE) -l ath_pci)
OLD_IWL=$(shell $(MODPROBE) -l iwl4965)


Please reply to me directly (or even on Cc).  I tried to join the list a
couple of weeks ago, but my request hasn't yet been processed.

Thanks,

-Philip


^ permalink raw reply

* Re: [PATCH] mac80211: don't sleep in mesh_path_add allocation
From: Andrey Yurovsky @ 2009-07-15 18:40 UTC (permalink / raw)
  To: Johannes Berg; +Cc: linux-wireless, javier
In-Reply-To: <1247681863.10754.26.camel@johannes.local>

On Wed, Jul 15, 2009 at 11:17 AM, Johannes
Berg<johannes@sipsolutions.net> wrote:
> On Wed, 2009-07-15 at 11:02 -0700, Andrey Yurovsky wrote:
>> mesh_path_add allocates an mpath and a node but it is called with RCU
>> held.  Use the GFP_ATOMIC flag to prevent these allocations from
>> sleeping since otherwise we can hit the following sleep-while-atomic:
>
> This isn't sufficient, quoting from the function, highlight added:
>
> int mesh_path_add(u8 *dst, struct ieee80211_sub_if_data *sdata)
> {
> ...
>        if (grow) {
>                struct mesh_table *oldtbl, *newtbl;
>
>                write_lock(&pathtbl_resize_lock);
>                oldtbl = mesh_paths;
>                newtbl = mesh_table_grow(mesh_paths);
>                if (!newtbl) {
>                        write_unlock(&pathtbl_resize_lock);
>                        return 0;
>                }
>                rcu_assign_pointer(mesh_paths, newtbl);
>                write_unlock(&pathtbl_resize_lock);
>
> *******         synchronize_rcu();
>                mesh_table_free(oldtbl, false);
>        }
> ...
> }
>
> johannes
>

Yes, we'll address growing the issue separately.  Ok, we'll send a new
patch for the allocations as well as growing the table in the future.

  -Andrey

^ permalink raw reply

* [PATCH v3] mac80211: drop frames for sta with no valid rate
From: Luis R. Rodriguez @ 2009-07-15 18:18 UTC (permalink / raw)
  To: johannes, linville; +Cc: linux-wireless, ath9k-devel, Luis R. Rodriguez

When we're associated we should be able to send data to
target sta. If we cannot we may be trying to use the incorrect
band to talk to the sta. Lets catch any such cases, warn, and
drop the frames to not invalidate assumptions being made on
rate control algorithms when they have a valid sta to
communicate with. Any such cases should be handled and fixed.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
---

John, sorry but this one is simpler, removes the #ifdef crap.

 include/net/mac80211.h |   11 +++++++++++
 net/mac80211/tx.c      |   20 ++++++++++++++++++++
 2 files changed, 31 insertions(+), 0 deletions(-)

diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index 14ef478..9428258 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -2113,6 +2113,17 @@ rate_lowest_index(struct ieee80211_supported_band *sband,
 	return 0;
 }
 
+static inline
+bool rate_usable_index_exists(struct ieee80211_supported_band *sband,
+			      struct ieee80211_sta *sta)
+{
+	unsigned int i;
+
+	for (i = 0; i < sband->n_bitrates; i++)
+		if (rate_supported(sta, sband->band, i))
+			return true;
+	return false;
+}
 
 int ieee80211_rate_control_register(struct rate_control_ops *ops);
 void ieee80211_rate_control_unregister(struct rate_control_ops *ops);
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 969a4b2..eae43e9 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -512,6 +512,7 @@ ieee80211_tx_h_rate_ctrl(struct ieee80211_tx_data *tx)
 	int i, len;
 	bool inval = false, rts = false, short_preamble = false;
 	struct ieee80211_tx_rate_control txrc;
+	u32 sta_flags;
 
 	memset(&txrc, 0, sizeof(txrc));
 
@@ -544,7 +545,26 @@ ieee80211_tx_h_rate_ctrl(struct ieee80211_tx_data *tx)
 	     (tx->sta && test_sta_flags(tx->sta, WLAN_STA_SHORT_PREAMBLE))))
 		txrc.short_preamble = short_preamble = true;
 
+	sta_flags = tx->sta ? get_sta_flags(tx->sta) : 0;
+
+	/*
+	 * Lets not bother rate control if we're associated and cannot
+	 * talk to the sta. This should not happen.
+	 */
+	if (WARN((tx->local->sw_scanning) &&
+		 (sta_flags & WLAN_STA_ASSOC) &&
+		 !rate_usable_index_exists(sband, &tx->sta->sta),
+		 "%s: Dropped data from as no usable bitrate found while "
+		 "scanning and associated. Target station: "
+		 "%pM on %d GHz band\n",
+		 tx->dev->name, hdr->addr1,
+		 tx->channel->band ? 5 : 2))
+		return TX_DROP;
 
+	/*
+	 * If we're associated with the sta at this point we know we can at
+	 * least send the frame at the lowest bit rate.
+	 */
 	rate_control_get_rate(tx->sdata, tx->sta, &txrc);
 
 	if (unlikely(info->control.rates[0].idx < 0))
-- 
1.6.3.3


^ permalink raw reply related

* Re: [PATCH] mac80211: don't sleep in mesh_path_add allocation
From: Johannes Berg @ 2009-07-15 18:17 UTC (permalink / raw)
  To: Andrey Yurovsky; +Cc: linux-wireless, javier
In-Reply-To: <1247680936-21513-1-git-send-email-andrey@cozybit.com>

[-- Attachment #1: Type: text/plain, Size: 1013 bytes --]

On Wed, 2009-07-15 at 11:02 -0700, Andrey Yurovsky wrote:
> mesh_path_add allocates an mpath and a node but it is called with RCU
> held.  Use the GFP_ATOMIC flag to prevent these allocations from
> sleeping since otherwise we can hit the following sleep-while-atomic:

This isn't sufficient, quoting from the function, highlight added:

int mesh_path_add(u8 *dst, struct ieee80211_sub_if_data *sdata)
{
...
        if (grow) {
                struct mesh_table *oldtbl, *newtbl;

                write_lock(&pathtbl_resize_lock);
                oldtbl = mesh_paths;
                newtbl = mesh_table_grow(mesh_paths);
                if (!newtbl) {
                        write_unlock(&pathtbl_resize_lock);
                        return 0;
                }
                rcu_assign_pointer(mesh_paths, newtbl);
                write_unlock(&pathtbl_resize_lock);

*******         synchronize_rcu();
                mesh_table_free(oldtbl, false);
        }
...
}

johannes

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

^ 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