All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@domain.hid>
To: Sean McGranaghan <smm@domain.hid>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-help] Low-level isr in ADEOS/RTDM
Date: Thu, 07 Sep 2006 22:33:31 +0200	[thread overview]
Message-ID: <4500821B.8040703@domain.hid> (raw)
In-Reply-To: <45007B5B.9010000@domain.hid>

[-- Attachment #1: Type: text/plain, Size: 2941 bytes --]

Sean McGranaghan wrote:
> Hello all,
> 
> I am having an issue with a "lost" interrupt in an RTDM driver. This is a long 
> story so I will try to summarize:
> 
> Hardware description -
> I have a Geode2 based PC/104 stack with CAN and ADC/DAC cards. The motherboard 
> implements a standard XT-PIC in its super io. The system is running Xenomai 
> 2.2.1 with a Gentoo  Linux 2.6.17 kernel. There are several external devices on 
> the CAN bus to load the bus with traffic.
> 
> Software description -
> I have two RTDM drivers that provide simple ioctl() interfaces to the 
> application. One driver supports two CAN controllers. (PCAN/SJA1000. I 
> implemented this driver many months before RTCAN was available. Sorry I couldn't 
> wait, paying customer and all. ;-)

Yeah. :)

> The other driver supports a ADC/DAQ card. The 
> application runs several Xenomai tasks using message queues for communication.
> 
> Failure Description -
> The application starts. I can see IRQ lines being raised and lowered as 
> interrupts are handled. The application runs normally. After about one or two 
> minutes depending on the bus load, I "lose" the IRQ15 interrupt. My interrupt 
> service routine is never called and the interrupt chain is broken for that 
> device. I have traced the IRQ lines from the devices on the oscilloscope and see 
> that the IRQ goes high, but is never acknowledged. (See attached. I added labels 
> to each trace.) This failure is sporadic and seems to depend on all three 
> devices generating interrupts in the system.
> 
> Theory -
> The interrupt is never acknowledged because the PIC did not notify the processor 
> or software never acknowledged the PIC.
> 
> Testing approach -
> I need to determine if the hardware or software has lost the interrupt. I would 
> tend to suspect software first so I decided to start there. I am using the 
> parallel port pins as GPIO output and trying to instrument the low-level 
> ADEOS/Xenomai interrupt handling. If I catch the interrupt soon enough in the 
> interrupt pipeline I can determine that some software issue is preventing my isr 
> from running. If no interrupt ever occurs then I can suspect the hardware.
> 
> Assumptions -
> ADEOS/Xenomai/RTDM catches the interrupt and propagates it to my isr. If my isr 
> is the first level interrupt handler I am out of luck.
> 
> Any thoughts or suggestions are appreciated.

Already had a look at the ipipe-tracer?

http://download.gna.org/adeos/patches/v2.6/i386/tracer

If you can determine the error condition in software, it's easy to
trigger a freeze of the past invoked functions: xntrace_user_freeze. You
can call it from any context, also from user-space. Check
/proc/ipipe/tracer for the output ("frozen") and tunables (specifially
"back_trace_points"). If help on interpreting the result is required,
post it (or relevant excerpts) here.

Jan


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 249 bytes --]

  reply	other threads:[~2006-09-07 20:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-07 20:04 [Xenomai-help] Low-level isr in ADEOS/RTDM Sean McGranaghan
2006-09-07 20:33 ` Jan Kiszka [this message]
2006-09-08 10:44   ` Sean McGranaghan

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=4500821B.8040703@domain.hid \
    --to=jan.kiszka@domain.hid \
    --cc=smm@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.