cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
kmshaw_saic
Observer
Observer
9,485 Views
Registered: ‎01-26-2011

Need Help With "petalinux-config" Device Tree Generation Error

Jump to solution

Good evening,

 

I have a design that that worked with Vivado/Petalinux 2014.4. The following changes were made:

 

  • Added additional IP to the design in IPI.
  • Upgraded to 2015.2

 

I run the following command:

 

petalinux-config --get-hw-description -p /home/labuser/bmdl_sdr1 -v

 

and I get the following error:

 

[INFO ] generate DTS to /home/labuser/bmdl_sdr1/subsystems/linux/configs/device-tree

****** hsi v (64-bit)
  **** SW Build 1266856 on Fri Jun 26 16:35:25 MDT 2015
    ** Copyright 1986-2015 Xilinx, Inc. All Rights Reserved.

source /opt/PetaLinux/petalinux-v2015.2-final/etc/hsm/scripts/petalinux_hsm_bridge.tcl -notrace
INFO: [Hsi 55-1698] elapsed time for repository loading 3 seconds
can't read "errorCode": no such variable
    while executing
"puts stderr "Error code: ${errorCode}.""
    (procedure "plnx_error_exit" line 2)
    invoked from within
"plnx_error_exit "HSM failed to generate dts""
    (procedure "prepare_dt_bsp" line 13)
    invoked from within
"prepare_dt_bsp"
    invoked from within
"if {[string equal -nocase $target_app "u-boot_bsp"]} {
    add_def_ip_list
    uboot_config_gen
} elseif {[string equal -nocase $target_app "device-tree"]} ..."
    (file "/opt/PetaLinux/petalinux-v2015.2-final/etc/hsm/scripts/petalinux_hsm_bridge.tcl" line 455)
INFO: [Common 17-206] Exiting hsi at Fri Jul 24 19:01:22 2015...
ERROR: Failed to post config linux
ERROR: Failed to config subsystem linux.
nux/Kconfig.syshw:1872:warning: choice value used outside its choice group
/home/labuser/bmdl_sdr1/build/linux/Kconfig.syshw:1409:warning: choice value used outside its choice group
/home/labuser/bmdl_sdr1/build/linux/Kconfig.syshw:1720:warning: choice value used outside its choice group
/home/labuser/bmdl_sdr1/build/linux/Kconfig.syshw:1422:warning: choice value used outside its choice group
/home/labuser/bmdl_sdr1/build/linux/Kconfig.syshw:1733:warning: choice value used outside its choice group
ERROR: [Common 17-263] There was a syntax error while parsing filter expression: 'INSTANCE==ps7_scugic_0 axi_mod_intc_0' at position '23'
ERROR: [Hsi 55-1545] Problem running tcl command ::sw_device_tree::generate : ERROR: [Common 17-263] There was a syntax error while parsing filter expression: 'INSTANCE==ps7_scugic_0 axi_mod_intc_0' at position '23'

    while executing
"::hsi::get_mem_ranges -of_objects $hw_proc_handle -filter "INSTANCE==$periph""
    (procedure "hsi::utils::get_ip_mem_ranges" line 5)
    invoked from within
"hsi::utils::get_ip_mem_ranges [get_cells $ip]"
    (procedure "get_ps_node_unit_addr" line 3)
    invoked from within
"get_ps_node_unit_addr $ip_name"
    (procedure "ps_node_mapping" line 3)
    invoked from within
"ps_node_mapping $intc label"
    (procedure "gen_interrupt_property" line 53)
    invoked from within
"gen_interrupt_property $drv_handle"
    ("foreach" body line 7)
    invoked from within
"foreach drv_handle [get_drivers] {
        # generate the default properties
        gen_peripheral_nodes $drv_handle "create_node_only"
        gen_r..."
    (procedure "::sw_device_tree::generate" line 3)
    invoked from within
"::sw_device_tree::generate device_tree"
ERROR: [Hsi 55-1442] Error(s) while running TCL procedure generate()
make[1]: *** [autogen-dts] Error 1
make: *** [post-config-auto-dts] Error 255

 

One thing different between 2014.4 and 2015.2 is that "IP Packager" in 2015.2 has the following warning:

 

[IP_Flow 19-4629] File Group 'xilinx_softwaredriver (Software Driver)': Requires either a MLD or a MDD file. Neither have been added to file group: "xilinx_softwaredriver"

 

But as you can see, the MDD has been added:

 

MDD Error 1.jpg

 

 

I'm wondering if that is causing the problem?

 

How do I determine the problem? I've searched files for the text 'INSTANCE==ps7_scugic_0 axi_mod_intc_0' at position '23' without success.

 

The TCL code for "prepare_dt_bsp" is this:

 

proc prepare_dt_bsp {} {
    global target_os out_dir target_app target_cpu
    set cpu_arch [get_sw_proc_arch $target_cpu]
    debug "prepare_bsp" "CPU Arch: $target_cpu"
    debug 1 "create_sw_design -os $target_os -dir $target_app -proc $target_cpu"

    if { [catch {create_sw_design "${target_app}" -proc "${target_cpu}" -os "${target_os}"} msg ]} {
        plnx_error_exit "HSM failed to create tree software design."
    }
    set_os_prop
    set_property CONFIG.pcw_dts "pcw.dtsi" [get_os]
    if { [catch {generate_target -dir "${out_dir}"} msg] } {
        plnx_error_exit "HSM failed to generate dts"
    }
}

 

But it's not clear to me why the last conditional statement is executed and "HSM failed to generate dts" is issued.

 

Anybody have any ideas??

 

Thanks,

 

Kevin

 

0 Kudos
1 Solution

Accepted Solutions
kmshaw_saic
Observer
Observer
16,242 Views
Registered: ‎01-26-2011

The problem, for those that are interested, was caused by the tools not supporting a desgn with both the ARM and one or more Microblazes. This was confirmed by Xilinx.

 

The workaround in a nutshell is this:

 

  • Copy the design to a new folder
  • Remove the Microblaze(s) from the design
  • Build Petalinux using this modified design
  • When "petalinux-package" is run, use the BIT file for the complete design (the one with the Microblaze(s))

 

Kevin

 

View solution in original post

0 Kudos
4 Replies
kmshaw_saic
Observer
Observer
9,277 Views
Registered: ‎01-26-2011

One thing I should mention is there are multiple MicroBlaze processors in the design. Petalinux will run in the ARM processor. The "choice value used outside its choice group" warning references line numbers in file "Kconfig.syshw" that appears to correspond to the Microblaze processors.

 

Is it possible that "petalinux-config" is having trouble with an 'hdf' file with multiple processors?

 

Kevin

 

0 Kudos
achutha
Xilinx Employee
Xilinx Employee
8,983 Views
Registered: ‎07-01-2010

@kmshaw_saic

 

I have seen a similar issue working with latest device-tree from git for one of my customer.

 

There is a CR#871804 filed for Petalinux 2015.2 issue , i will keep you posted on this.

 

Can you share the hdf file?

 

Regards,
Achutha

---------------------------------------------------------------------------------------------
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
kmshaw_saic
Observer
Observer
8,976 Views
Registered: ‎01-26-2011

Hi Achutha,

 

The hdf is attached. Be advised I have opened a Service Request on this (SR# 10317673) yesterday but haven't received a response yet.

 

Thanks,

 

Kevin

0 Kudos
kmshaw_saic
Observer
Observer
16,243 Views
Registered: ‎01-26-2011

The problem, for those that are interested, was caused by the tools not supporting a desgn with both the ARM and one or more Microblazes. This was confirmed by Xilinx.

 

The workaround in a nutshell is this:

 

  • Copy the design to a new folder
  • Remove the Microblaze(s) from the design
  • Build Petalinux using this modified design
  • When "petalinux-package" is run, use the BIT file for the complete design (the one with the Microblaze(s))

 

Kevin

 

View solution in original post

0 Kudos