All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wolfgang Grandegger <wg@domain.hid>
To: niklaus.giger@domain.hid
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-help] Handling a interrupt from user space on PPC405
Date: Thu, 14 Dec 2006 09:08:24 +0100	[thread overview]
Message-ID: <45810678.507@domain.hid> (raw)
In-Reply-To: <200612132315.54899.niklaus.giger@domain.hid>

Niklaus Giger wrote:
> Hi
> 
> I tried to use the FIT (Fixed Interrupt Timer) on my PPC405GPr board, which 
> uses 0x1010 as its interrupt vector in a user space (vxworks-skin) 
> application.
> <..>
>   RT_INTR FITnterrupt;
>   res = rt_intr_create(&FITnterrupt, 0, 0x1010, I_NOAUTOENA);
> <..>
> But I got -22 EINVAL as error.
> Could somebody please tell me, what is wrong with my example.

The FIT exception is not an external interrupt and cannot be used with 
the the above function. And 0x1010 is not a valid IRQ number anyhow 
(it's actually the jump address of the FIT exception).

> I would like to have as little as possible code in the kernel and handling the 
> whole interrupt in a RT (vxworks-skin) user space task.
> 
> And how do I have to handle the case, where my interrupt handler is only 
> interested in one of external interrupts of the PPC405?
> 
> A good answer would enable me to publish afterwards a working example code.

The right thing to do is to handle the expection as VIRQ like the 
decrementer (or the PIT on the AMCC 405). Unfortunately, this requires 
various modifications to the ADEOS-IPIPE patch, but it's feasible, of 
course. Search for CONFIG_IPIPE in head_4xx.c,

Wolfgang.



      parent reply	other threads:[~2006-12-14  8:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-13 22:15 [Xenomai-help] Handling a interrupt from user space on PPC405 Niklaus Giger
2006-12-14  7:05 ` Heikki Lindholm
2006-12-14  8:23   ` Wolfgang Grandegger
2006-12-14  9:05     ` Heikki Lindholm
2006-12-14  9:39       ` Wolfgang Grandegger
2006-12-14 12:43   ` Niklaus Giger
2006-12-14  8:08 ` Wolfgang Grandegger [this message]

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=45810678.507@domain.hid \
    --to=wg@domain.hid \
    --cc=niklaus.giger@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.