All of lore.kernel.org
 help / color / mirror / Atom feed
From: James Kilts <jameskilts@domain.hid>
To: xenomai@xenomai.org
Subject: Re: [Xenomai-help] Interrupt only runs once
Date: Thu, 24 Sep 2009 13:46:32 -0500	[thread overview]
Message-ID: <9aa019ba0909241146y9a97988m8aca04540e2289a1@domain.hid> (raw)
In-Reply-To: <4AB2A308.4010508@domain.hid>

> you should really upgrade to 2.4.9.1.

I'm now running Xenomai 2.4.9.1 on Linux 2.6.28.9.


>>> I had a look at handle_prio_irq in arch/arm/mach-ns9xxx/irq.c. What
>>> this irq handler does is bad, really bad. If you care about interrupt
>>> latencies, you should really use handle_level_irq. That is, replace the
>>> #if 0 with a #if 1.

Interrupt latency in the Linux kernel is not important to me, but
Xenomai interrupt latency is critical.  Just for the fun of it, I
tried switching to handle_level_irq() and then adding an irq_finish()
function similar to the AT91, but Linux locks up during the boot
sequence while initializing the Ethernet stack.  The timing of ACK/EOI
on this chip is sensitive.

Currently the problem is that a Xenomai ISR on this system needs to
respond to interrupts consistently under 50 microseconds.  When the
system is running idle or when running "dd if=/dev/zero of=/dev/zero",
it's able to respond to an IRQ trigger by toggling a GPIO within 35
microseconds.  But if I run "top" and then flood the serial input
buffer with carriage returns (holding down the enter key) the oscope
occasionally shows a large delay, in about 1 out of every 30 ISR calls
the GPIO toggles late on the order of 100-300 microseconds.  The
timing is worse when I flood the system with pings, upwards of 3
milliseconds to respond, although the majority remain under 35
microseconds.

These tests have been run using a LeCroy 1 GHz Oscilloscope.

I've been through the Troubleshooting and verified that all power
management, frequency modulation, etc. are disabled.  The serial port
driver does not appear to be masking the interrupts.  Any ideas as to
what could be causing these delays?


Thanks for your help.

- James


  reply	other threads:[~2009-09-24 18:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-15 15:27 [Xenomai-help] Interrupt only runs once James Kilts
2009-09-16 15:47 ` Philippe Gerum
2009-09-17 17:26   ` James Kilts
2009-09-17 17:31     ` Gilles Chanteperdrix
2009-09-17 17:39     ` Gilles Chanteperdrix
2009-09-17 20:45       ` James Kilts
2009-09-17 20:58         ` Gilles Chanteperdrix
2009-09-24 18:46           ` James Kilts [this message]
2009-09-24 18:58             ` Gilles Chanteperdrix

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9aa019ba0909241146y9a97988m8aca04540e2289a1@domain.hid \
    --to=jameskilts@domain.hid \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.