UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Observer zaku89
Observer
420 Views
Registered: ‎05-30-2018

(Ultrascale+Petalinux2017.4) Two Interrupt port from one custom IP, the second interrupt is missing

I am running Petalinux 201.4 on Ultrazed board. I have a custom IP which will generate two rising edge interrupt signal every 100 us. I connect the two port to the PL-PS SPI interrupt (GIC NO: 121, 122) Because I have not set the trigger type in the vivado project (default will be level trigger). So I have to modify this edge property in the system-user.dtsi manually as follow: /include/ "system-conf.dtsi" / { }; / { chosen { bootargs = "earlycon clk_ignore_unused earlyprintk root=/dev/mmcblk1p2 rw rootwait rootfstype=ext4 mem=1024M uio_pdrv_genirq.of_id=generic-uio"; }; }; &TriggerGen_IP_0 { compatible = "generic-uio"; interrupts = <0 89 1 0 90 1>; }; Then I rebuild the petalinux and boot up the system. It seems I can only see and get Interrput 121(89+32) edge type. But I can not see or get the 122. Does anyone can help? Thank you!
0 Kudos
4 Replies
Observer zaku89
Observer
399 Views
Registered: ‎05-30-2018

Re: (Ultrascale+Petalinux2017.4) Two Interrupt port from one custom IP, the second interrupt is missing

Sorry for the format, I have no idea why it looks so strange. I will repost it again.

 

I am running Petalinux 201.4 on Ultrazed board.

I have a custom IP which will generate two rising edge interrupt signal every 100 us.

I connect the two port to the PL-PS SPI interrupt (GIC NO: 121, 122)

Because I have not set the trigger type in the vivado project (default will be level trigger).

 

So I have to modify this edge property in the system-user.dtsi manually as follow:

 

/include/

"system-conf.dtsi"

/ {

};

/ {

chosen { bootargs = "earlycon clk_ignore_unused earlyprintk root=/dev/mmcblk1p2 rw rootwait rootfstype=ext4 mem=1024M uio_pdrv_genirq.of_id=generic-uio";

};

};

&TriggerGen_IP_0 {

            compatible = "generic-uio";

            interrupts = <0 89 1 0 90 1>;

          };

Then I rebuild the petalinux and boot up the system.

It seems I can only see and get Interrput 121(89+32) edge type.

But I can not see or get the 122.

Does anyone can help? Thank you!

0 Kudos
Moderator
Moderator
392 Views
Registered: ‎09-12-2007

Re: (Ultrascale+Petalinux2017.4) Two Interrupt port from one custom IP, the second interrupt is missing

The UIO does not support multiple interrupt sources

 

You would need to update the source here:

drivers/uio/uio_pdrv_genirq.c

if (ret >= 1) {
uioinfo->irq = ret;
uioinfo->handler = uio_pdrv_genirq_handler;
uioinfo->irqcontrol = uio_pdrv_genirq_irqcontrol;
uioinfo->open = uio_pdrv_genirq_open;
uioinfo->release = uio_pdrv_genirq_release;
}

 

You would need to update the handler and irqcontrol functions too.

 

I have never tried this.

 

 

0 Kudos
Observer zaku89
Observer
367 Views
Registered: ‎05-30-2018

Re: (Ultrascale+Petalinux2017.4) Two Interrupt port from one custom IP, the second interrupt is missing

Thank you Stephenm. I will try it.
0 Kudos
Moderator
Moderator
360 Views
Registered: ‎09-12-2007

Re: (Ultrascale+Petalinux2017.4) Two Interrupt port from one custom IP, the second interrupt is missing

Let me know how you get on. If I have spare time I'll try this when I get back to office 

0 Kudos