cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Visitor
Visitor
105 Views
Registered: ‎08-24-2020

Include pl_mem in dtso file

Jump to solution

I have modified the SSR project for the ZCU111 board to use one of the high frequency ADC/DAC channels instead of the default channels which are low frequency.  I generated an .xsa file from Vivado and then used petalinux commands:

petalinux-build -c device-tree -x cleanstate
petalinux-build -c device-tree

to generate a .dtbo file.

When I tried loading the .bin and .dtbo file, none of the /sys/class/plmem/plmem0-15 drivers were installed.  I converted the .dtbo file to a .dtsi file, and all of these references were missing.

I have tried editing the .dtsi file by hand to add these back in, but have not been successful.  Fourteen of the 16 plmem folders are created, but 0 and 8 are always missing, and there are driver creation errors.

Before pursuing this further, I wanted to find out if there was a more efficient way to do this. 

Should I expect the .dtso file generated from the .xsa file to automatically include the plmem sections?  I am using the ZCU111 board files in the project.

If not, are there instructions as to how to correctly add these?  There seem to be a couple of layers involved, and creating them by hand with references between plmem, dma, and sram pool phandles seems like an error prone solution.

Thanks,

James

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Moderator
Moderator
68 Views
Registered: ‎02-07-2018

Hi @James_Edgar 

You can modify pl device tree changes using pl-custom.dtsi file. so that after building it this changes will reflect in base.dtbo file.

Below is for your reference

/ {
fragment@2 {
target = <&amba_pl>;
overlay2: __overlay__ {

ethernet@a0100000 {
axistream-connected = <0x45>;
axistream-control-connected = <0x45>;

};
dma@a0010000 {
linux,phandle = <0x45>;
phandle = <0x45>;
};

axi_quad_spi@a0030000 {
compatible = "generic-uio";   -- Added 
};

};
};

};

 axi_quad_spi  node present in pl.dtsi file , based on that only you need to modify pl-custom.dtsi file

You can see the changes  after converting it from  dtbo to dtsi  file using “dtc -I dtb -O dts base.dtbo -o system.dtsi” command

 

Thanks & regards

Aravind

----------------------------------------------------------------------------------------------
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.
---------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
2 Replies
Highlighted
Moderator
Moderator
69 Views
Registered: ‎02-07-2018

Hi @James_Edgar 

You can modify pl device tree changes using pl-custom.dtsi file. so that after building it this changes will reflect in base.dtbo file.

Below is for your reference

/ {
fragment@2 {
target = <&amba_pl>;
overlay2: __overlay__ {

ethernet@a0100000 {
axistream-connected = <0x45>;
axistream-control-connected = <0x45>;

};
dma@a0010000 {
linux,phandle = <0x45>;
phandle = <0x45>;
};

axi_quad_spi@a0030000 {
compatible = "generic-uio";   -- Added 
};

};
};

};

 axi_quad_spi  node present in pl.dtsi file , based on that only you need to modify pl-custom.dtsi file

You can see the changes  after converting it from  dtbo to dtsi  file using “dtc -I dtb -O dts base.dtbo -o system.dtsi” command

 

Thanks & regards

Aravind

----------------------------------------------------------------------------------------------
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.
---------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
Highlighted
Visitor
Visitor
51 Views
Registered: ‎08-24-2020

For anyone else missing the pl_mem sections after rebuild, attached is the file I added so they would be included with a new .xsa build.  (.txt added to file name so it will not be deleted on post)  Edited to replace file with 2020.1 version.

0 Kudos