cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
natew
Visitor
Visitor
2,472 Views
Registered: ‎07-23-2017

Simple PL-PS interrupt difficulty (Vivado 2017.2 + PetaLinux)

I have been working toward a minimal working project for the ZedBoard (Zynq7) in which I generate PL->PS interrupts and handle them in a kernel module in Linux. So far I've had no luck in seeing my interrupts, so I'd like to ask for help in case I'm doing something wrong.

 

I've tried several variations of hardware (including something like this with pushbuttons: https://www.xilinx.com/support/answers/58942.html), but my simplest hardware is just a Zynq block with the ZedBoard preset, PL-PS interrupts enabled, and a slow FCLK connected to each of the 16 IRQ lines via the concat IP.

 

I generate and export my hardware with Vivado, then load it into PetaLinux. I use PetaLinux build and package everything, then boot. My driver happily loads, but it never notifies me of any interrupts, and when I check /proc/interrupts, the interrupt count always stays at 0 for my IRQ. I've tried offsetting the IRQ by 32 in my module code to no effect.

 

Less importantly since I'm not using the Xilinx SDK directly (since I'm using a PetaLinux workflow), I've tried opening my project in the SDK and looking for the xparameters.h file I've seen mentioned, but I'm not seeing it anywhere. Am I perhaps missing a step, or should the header file be generated when I export my hardware from Vivado?

 

Thanks in advance for any assistance.

5 Replies
hbucher
Scholar
Scholar
2,461 Views
Registered: ‎03-22-2016

@natew Perhaps you should try a standalone application first and go from there. 

 

Could you try this example? 

https://www.xilinx.com/support/answers/50572.html

 

 

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos
pratham
Scholar
Scholar
2,413 Views
Registered: ‎06-05-2013

is it possible to upload the .hdf file of your hardware design? this information should have been in HDF when you export.
-Pratham

----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------------
0 Kudos
natew
Visitor
Visitor
2,362 Views
Registered: ‎07-23-2017

Sure. Attached is the HDF for one of the projects I've attempted. It's just a Zynq block with FCLK1 connected (via concat) to all 16 IRQ lines.

0 Kudos
natew
Visitor
Visitor
2,179 Views
Registered: ‎07-23-2017

@pratham Any thoughts?

0 Kudos
jasonwu
Moderator
Moderator
2,145 Views
Registered: ‎03-27-2013

Hi natew,

 

First I would suggest you to drive the interrupt in standalone application to check if there is hardware problem.

Then you can try to create a module template according to the section of "Steps to Add Custom Modules" in UG1144.

It can generate an simple driver template which has interrupt registration inside.

I have done similar test before on an old version of PetaLinux to register a custom interrupt to Linux. Not sure if the template is the same.

Best Regards,
Jason
-----------------------------------------------------------------------------------------------
Please mark the Answer as "Accept as solution" if the information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
-----------------------------------------------------------------------------------------------