Skip to contentSkip to conversation

ath9k performance issues

ath9k-devel Bernhard Walle 5 participants 15 messages Apr 5, 2011

lore
Share & tools
lore
#0 lore raw

Hello,

we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system that does the transmission has a high CPU utilization:

iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a high softirq proportion.

Using an Intel card (5300) has a lower CPU utilization (~60 %), but it's no option to use it because the Linux driver has no access point mode.

Are there any tweaks to decrease the CPU utilization with the ath9k driver? Any recommendations for the application to send the network packets more efficient?

Regards,
Bernhard

#1 lore raw
Quoted 8 lines · Bernhard Walle

Hello,

we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system that does the transmission has a high CPU utilization:

iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a high softirq proportion.

Quoted 6 lines

Using an Intel card (5300) has a lower CPU utilization (~60 %), but it's no option to use it because the Linux driver has no access point mode.

Are there any tweaks to decrease the CPU utilization with the ath9k driver? Any recommendations for the application to send the network packets more efficient?

What kernel version are you using? Are you using the in-kernel ath9k or are you using compat-wireless? I have added quite a few performance optimizations over time, as I'm working with much slower MIPS CPUs than the octeon.
In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around 90 mbit/s of traffic with only around 70% CPU utilization.

- Felix

#2 lore raw

--- On Tue, 4/5/11, Felix Fietkau <[email protected]> wrote:

From: Felix Fietkau <[email protected]>
Subject: Re: [ath9k-devel] ath9k performance issues
To: "Bernhard Walle" <[email protected]>
Cc: ath9k-devel at lists.ath9k.org
Date: Tuesday, April 5, 2011, 9:29 PM

Quoted 8 lines · Bernhard Walle

Hello,

we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system that does the transmission has a high CPU utilization:

iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a high softirq proportion.

Quoted 6 lines

Using an Intel card (5300) has a lower CPU utilization (~60 %), but it's no option to use it because the Linux driver has no access point mode.

Are there any tweaks to decrease the CPU utilization with the ath9k driver? Any recommendations for the application to send the network packets more efficient?

What kernel version are you using? Are you using the in-kernel ath9k or are you using compat-wireless? I have added quite a few performance optimizations over time, as I'm working with much slower MIPS CPUs than the octeon.
In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around 90 mbit/s of traffic with only around 70% CPU utilization.

- Felix

Now thats interesting Felix :) , how have you managed to get all these?

--SGS

_______________________________________________
ath9k-devel mailing list
ath9k-devel at lists.ath9k.org
https://lists.ath9k.org/mailman/listinfo/ath9k-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20110405/eb912110/attachment.htm

#3 lore raw
Quoted 31 lines · Serene Gud

--- On *Tue, 4/5/11, Felix Fietkau /<[email protected]>/* wrote:
From: Felix Fietkau <[email protected]>
Subject: Re: [ath9k-devel] ath9k performance issues
To: "Bernhard Walle" <[email protected]>
Cc: ath9k-devel at lists.ath9k.org
Date: Tuesday, April 5, 2011, 9:29 PM

On 2011-04-05 5:44 PM, Bernhard Walle wrote:
> Hello,
>
> we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system > that does the transmission has a high CPU utilization:
>
> iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a > high softirq proportion.
>
> Using an Intel card (5300) has a lower CPU utilization (~60 %),
but it's
> no option to use it because the Linux driver has no access point
mode.
>
> Are there any tweaks to decrease the CPU utilization with the ath9k > driver? Any recommendations for the application to send the network > packets more efficient?
What kernel version are you using? Are you using the in-kernel ath9k or are you using compat-wireless? I have added quite a few performance optimizations over time, as I'm working with much slower MIPS CPUs than the octeon.
In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around 90 mbit/s of traffic with only around 70% CPU utilization.

Quoted 4 lines

- Felix

Now thats interesting Felix :) , how have you managed to get all these?

What do you mean with 'get all these'?

- Felix

#4 lore raw
Quoted 25 lines · Serene Gud

? ???On 2011-04-05 5:44 PM, Bernhard Walle wrote:
? ? ? > Hello,
? ? ? >
? ? ? > we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system ? ? ? > that does the transmission has a high CPU utilization:
? ? ? >
? ? ? > iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a ? ? ? > high softirq proportion.
? ? ? >
? ? ? > Using an Intel card (5300) has a lower CPU utilization (~60 %), ? ???but it's
? ? ? > no option to use it because the Linux driver has no access point ? ???mode.
? ? ? >
? ? ? > Are there any tweaks to decrease the CPU utilization with the ath9k ? ? ? > driver? Any recommendations for the application to send the network ? ? ? > packets more efficient?
? ???What kernel version are you using? Are you using the in-kernel ath9k or ? ???are you using compat-wireless? I have added quite a few performance ? ???optimizations over time, as I'm working with much slower MIPS CPUs than ? ???the octeon.
? ???In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around ? ???90 mbit/s of traffic with only around 70% CPU utilization.

Quoted 4 lines

? ???- Felix

? ???Now thats interesting Felix :) , how have you managed to get all these?

What do you mean with 'get all these'?

- Felix

Sorry, I am new to these things; what I wanted to ask you was that with the kind of CPU info that you have; how were you able to get 90 mbit/s of traffic. I am using a much faster CPU with 1.66 Ghz 512K still I usually get 65mbit/s. I am using in-kernel ath9K. Are you using compat-wireless? Are there any other changes that you have made to your system? I have no idea if we can make the tx bitrate stable? If you have done that, kindly share.

Thanks!
SGS

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20110405/980d21a1/attachment-0001.htm

#5 lore raw
Quoted 43 lines · Serene Gud

On 2011-04-05 6:03 PM, Serene Gud wrote:

>
> On 2011-04-05 5:44 PM, Bernhard Walle wrote:
> > Hello,
> >
> > we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system > > that does the transmission has a high CPU utilization:
> >
> > iperf in UDP mode with 50M bandwith has ~90 % CPU utilization
with a
> > high softirq proportion.
> >
> > Using an Intel card (5300) has a lower CPU utilization (~60 %), > but it's
> > no option to use it because the Linux driver has no access point > mode.
> >
> > Are there any tweaks to decrease the CPU utilization with the ath9k > > driver? Any recommendations for the application to send the network > > packets more efficient?
> What kernel version are you using? Are you using the in-kernel
ath9k or
> are you using compat-wireless? I have added quite a few performance > optimizations over time, as I'm working with much slower MIPS
CPUs than
> the octeon.
> In my tests, a 300 MHz MIPS 24K CPU is good enough for handling
around
> 90 mbit/s of traffic with only around 70% CPU utilization. >
> - Felix
>
>
> Now thats interesting Felix :) , how have you managed to get all
these?
What do you mean with 'get all these'?

- Felix

Quoted 6 lines

Sorry, I am new to these things; what I wanted to ask you was that with the kind of CPU info that you have; how were you able to get 90 mbit/s of traffic. I am using a much faster CPU with 1.66 Ghz 512K still I usually get 65mbit/s. I am using in-kernel ath9K. Are you using compat-wireless? Are there any other changes that you have made to your system?

The device I used was using an AR7130 MIPS CPU. I set it up as an access point (with 4addr/wds mode enabled), then used another device as a 4-addr client. Both were set up for bridging wireless to wired. After that I ran iperf TCP sessions between two laptops (each connected to one of the embedded devices).

Quoted 2 lines

I have no idea if we can make the tx bitrate stable? If you have done that, kindly share.

Are you using the ath9k rate control or are you using minstrel_ht? My tests were done with minstrel_ht. You can enable it by disabling the config option for the ath9k rate control.

- Felix

#6 lore raw

--- On Tue, 4/5/11, Felix Fietkau <[email protected]> wrote:

Quoted 43 lines · Serene Gud

? ???On 2011-04-05 6:03 PM, Serene Gud wrote:

? ? ? >
? ? ? > On 2011-04-05 5:44 PM, Bernhard Walle wrote:
? ? ? > > Hello,
? ? ? > >
? ? ? > > we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system ? ? ? > > that does the transmission has a high CPU utilization:
? ? ? > >
? ? ? > > iperf in UDP mode with 50M bandwith has ~90 % CPU utilization ? ???with a
? ? ? > > high softirq proportion.
? ? ? > >
? ? ? > > Using an Intel card (5300) has a lower CPU utilization (~60 %), ? ? ? > but it's
? ? ? > > no option to use it because the Linux driver has no access point ? ? ? > mode.
? ? ? > >
? ? ? > > Are there any tweaks to decrease the CPU utilization with the ath9k ? ? ? > > driver? Any recommendations for the application to send the network ? ? ? > > packets more efficient?
? ? ? > What kernel version are you using? Are you using the in-kernel ? ???ath9k or
? ? ? > are you using compat-wireless? I have added quite a few performance ? ? ? > optimizations over time, as I'm working with much slower MIPS ? ???CPUs than
? ? ? > the octeon.
? ? ? > In my tests, a 300 MHz MIPS 24K CPU is good enough for handling ? ???around
? ? ? > 90 mbit/s of traffic with only around 70% CPU utilization. ? ? ? >
? ? ? > - Felix
? ? ? >
? ? ? >
? ? ? > Now thats interesting Felix :) , how have you managed to get all ? ???these?
? ???What do you mean with 'get all these'?

? ???- Felix

Quoted 6 lines

? ???Sorry, I am new to these things; what I wanted to ask you was that ? ???with the kind of CPU info that you have; how were you able to get 90 ? ???mbit/s of traffic. I am using a much faster CPU with 1.66 Ghz 512K ? ???still I usually get 65mbit/s. I am using in-kernel ath9K. Are you ? ???using compat-wireless? Are there any other changes that you have ? ???made to your system?

The device I used was using an AR7130 MIPS CPU. I set it up as an access point (with 4addr/wds mode enabled), then used another device as a 4-addr client. Both were set up for bridging wireless to wired. After that I ran iperf TCP sessions between two laptops (each connected to one of the embedded devices).

Thanks Felix. I set up an Access point with master mode enables (with the help of hostapd).

Quoted 2 lines

? ???I have no idea if we can make the tx bitrate stable? If you have ? ???done that, kindly share.

Are you using the ath9k rate control or are you using minstrel_ht? My tests were done with minstrel_ht. You can enable it by disabling the config option for the ath9k rate control.

My client had an intel card which uses it own rate control so I am using a USB wireless card now which uses minstrel but my Access point on the other hand uses ath9k_rate_control. I guess I should make them both use the same rate control algo.

--SGS

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20110405/003ee767/attachment.htm

#7 lore raw
In reply to Felix Fietkau
Quoted 5 lines

Are you using the ath9k rate control or are you using minstrel_ht? My tests were done with minstrel_ht. You can enable it by disabling the config option for the ath9k rate control.

- Felix

This is interesting. I have a problem with rate control (I guess) too. Can you give me a clue on how to disable rate control for ath9k? What is a config option for ath9k? Where is it? Can I disable it by writing some value into /sys or maybe it's possible via modprobe ath9k --some_params?

Thanks.

#8 lore raw
Quoted 11 lines · Kucherenko Valeriy
Quoted 5 lines

Are you using the ath9k rate control or are you using minstrel_ht? My tests were done with minstrel_ht. You can enable it by disabling the config option for the ath9k rate control.

- Felix

This is interesting. I have a problem with rate control (I guess) too. Can you give me a clue on how to disable rate control for ath9k? What is a config option for ath9k? Where is it? Can I disable it by writing some value into /sys or maybe it's possible via modprobe ath9k --some_params?

In the kernel tree (.config) and in compat-wireless (config.mk) it's the option CONFIG_ATH9K_RATE_CONTROL.

- Felix

#9 lore raw
Quoted 4 lines · Felix Fietkau
Quoted 3 lines · Kucherenko Valeriy
Quoted 3 lines

?Are you using the ath9k rate control or are you using minstrel_ht? My ?tests were done with minstrel_ht. You can enable it by disabling the ?config option for the ath9k rate control.

HTH; if not, please excuse the waste of time; this is from stock r26460 on Ubiquiti M900 and Loco M900:

root at OpenWrt:~# iw wlan0 station dump
Station 00:15:6d:9c:16:df (on wlan0)

        inactive time:  840 ms
        rx bytes:       628
        rx packets:     22
        tx bytes:       560
        tx packets:     11
        tx retries:     65
        tx failed:      7
        signal:         -97 dBm
        signal avg:     -96 dBm
        tx bitrate:     104.0 MBit/s MCS 13
        rx bitrate:     6.5 MBit/s MCS 0

best regards/ldv

Signature · 4 lines
Larry Vaden, CoFounder
Internet Texoma, Inc.
Serving Rural Texomaland Since 1995
We Care About Your Connection!
#10 lore raw

Again, HTH: this is from a Bullet M2 running stock r26358:

Station 00:15:6d:f0:47:dd (on wlan0)

        inactive time:  44790 ms
        rx bytes:       10380739
        rx packets:     55088
        tx bytes:       96278984
        tx packets:     81367
        tx retries:     51061
        tx failed:      0
        signal:         -79 dBm
        signal avg:     -78 dBm
        tx bitrate:     48.0 MBit/s
        rx bitrate:     9.0 MBit/s

best regards/ldv

Signature · 4 lines
Larry Vaden, CoFounder
Internet Texoma, Inc.
Serving Rural Texomaland Since 1995
We Care About Your Connection!
#11 lore raw
In reply to Felix Fietkau

Hello Felix,

Quoted 8 lines · Felix Fietkau
Quoted 7 lines · Bernhard Walle

we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system that does the transmission has a high CPU utilization:

iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a high softirq proportion.

Quoted 8 lines
Quoted 6 lines

Using an Intel card (5300) has a lower CPU utilization (~60 %), but it's no option to use it because the Linux driver has no access point mode.

Are there any tweaks to decrease the CPU utilization with the ath9k driver? Any recommendations for the application to send the network packets more efficient?

What kernel version are you using? Are you using the in-kernel ath9k or are you using compat-wireless? I have added quite a few

I'm using 2.6.38.1 ath9k which is at ~80 % CPU, starting from 2.6.37.1 with ~90 % CPU which was still an improvement. Do you think that compat-wireless gives still a performance boost?

Quoted 5 lines

Which
performance optimizations over time, as I'm working with much slower MIPS CPUs than the octeon.
In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around 90 mbit/s of traffic with only around 70% CPU utilization.

That sounds interesting. Any other optimisations other than using compat-wireless?

Regards,
Bernhard

#12 lore raw
Quoted 20 lines · Bernhard Walle

Hello Felix,

Quoted 8 lines · Felix Fietkau
Quoted 7 lines · Bernhard Walle

we're using a PCIe AR9280 card on a Octeon MIPS CPU. The system that does the transmission has a high CPU utilization:

iperf in UDP mode with 50M bandwith has ~90 % CPU utilization with a high softirq proportion.

Quoted 8 lines
Quoted 6 lines

Using an Intel card (5300) has a lower CPU utilization (~60 %), but it's no option to use it because the Linux driver has no access point mode.

Are there any tweaks to decrease the CPU utilization with the ath9k driver? Any recommendations for the application to send the network packets more efficient?

What kernel version are you using? Are you using the in-kernel ath9k or are you using compat-wireless? I have added quite a few

Quoted 3 lines

I'm using 2.6.38.1 ath9k which is at ~80 % CPU, starting from 2.6.37.1 with ~90 % CPU which was still an improvement. Do you think that compat-wireless gives still a performance boost?

Not sure. These numbers sound awfully high to me. Maybe you should do some profiling to figure out what's using all this CPU time.

Quoted 8 lines
Quoted 5 lines

Which
performance optimizations over time, as I'm working with much slower MIPS CPUs than the octeon.
In my tests, a 300 MHz MIPS 24K CPU is good enough for handling around 90 mbit/s of traffic with only around 70% CPU utilization.

That sounds interesting. Any other optimisations other than using compat-wireless?

No. I've pushed all of my enhancements upstream.

- Felix

#13 lore raw
Quoted 6 lines · Felix Fietkau
Quoted 4 lines

I'm using 2.6.38.1 ath9k which is at ~80 % CPU, starting from 2.6.37.1 with ~90 % CPU which was still an improvement. Do you think that compat-wireless gives still a performance boost?

Not sure. These numbers sound awfully high to me. Maybe you should do some profiling to figure out what's using all this CPU time.

Just to make sure: my Octeon runs at 300 MHz. Do you think that numbers are too much? Userspace profiling showed that the CPU goes to sendto(), of course. Which profiling method do you recommend for MIPS -- oprofile?

Regards,
Bernhard

#14 lore raw
Quoted 11 lines · Bernhard Walle
Quoted 6 lines · Felix Fietkau
Quoted 4 lines

I'm using 2.6.38.1 ath9k which is at ~80 % CPU, starting from 2.6.37.1 with ~90 % CPU which was still an improvement. Do you think that compat-wireless gives still a performance boost?

Not sure. These numbers sound awfully high to me. Maybe you should do some profiling to figure out what's using all this CPU time.

Just to make sure: my Octeon runs at 300 MHz. Do you think that numbers are too much? Userspace profiling showed that the CPU goes to sendto(), of course. Which profiling method do you recommend for MIPS -- oprofile?

Yes, I was using oprofile when I was working on improving ath9k performance.

- Felix