cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
rtapiador
Visitor
Visitor
1,166 Views
Registered: ‎06-07-2018

Reset PL from Petalinux Zynq MPSoC

Hi all,

I am triying to reset the PL from PS using petalinux.

My first attemp was using GPIO, However the system gets hangs when I tried to write a 1 to enable the reset.

Then I tried to use the ZynqMp reset driver to reset the PL reset, I did everything that I read here:

https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18842455/ZynqMP+Linux+Reset-controller+Driver

However the reset-mgr is not listed. I enabled the reset driver, but I have some doubts about where to write the dts entry. I wrote in /project-spec/meta-user/recipes-bsp/device-tree/files/system-user.dtsi
This is the entry:

rst: reset-controller {
compatible = "xlnx,zynqmp-reset";
#reset-cells = <1>;
};

I need to reset the logic and I would like to know if i wrote wrongly the dts entry or why the GPIO hangs the system.

If there is another way to reset the logic please tell me.

Thanks in advance

0 Kudos
Reply
5 Replies
zouyu930503
Adventurer
Adventurer
520 Views
Registered: ‎07-28-2018

Same question here. Did you find any solution to do that?

0 Kudos
Reply
pedro_uno
Advisor
Advisor
498 Views
Registered: ‎02-12-2013

I'm not sure what you mean by "reset the PL".  If you reset everything in your PL design including the AXI logic I can see why it would hang.

It is more common for software controlled resets to just reset a specific part of your design.

Another option to reset the whole PL would be to just reconfigure the fpga.  Petalinux has drivers that let you reconfigure the PL and it happens real fast.  That would put the whole PL back to the boot-up state.

 

----------------------------------------
DSP in hardware and software
-----------------------------------------
zouyu930503
Adventurer
Adventurer
455 Views
Registered: ‎07-28-2018

Hi,

I followed the tutorial to program PL from PetaLinux, but it's very vague, some parts are not clearly explained.

https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18841847/Solution+ZynqMP+PL+Programming#SolutionZynqMPPLProgramming-PetalinuxFlow

 

What is this hdf directory? PetaLinux 2019.2 does not use hdf anymore.

 
 
 
 
 
 
 

Thank you.

Screenshot from 2020-07-09 18-38-09.png
0 Kudos
Reply
zouyu930503
Adventurer
Adventurer
445 Views
Registered: ‎07-28-2018

Hi,

I re-programmed the PL, but it seems that peripherals are not reset at all.

0 Kudos
Reply
pedro_uno
Advisor
Advisor
397 Views
Registered: ‎02-12-2013

For reconfiguring the PL I don't think you need to enable anything like fpga manager in Petalinux. Here are some instructions I made for myself. I copy the .bin file to /lib/firmware then run a command as root. I am running a non-volatile root filesystem so things might be different for me.

Copy .../fpga/implement/results/top.bit.bin to /lib/firmware. I think you need to do this as sudo.
Change to root with "sudo su".
echo top.bit.bin > /sys/class/fpga_manager/fpga0/firmware

The blue done LED should flash off very briefly.

----------------------------------------
DSP in hardware and software
-----------------------------------------