Re: ath / 802.11n performance issues and timer code

From: Adrian Chadd <adrian_at_freebsd.org>
Date: Tue, 27 Sep 2011 11:18:45 +0800
Hi John/Alex.

The AR71xx MIPS kernels didn't include PREEMPTION. This seems a bit
silly, as it's needed by sched_4bsd to actually compile in the code in
maybe_preempt().
So I added it, and it simply increased CPU use without fixing the
issue. But yes, maybe_preempt() is now setting td_owepreempt.

This however doesn't fix it.

I have a gem of a trace here:
http://people.freebsd.org/~adrian/ath/ktr.7.sorted.txt .

I've added some ath interrupt and RX tasklet trace points. Look for
RXEOL and work your way backwards.

The course of events:

* 2128: switch to idle
* 2130: ath0 intr comes in
* 2132/2133: put on runq, wakeup ath0 netisr
* 2134: maybe_preempt gets called, so hopefully td_owepreempt is going on
* 2136: "skip" in kern_clocksource.c
* 2139: the clock0 interrupt comes in - the latency between 2138 and
2139 is huge (70ms?)

At this point it schedules clock0 swi, where 11 statclock entries get
recorded. Then it calls my ath netisr routine, but by this point RXEOL
(end of RX descriptor list) has occured.

Now, there was an ath0 interrupt just before this. Is it possible that
two quick successive ath0 interrupts are triggering some strange
behaviour?



Adrian
Received on Tue Sep 27 2011 - 01:18:46 UTC

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