Re: ath / 802.11n performance issues and timer code

From: Alexander Motin <mav_at_FreeBSD.org>
Date: Sat, 24 Sep 2011 00:38:10 +0300
On 23.09.2011 18:29, Adrian Chadd wrote:
> I've been looking at issues with 802.11n RX performance on these
> MIPS24k based MIPS boards.
> After doing a bit of digging, I discovered what looked like strange
> scheduler issues where the RX and TX completion schedulers weren't
> being invoked quickly.
> The ath driver schedules these functions using taskqueues.
> 
> Here's the time keeper configuration for my mips24k board:
> 
> # sysctl kern.eventtimer
> kern.eventtimer.choice: MIPS32(800)
> kern.eventtimer.et.MIPS32.flags: 7
> kern.eventtimer.et.MIPS32.frequency: 360000000
> kern.eventtimer.et.MIPS32.quality: 800
> kern.eventtimer.periodic: 1
> kern.eventtimer.timer: MIPS32
> kern.eventtimer.idletick: 0
> kern.eventtimer.singlemul: 2
> 
> When I set kern.eventtimer.periodic=1, the 11n TX/RX performance
> suddenly jumps to where it should be.
> 
> Would you mind helping me figure out what the problem is? 

I would be glad to help, but at this moment I am not sure how network
traffic related to timer. May be wireless has some specifics, but for
wired adapters traffic processing happens on network interrupts.

> I didn't think kern.eventtimer.periodic was needed?

It should not be needed.

Have you tried to set kern.eventtimer.idletick=1 instead?
kern.eventtimer.periodic=1 on UP system effectively includes
kern.eventtimer.idletick=1. kern.eventtimer.idletick=0 may somewhat
increase interrupts overhead due to need to reprogram timer before
context switch, but under high interrupt rate (about few KHz) kernel
should dynamically switch to "quick" mode skipping it.

-- 
Alexander Motin
Received on Fri Sep 23 2011 - 19:44:08 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:18 UTC