2011-07-16 21:17:34

by Olivier Crête

[permalink] [raw]
Subject: Sometimes rtl8187 stops sending/receiving packets under load

Hello,

It's a regularly reproducible bug: under some load, like a couple
torrents running, but not enough to saturate the wireless link (and not
even enough to saturate the ADSL link on the other side), the card stops
sending or receiving any packet. Unloading and reloading the rtl8187
driver fixes the problem.

Kernel version is 2.6.38, but it also happened with older versions, and
I haven't bothered testing new ones since there are no changes in that
driver.

I get this on my dmesg:
ieee80211 phy0: wlan0: No probe response from AP 00:0f:66:e2:5f:dd after 500ms, disconnecting.
cfg80211: Calling CRDA to update world regulatory domain
wlan0: authenticate with 00:0f:66:e2:5f:dd (try 1)
wlan0: authenticate with 00:0f:66:e2:5f:dd (try 2)
wlan0: authenticate with 00:0f:66:e2:5f:dd (try 3)
wlan0: authentication with 00:0f:66:e2:5f:dd timed out

The wireless card is the one built-in a Asus P5K-E/wifi-ap motherboard.
And the router is a WRT54G v2 running the latest OpenWRT.

This bit of dmesg output may also be useful:
usb 1-3: reset high speed USB device using ehci_hcd and address 2
cfg80211: Calling CRDA to update world regulatory domain
ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
ieee80211 phy0: hwaddr 00:15:af:37:19:b3, RTL8187vB (default) V1 + rtl8225z2, rfkill mask 2


--
Olivier Cr?te
[email protected]


Attachments:
signature.asc (198.00 B)
This is a digitally signed message part

2011-07-17 06:01:05

by Andreas Hartmann

[permalink] [raw]
Subject: Re: Sometimes rtl8187 stops sending/receiving packets under load

Olivier Cr?te wrote:
> On Sat, 2011-07-16 at 18:09 -0500, Larry Finger wrote:
>> On 07/16/2011 04:17 PM, Olivier Cr?te wrote:
>>> I get this on my dmesg:
>>> ieee80211 phy0: wlan0: No probe response from AP 00:0f:66:e2:5f:dd after 500ms, disconnecting.
>>> cfg80211: Calling CRDA to update world regulatory domain
>>> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 1)
>>> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 2)
>>> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 3)
>>> wlan0: authentication with 00:0f:66:e2:5f:dd timed out
>>>
>>> The wireless card is the one built-in a Asus P5K-E/wifi-ap motherboard.
>>> And the router is a WRT54G v2 running the latest OpenWRT.
>>>
>>> This bit of dmesg output may also be useful:
>>> usb 1-3: reset high speed USB device using ehci_hcd and address 2
>>> cfg80211: Calling CRDA to update world regulatory domain
>>> ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
>>> ieee80211 phy0: hwaddr 00:15:af:37:19:b3, RTL8187vB (default) V1 + rtl8225z2, rfkill mask 2
>>
>> I have the same device as you as shown in the following:
>>
>> ieee80211 phy1: hwaddr 00:1b:2f:a2:07:ca, RTL8187vB (default) V1 + rtl8225z2,
>> rfkill mask 2
>>
>> I have run this card extensively in the past several months and have not seen
>> any problems. One of my APs is a WRT54GL running a fairly recent openWRT.
>>
>> Does this only happen when running torrents, or does it happen with a different
>> heavy load?
>
> I can only reproduce it with torrents, downloading something with a
> single TCP connection doesn't crash. So my guess it has something to do
> with the upload side maybe or maybe with loading both directions at the
> same time.
>
>> Please try to repeat with a 2.6.39 or 3.0 kernel.
>
> Alright, upgraded to 3.0-rc7 and I could still reproduce it in less than
> 10 minutes.

Do you have a SMP-machine (there are running more then one threads
parallel)? If yes, there have been problems fixed in the rt2x00 driver,
which showed similar problems as you described. I "forced" them with
netperf to get them easily reproduced. Don't know, if these patches
would address your problem, too.

https://patchwork.kernel.org/patch/951132/
https://patchwork.kernel.org/patch/951222/
https://patchwork.kernel.org/patch/951192/


Unfortunately, there are more load-related problems in the WLAN stack,
especially with hostapd / wpa_supplicant, which are just ignored by the
programmer.



Andreas

2011-07-17 05:22:37

by Olivier Crête

[permalink] [raw]
Subject: Re: Sometimes rtl8187 stops sending/receiving packets under load

On Sat, 2011-07-16 at 18:09 -0500, Larry Finger wrote:
> On 07/16/2011 04:17 PM, Olivier Cr?te wrote:
> > I get this on my dmesg:
> > ieee80211 phy0: wlan0: No probe response from AP 00:0f:66:e2:5f:dd after 500ms, disconnecting.
> > cfg80211: Calling CRDA to update world regulatory domain
> > wlan0: authenticate with 00:0f:66:e2:5f:dd (try 1)
> > wlan0: authenticate with 00:0f:66:e2:5f:dd (try 2)
> > wlan0: authenticate with 00:0f:66:e2:5f:dd (try 3)
> > wlan0: authentication with 00:0f:66:e2:5f:dd timed out
> >
> > The wireless card is the one built-in a Asus P5K-E/wifi-ap motherboard.
> > And the router is a WRT54G v2 running the latest OpenWRT.
> >
> > This bit of dmesg output may also be useful:
> > usb 1-3: reset high speed USB device using ehci_hcd and address 2
> > cfg80211: Calling CRDA to update world regulatory domain
> > ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
> > ieee80211 phy0: hwaddr 00:15:af:37:19:b3, RTL8187vB (default) V1 + rtl8225z2, rfkill mask 2
>
> I have the same device as you as shown in the following:
>
> ieee80211 phy1: hwaddr 00:1b:2f:a2:07:ca, RTL8187vB (default) V1 + rtl8225z2,
> rfkill mask 2
>
> I have run this card extensively in the past several months and have not seen
> any problems. One of my APs is a WRT54GL running a fairly recent openWRT.
>
> Does this only happen when running torrents, or does it happen with a different
> heavy load?

I can only reproduce it with torrents, downloading something with a
single TCP connection doesn't crash. So my guess it has something to do
with the upload side maybe or maybe with loading both directions at the
same time.

> Please try to repeat with a 2.6.39 or 3.0 kernel.

Alright, upgraded to 3.0-rc7 and I could still reproduce it in less than
10 minutes.

--
Olivier Cr?te
[email protected]


Attachments:
signature.asc (198.00 B)
This is a digitally signed message part

2011-07-16 23:09:16

by Larry Finger

[permalink] [raw]
Subject: Re: Sometimes rtl8187 stops sending/receiving packets under load

On 07/16/2011 04:17 PM, Olivier Cr?te wrote:
> Hello,
>
> It's a regularly reproducible bug: under some load, like a couple
> torrents running, but not enough to saturate the wireless link (and not
> even enough to saturate the ADSL link on the other side), the card stops
> sending or receiving any packet. Unloading and reloading the rtl8187
> driver fixes the problem.
>
> Kernel version is 2.6.38, but it also happened with older versions, and
> I haven't bothered testing new ones since there are no changes in that
> driver.

This assumption may not be valid as there have been a lot of changes in
mac80211, which might fix this.

> I get this on my dmesg:
> ieee80211 phy0: wlan0: No probe response from AP 00:0f:66:e2:5f:dd after 500ms, disconnecting.
> cfg80211: Calling CRDA to update world regulatory domain
> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 1)
> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 2)
> wlan0: authenticate with 00:0f:66:e2:5f:dd (try 3)
> wlan0: authentication with 00:0f:66:e2:5f:dd timed out
>
> The wireless card is the one built-in a Asus P5K-E/wifi-ap motherboard.
> And the router is a WRT54G v2 running the latest OpenWRT.
>
> This bit of dmesg output may also be useful:
> usb 1-3: reset high speed USB device using ehci_hcd and address 2
> cfg80211: Calling CRDA to update world regulatory domain
> ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
> ieee80211 phy0: hwaddr 00:15:af:37:19:b3, RTL8187vB (default) V1 + rtl8225z2, rfkill mask 2

I have the same device as you as shown in the following:

ieee80211 phy1: hwaddr 00:1b:2f:a2:07:ca, RTL8187vB (default) V1 + rtl8225z2,
rfkill mask 2

I have run this card extensively in the past several months and have not seen
any problems. One of my APs is a WRT54GL running a fairly recent openWRT.

Does this only happen when running torrents, or does it happen with a different
heavy load?

Please try to repeat with a 2.6.39 or 3.0 kernel.

Larry

2011-10-02 16:34:38

by Larry Finger

[permalink] [raw]
Subject: Re: Sometimes rtl8187 stops sending/receiving packets under load

On 10/02/2011 03:32 AM, Olivier Cr?te wrote:
>
> I've also noticed that just before it all goes horribly wrong, I start
> missing events from my USB HID mouse.. Maybe its a usb host controller
> bug or something.. hard to debug.

That will indeed be hard to debug.

Larry


2011-10-02 08:32:50

by Olivier Crête

[permalink] [raw]
Subject: Re: Sometimes rtl8187 stops sending/receiving packets under load

On Fri, 2011-09-02 at 12:01 -0400, Olivier Cr?te wrote:
> Hi,
>
> On Fri, 2011-08-19 at 22:18 -0500, Larry Finger wrote:
> > I have 3 different devices that use either the RTL8187L or RTL8187B chips and
> > the rtl8187 driver. None of them have any problems of the type you describe,
> > thus you may have either a screwy AP, or excessive interference. Have you tried
> > changing the channel to another of the set of 1, 6, 11, or have you tried with a
> > different AP?
>
> I tried with a different AP (some DLink with the stock firmware) instead
> of the WRT54Gv2 and the driver also fails after a while... Seems like an
> annoying issue to debug.. I'm tempted to believe that maybe it's an
> hardware issue maybe, I should do some stress testing in Windows maybe.

I've also noticed that just before it all goes horribly wrong, I start
missing events from my USB HID mouse.. Maybe its a usb host controller
bug or something.. hard to debug.


--
Olivier Cr?te
[email protected]


Attachments:
signature.asc (198.00 B)
This is a digitally signed message part