Skip to contentSkip to conversation

Problems triggering a nested interrupt to a user space process

Xenomai Marco Tessore 2 participants 3 messages Sep 25, 2014 – Sep 26, 2014 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

Good morning,
I'd like to manage, from user-space, the reaction to interrupts on GPIO pins, on a board based on processor Freescale iMX28. I have Linux 3.11 and Xenomai 2.6.3.

In no way I can see reactions interrupt, nor from user space, where I call rt_intr_create, rt_intr_enable, rt_intr_wait, nor from kernel space by attaching a handler with the rtdm_irq_request.

The interrupt type is "nested", as each bank acts as a collector for all gpio pin may receive interrupt.

Referring to the pin I'm using for my tests,
I have a kernel module with which I can inform userspace about the irq number assigned by Linux, both as regards the controller pin (interrupt 93),
that with regard to the interrupt of the single specific pin (interrupt 98).

I did a little debugging at the kernel level and I saw that, when I take the interrupt,
1) is invoked __ipipe_grab_irq (irq = 93)
2) is invoked after the linux gpio interrupt handler, manifold (mxs_gpio_irq_handler in gpio-mxs.c)
3) Thi handler invokes the generic_handle_irq for irq 98
4) Take again the __ipipe_grab_irq for interrupt 98.
5) Nothing happens at this point.

At this point I thought that if I had engaged in user-space or kernel-space to interrupt 98 or 93, I could see some reaction, unfortunately I can not see any further reaction.

Would you have any suggestions about what to look for to get the desired effect?

Thank you in advance
Kind regards
Marco Tessore

#1 lore raw
Quoted 4 lines · Marco Tessore

Good morning,
I'd like to manage, from user-space, the reaction to interrupts on GPIO pins, on a board based on processor Freescale iMX28.
I have Linux 3.11 and Xenomai 2.6.3.

We did not make an I-pipe patch for Linux 3.11. Are you able to reproduce the issue with an I-pipe patch we delivered?

Signature · 1 line
                                                                Gilles.

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw
Quoted 11 lines · Marco Tessore

Il 25/09/2014 18:17, Gilles Chanteperdrix ha scritto:

Quoted 8 lines · Marco Tessore
Quoted 4 lines

Good morning,
I'd like to manage, from user-space, the reaction to interrupts on GPIO pins, on a board based on processor Freescale iMX28.
I have Linux 3.11 and Xenomai 2.6.3.

We did not make an I-pipe patch for Linux 3.11. Are you able to reproduce the issue with an I-pipe patch we delivered?

I-pipe patch is the 3.10.18 stable one.
It was applied to a kernel 3.11.0rc3.

Using an rc kernel is a bad idea. Especially since the 3.11 kernel has been released for several monthes now. Anyway, could you test with a kernel for which we provide an I-pipe patch?

Other than that, I suggest you read:
http://xenomai.org/2014/09/porting-xenomai-dual-kernel-to-a-new-arm-soc/
And use it to check that everything is made correctly for the SOC you use.

Please keep the conversation on the list.

Signature · 1 line
                                                                Gilles.