cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
stonedown
Visitor
Visitor
1,950 Views
Registered: ‎10-16-2018

Custom device tree board file not found when building device tree

Zynq-7000

I am attempting to migrate from Petalinux-v2018.2 to Petalinux-v2018.3

I am unable to build the device tree without getting the below error. I am able to work-around by copying the XXXX.dtsi file into the following location:

/build/tmp/work/plnx_zynq7-xilinx-linux-gnueabi/device-tree/xilinx+gitAUTOINC+b7466bbeee-r0/git/device_tree/data/kernel_dtsi/2018.3/BOARD

Here is the error:

Error:XXXX.dtsi board file is not present in DTG. Please add a valid board.
ERROR: [Hsi 55-1545] Problem running tcl command ::sw_device_tree::generate : Error:XXXX.dtsi board file is not present in DTG. Please add a valid board.
    while executing
"error "Error:$dtsi_name board file is not present in DTG. Please add a valid board.""
    ("foreach" body line 57)
    invoked from within
"foreach override $overrides {
    if {[lindex $override 0] == "BOARD"} {
        set first_element [lindex $override 0]
        set dtsi_file [lindex $override 1]
        ..."
    ("foreach" body line 2)
    invoked from within
"foreach i [get_sw_cores device_tree] {
    foreach override $overrides {
    if {[lindex $override 0] == "BOARD"} {
        set first_element [lindex $override..."
    (procedure "gen_board_info" line 7)
    invoked from within
"gen_board_info"
    (procedure "::sw_device_tree::generate" line 12)
    invoked from within
"::sw_device_tree::generate device_tree"
ERROR: [Hsi 55-1442] Error(s) while running TCL procedure generate()
ERROR: [Common 17-39] 'generate_target' failed due to earlier errors.

 

It seems like I need to set_property CONFIG.periph_type_overrides, and I tried to do that with the "hsi" tool, but I get the same error.

Patch “0017-clk-Check-for-the-microblaze-in-the-gen_clk_property”, which was incorporated into Petalinux-v2018.3 says this:

From 03ca9a93bb02a2c48531f34e445d823c94f31fcb Mon Sep 17 00:00:00 2001

From: Venkatesh Yadav Abbarapu <venkatesh.abbarapu@xilinx.com>

Date: Wed, 22 Aug 2018 11:40:45 +0530

Subject: [DEVICE-TREE-XLNX PATCH 19/34] Add support for custom board dtsi files

 

In case if someone wants to add their custom board dtsi file out of the

device tree repository they can provide the absolute or relative path of

the dtsi file and that gets added to the output directory.

 

Example:

The custom board dtsi file path can be absolute or relative by using below

set_property CONFIG.periph_type_overrides "{BOARD <path>/zcu111-rev1.0.dtsi}" [get_os]

This dtsi files gets added to the output directory say dt/ and gets included in

system-top.dts.

 

Signed-off-by: Venkatesh Yadav Abbarapu <venkatesh.abbarapu@xilinx.com>

Acked-by: Michal Simek <michal.simek@xilinx.com>

 

I can't quite put the pieces of this puzzle together. What am I meant to do?

Thanks.

0 Kudos
2 Replies
ihcfan
Visitor
Visitor
798 Views
Registered: ‎08-09-2020

any answer on this?

0 Kudos
mustafa60
Contributor
Contributor
542 Views
Registered: ‎07-17-2019

hi @ihcfan and @stonedown ,

for you and others faced with this problem, don't change the board name in the config file. left it as it is(template). After modifying it, I encountered the same problem, too.

0 Kudos