From: Stephan Adler <stephan.adler@domain.hid>
To: xenomai@xenomai.org
Subject: [Xenomai-help] Problems with level triggered Interrupts on ARM
Date: Mon, 07 Jul 2008 13:06:43 +0200 [thread overview]
Message-ID: <4871F8C3.3030601@domain.hid> (raw)
Dear list!
I have a problem in understanding how Xenomai handles level triggered
Interrupts.
I am using an ARM AT91RM9200 with the native Xenomai (2.4.2) skin.
I try to implement the handling of a network protocol on that platform.
Therefore a network controller is used which is directly connected to
the Arm.
This network controller has one level-trigerred interrupt line. The line
is used to signal when a packet has arrived in the controller. There are
two types of messages - a control-type and a data-type. The interrupt is
shared for both packet types.
When a packet arrives the interrupt line is pulled to a low-level until
the Arm reads a certain register depending on the packet-type. A problem
occurs when - while handling a data-message - a control-message is
received by the controller. The interrupt line will stay down after the
data-packet is handled until I handle the control-message also.
Well - as I am using a level triggered interrupt I'd expect Xenomai to
jump over the rt_intr_wait() instruction until the level of the
interrupt rises again. But that actually doesn't happen. Indeed Xenomai
just counts the interrupt whenever an new edge of the interrupt signal
occurs.
I searched this list for an explanation of that behavior and found these
two messages:
https://mail.gna.org/public/xenomai-help/2006-06/msg00078.html
https://mail.gna.org/public/xenomai-help/2008-05/msg00263.html
When I understand both posts correctly, I assume the following behavior
of the Arm vs. Xenomai:
- the ARM sends an hardware interrupt to Xenomai each an etch occurs in
the signal. This should be interpreted as an "interrupt start" and
"interrupt end" event for a level triggered interrupt.
- Xenomai does not interpret both events this way, but just counts each
event as single interrupt event. - When the "interrupt end" event does
not occur an the level stays low, Xenomai will step over rt_intr_wait()
for one time - and not again - although the level triggered interrupt is
still active.
My question is now wether I understood this behavior correctly - or
wether I am doing something wrong. I could work around that problem by
myself by just counting the interrupts - but that would not be very
satisfying.
I also read that there might be some way to work around that issue by
using rt_intr_enable() - if this is the case - how to do so?
Thanks a lot
Stephan Adler
--
Stephan Adler
imc Meßsysteme GmbH
next reply other threads:[~2008-07-07 11:06 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-07 11:06 Stephan Adler [this message]
2008-07-07 12:14 ` [Xenomai-help] Problems with level triggered Interrupts on ARM 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=4871F8C3.3030601@domain.hid \
--to=stephan.adler@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.