2008-01-05 15:18:48

by Hauke Mehrtens

[permalink] [raw]
Subject: rtl8187 rate control doesn't work

Hi

Now the compat-wireless-2.6 package is working and I get an Internet
connection with my rtl8187 based card. (It's on an ASUS P5B Deluxe)

I used the compat-wireless-2.6 package for this log, but I have the same
problem with the version integrated in kernel 2.6.24-rc6

The Access Point is some rooms away so the signal is not the best at my
location. When starting the device with no fixed rate it wants to
connect with 54MBit/s and as iwconfig says it was successful but I can't
ping any device in the wireless LAN. (it's the first part of the log)
The rate will not be slowed down it stays fixed at 54MBit/s.

After starting the device with rate fixed to 11M I get a connection to
the Access Point and iwconfig's output looks the same as without fixed
rate, but I'm able to ping the all devices in the network. (second part
of the log)
Now it slows down the rate to 1MBit/s

iwconfig looks like this (fixed rate to 11M):
wlan0 IEEE 802.11g ESSID:"mehrtenswlan"
Mode:Managed Frequency:2.412 GHz Access Point: 00:1A:XX:XX:XX:XX
Bit Rate=1 Mb/s Tx-Power=27 dBm
Retry min limit:7 RTS thr:off Fragment thr=2352 B
Link Quality=50/64 Signal level=16/65
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0

With no fixed rate there is an Bit Rate=54 Mb/s instead of 1Mb/s.


With rate fixed to 18MBit/s I have the same problem as with no fixed rate.

dmesg log:

phy0: Selected rate control algorithm 'pid'
phy0: hwaddr 00:15:af:03:ab:79, rtl8187 V1 + rtl8225z2
usbcore: registered new interface driver rtl8187

wlan0: Initial auth_alg=0
wlan0: authenticate with AP 00:1a:92:ea:73:12
wlan0: authenticate with AP 00:1a:92:ea:73:12
wlan0: authenticate with AP 00:1a:92:ea:73:12
wlan0: authentication with AP 00:1a:92:ea:73:12 timed out

wlan0: Initial auth_alg=0
wlan0: authenticate with AP 00:1a:92:ea:73:12
wlan0: RX authentication from 00:1a:92:ea:73:12 (alg=0 transaction=2
status=0)
wlan0: authenticated
wlan0: associate with AP 00:1a:92:ea:73:12
wlan0: RX AssocResp from 00:1a:92:ea:73:12 (capab=0x411 status=0 aid=1)
wlan0: associated
wlan0: switched to short barker preamble (BSSID=00:1a:92:ea:73:12)
ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready

>>restarting connection with fixed rate 11M

wlan0: deauthenticate(reason=3)
ADDRCONF(NETDEV_UP): wlan0: link is not ready

wlan0: Initial auth_alg=0
wlan0: authenticate with AP 00:1a:92:ea:73:12
wlan0: RX authentication from 00:1a:92:ea:73:12 (alg=0 transaction=2
status=0)
wlan0: authenticated
wlan0: associate with AP 00:1a:92:ea:73:12
wlan0: RX AssocResp from 00:1a:92:ea:73:12 (capab=0x411 status=0 aid=1)
wlan0: associated
wlan0: switched to short barker preamble (BSSID=00:1a:92:ea:73:12)
ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
wlan0: no IPv6 routers present

--

Hauke Mehrtens


2008-01-05 21:54:40

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

On Jan 5, 2008 9:47 AM, Hauke Mehrtens <[email protected]> wrote:
> Hi
>
> Now the compat-wireless-2.6 package is working and I get an Internet
> connection with my rtl8187 based card. (It's on an ASUS P5B Deluxe)
>
> I used the compat-wireless-2.6 package for this log, but I have the same
> problem with the version integrated in kernel 2.6.24-rc6
>
> The Access Point is some rooms away so the signal is not the best at my
> location. When starting the device with no fixed rate it wants to
> connect with 54MBit/s and as iwconfig says it was successful but I can't
> ping any device in the wireless LAN. (it's the first part of the log)
> The rate will not be slowed down it stays fixed at 54MBit/s.
>
> After starting the device with rate fixed to 11M I get a connection to
> the Access Point and iwconfig's output looks the same as without fixed
> rate, but I'm able to ping the all devices in the network. (second part
> of the log)
> Now it slows down the rate to 1MBit/s

Seems to be the new PID rate control algorithm. I believe Stephano
(CC'd) was sending some patches for this. Please try changing in
config.mk

>From this value:

CONFIG_MAC80211_RC_DEFAULT=pid

To this:

CONFIG_MAC80211_RC_DEFAULT=simple

and let us know how that goes. Oh and linux-kernel is the wrong list
to use, please just use linux-wireless for future e-mails.

Luis

2008-01-07 16:03:19

by Hauke Mehrtens

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

There is an other Problem.

iwconfig shows me "Bit Rate=1 Mb/s" the hole time, but I'm able to
download with an average of 440K/s as wget says.

It's with PID rate control algorithm.

--

Hauke Mehrtens

Luis R. Rodriguez wrote:
> On Jan 5, 2008 9:47 AM, Hauke Mehrtens <[email protected]> wrote:
>> Hi
>>
>> Now the compat-wireless-2.6 package is working and I get an Internet
>> connection with my rtl8187 based card. (It's on an ASUS P5B Deluxe)
>>
>> I used the compat-wireless-2.6 package for this log, but I have the same
>> problem with the version integrated in kernel 2.6.24-rc6
>>
>> The Access Point is some rooms away so the signal is not the best at my
>> location. When starting the device with no fixed rate it wants to
>> connect with 54MBit/s and as iwconfig says it was successful but I can't
>> ping any device in the wireless LAN. (it's the first part of the log)
>> The rate will not be slowed down it stays fixed at 54MBit/s.
>>
>> After starting the device with rate fixed to 11M I get a connection to
>> the Access Point and iwconfig's output looks the same as without fixed
>> rate, but I'm able to ping the all devices in the network. (second part
>> of the log)
>> Now it slows down the rate to 1MBit/s
>
> Seems to be the new PID rate control algorithm. I believe Stephano
> (CC'd) was sending some patches for this. Please try changing in
> config.mk
>
> From this value:
>
> CONFIG_MAC80211_RC_DEFAULT=pid
>
> To this:
>
> CONFIG_MAC80211_RC_DEFAULT=simple
>
> and let us know how that goes. Oh and linux-kernel is the wrong list
> to use, please just use linux-wireless for future e-mails.
>
> Luis

2008-01-07 17:42:24

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

On Jan 7, 2008 11:02 AM, Hauke Mehrtens <[email protected]> wrote:
> There is an other Problem.
>
> iwconfig shows me "Bit Rate=1 Mb/s" the hole time, but I'm able to
> download with an average of 440K/s as wget says.
>
> It's with PID rate control algorithm.

Thanks for reporting this, how'd it go with simple rate control
algorithm instead?

Luis

2008-01-11 22:40:38

by Hauke Mehrtens

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

Luis R. Rodriguez wrote:
> On Jan 7, 2008 11:02 AM, Hauke Mehrtens <[email protected]> wrote:
>
> Thanks for reporting this, how'd it go with simple rate control
> algorithm instead?

How do I change from pid to simple rate control algorithm? I have tried
to set the CONFIG_MAC80211_RC_DEFAULT variable but it doesn't change the
dmesg output. On kernel 2.6.22 simple rate control algorithm is used as
default but on 2.6.24 pid is the default on.

Can you please send me a config.mk

On kernel 2.4.24 with pid the rate shown by iwconfig stays at the
starting on, also if I change it with "sudo iwconfig wlan0 rate 11M", on
kernel 2.6.22 with simple rate control algorithm it shows the right rate.

If I change the rate to something smaller than 11M I am able to ping the
Access Point and if it is bigger that 11M I can't ping it. If no fixed
rate is entered it stays at 54MBit/s and I can't ping the AP. The
network speed is at ~1MBit/s and "Link Quality=53/64 Signal level=25/65"

I have a AMD64 System and I am using the compat-wireless-2.6 of today.

Hauke Mehrtens

2008-01-12 14:44:49

by Hauke Mehrtens

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

I have tested kernel 2.6.24-rc7-git4 with the build in rtl8187 module
and I have the same problem.

I can't ping the AP if the rate is set to auto or to something higher
than 11M. I have to set it to something less than 11M to be able to ping
the AP.

iwconfig shows a successful connection in both cases.

I am using Ubuntu 7.10 with vanilla kernel 2.6.24-rc7-git4 on AMD64
system with wpa_supplicant v0.5.8

--
Hauke

2008-01-12 15:26:11

by Stefano Brivio

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

On Sat, 12 Jan 2008 15:44:30 +0100
Hauke Mehrtens <[email protected]> wrote:

> I have tested kernel 2.6.24-rc7-git4 with the build in rtl8187 module
> and I have the same problem.

Could you please try the wireless-2.6 kernel tree? I think it's fixed
there. Details on how to download that can be found here:
http://linuxwireless.org/en/developers/Documentation/git-guide


--
Ciao
Stefano

2008-01-12 18:24:17

by Hauke Mehrtens

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

I have tried wireless-2.6 and I have the same problem. If the rate goes
over 11M no TCP/IP traffic goes through the wireless connecting. If rate
is set to auto and the rate control algorithm changes it to something
less than 11M TCP/IP traffic goes through, but if it is more than 11M no
TCP/IP traffic goes through the wireless link.

with "iwconfig wlan0 rate 11M" everything works.

--
Hauke Mehrtens

Stefano Brivio wrote:
> On Sat, 12 Jan 2008 15:44:30 +0100
> Hauke Mehrtens <[email protected]> wrote:
>
>> I have tested kernel 2.6.24-rc7-git4 with the build in rtl8187 module
>> and I have the same problem.
>
> Could you please try the wireless-2.6 kernel tree? I think it's fixed
> there. Details on how to download that can be found here:
> http://linuxwireless.org/en/developers/Documentation/git-guide
>
>
> --
> Ciao
> Stefano
> -
> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html

2008-01-12 19:33:45

by Stefano Brivio

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

On Sat, 12 Jan 2008 19:23:53 +0100
Hauke Mehrtens <[email protected]> wrote:

> I have tried wireless-2.6 and I have the same problem. If the rate goes
> over 11M no TCP/IP traffic goes through the wireless connecting. If rate
> is set to auto and the rate control algorithm changes it to something
> less than 11M TCP/IP traffic goes through, but if it is more than 11M no
> TCP/IP traffic goes through the wireless link.

And this is a problem if the rate control algorithm often sets the rate to
more than 11M even if connection is unreliable at that rate. Does this
actually happen? Are you currently using 'pid'?

Also, it would be fine to have a dump of the PID events. In order to get
this, you need to:
- build a kernel with debugfs enabled;
- mount debugfs (mount -t debugfs foo /mnt/debug)

Then, before testing:
cat /mnt/debug/ieee80211/phy0/stations/*/rc_pid_events > events_dump

You can even make a graph out of that, with a python script which Mattias
posted on this list some time ago, but a dump would be just fine.


--
Ciao
Stefano

2008-01-14 19:26:58

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: rtl8187 rate control doesn't work

On Jan 11, 2008 5:39 PM, Hauke Mehrtens <[email protected]> wrote:
> Luis R. Rodriguez wrote:
> > On Jan 7, 2008 11:02 AM, Hauke Mehrtens <[email protected]> wrote:
> >
> > Thanks for reporting this, how'd it go with simple rate control
> > algorithm instead?
>
> How do I change from pid to simple rate control algorithm?

In config.mk replace this line:

CONFIG_MAC80211_RC_DEFAULT=pid

with:

CONFIG_MAC80211_RC_DEFAULT=simple

although I am planning on changing the config stuff soon.

Luis