Post Go back to editing

Unable to build petalinux 2021.2 for zynq-adrv9361-z7035-bob-cmos

Category: Software
Software Version: Petalinux 2021.2

I have been following the analog devices guide on setting up a project for petalinux.

I have not had any issues building the base analog devices design. However, I am having issues building for zynq-adrv9361-z7035-bob-cmos.

When i specify
KERNEL_DTB = "zynq-adrv9361-z7035-bob"  

the build succeeds. However, if i change it to the cmos variant like so:
KERNEL_DTB = "zynq-adrv9361-z7035-bob-cmos"  

i get the following error:
sed: can't read /home/petalinux_project/build/tmp/work/zynq_generic-xilinx-linux-gnueabi/device-tree/xilinx-v2021.2+gitAUTOINC+c0acd8f064-r0/zynq-adrv9361-z7035-bob.dts

I am not sure why this is happening. I tried specifying the manual device tree include directory to
($STAGING_KERNEL_DIR}/include)  
and
(${STAGING_KERNEL_DIR}/arch/arm/boot/dts)

but still the build will fail. Same behavior was observed when building
zynq-adrv9364-z7020-bob-cmos vs zynq-adrv9364-z7020-bob


Parents Reply Children
  • The device dts files aren't in WORKDIR, only the pl-delete files. 

  • Yes that is what I am seeing. I just built for the cmos kernel dtb and it failed. here are the contents of the directory in question:

    ls build/tmp/work/zynq_generic-xilinx-linux-gnueabi/device-tree/xilinx-v2021.2+gitAUTOINC+c0acd8f064-r0/
    base-hsi.tcl              pkgdata-pdata-input                                        pl-delete-nodes-zynq-zc706-adv7511-ad9434-fmc-500ebz.dtsi       pl-delete-nodes-zynq-zed-adv7511-adrv9002.dtsi
    build                     pkgdata-sysroot                                            pl-delete-nodes-zynq-zc706-adv7511-ad9625-fmcadc2.dtsi          pl-delete-nodes-zynq-zed-adv7511-adrv9002-rx2tx2.dtsi
    config                    pl-delete-nodes-zynq-adrv9361-z7035-bob-cmos.dtsi          pl-delete-nodes-zynq-zc706-adv7511-ad9739a-fmc.dtsi             pl-delete-nodes-zynq-zed-adv7511.dtsi
    deploy-device-tree        pl-delete-nodes-zynq-adrv9361-z7035-bob.dtsi               pl-delete-nodes-zynq-zc706-adv7511-adrv9008-1-jesd204-fsm.dtsi  pl-delete-nodes-zynq-zed-imageon.dtsi
    deploy-rpms               pl-delete-nodes-zynq-adrv9361-z7035-fmc.dtsi               pl-delete-nodes-zynq-zc706-adv7511-adrv9008-2-jesd204-fsm.dtsi  pseudo
    deploy-source-date-epoch  pl-delete-nodes-zynq-adrv9364-z7020-bob-cmos.dtsi          pl-delete-nodes-zynq-zc706-adv7511-adrv9009.dtsi                recipe-sysroot
    device-tree.spec          pl-delete-nodes-zynq-adrv9364-z7020-bob.dtsi               pl-delete-nodes-zynq-zc706-adv7511-adrv9371.dtsi                recipe-sysroot-default
    device-tree.yaml          pl-delete-nodes-zynq-zc702-adv7511-ad9361-fmcomms5.dtsi    pl-delete-nodes-zynq-zc706-adv7511-adrv9375-jesd204-fsm.dtsi    source-date-epoch
    dtgen.tcl                 pl-delete-nodes-zynq-zc702-adv7511.dtsi                    pl-delete-nodes-zynq-zc706-adv7511.dtsi                         sysroot-destdir
    git                       pl-delete-nodes-zynq-zc706-adv7511-ad6676-fmc.dtsi         pl-delete-nodes-zynq-zc706-adv7511-fmcdaq2.dtsi                 system-user.dtsi
    image                     pl-delete-nodes-zynq-zc706-adv7511-ad9081.dtsi             pl-delete-nodes-zynq-zc706-adv7511-fmcdaq3-revC.dtsi            temp
    license-destdir           pl-delete-nodes-zynq-zc706-adv7511-ad9172-fmc-ebz.dtsi     pl-delete-nodes-zynq-zc706-adv7511-fmcjesdadc1.dtsi             zynq-7000-qspi-dummy.dtsi
    package                   pl-delete-nodes-zynq-zc706-adv7511-ad9265-fmc-125ebz.dtsi  pl-delete-nodes-zynq-zc706-adv7511-fmcomms11.dtsi
    packages-split            pl-delete-nodes-zynq-zc706-adv7511-ad9361-fmcomms2-3.dtsi  pl-delete-nodes-zynq-zed-adv7511-ad9361-fmcomms2-3.dtsi
    pkgdata                   pl-delete-nodes-zynq-zc706-adv7511-ad9361-fmcomms5.dtsi    pl-delete-nodes-zynq-zed-adv7511-ad9467-fmc-250ebz.dtsi

    The corner case does not seem to be handled on my system. How do I go about checking the values of the petalinux environment variables, and which ones do you want me to check?

  • Changing the path in the corner case from WORKDIR to KERNEL_DTB_PATH resolves the problem.

    For example:

    dtb_tag_file="${KERNEL_DTB_PATH}/zynq-adrv9364-z7020-bob.dts"

    Do you want a pull request for this? I can't actually test the build since I don't have a machine with on old enough distro to run petalinux :(

  •  

    Can you tell me which branch are you using? You should be using 2021_R2...

    What do you have in your petalinux conf file? Are you only setting KERNEL_DTB? Lastly, can you paste the contents of the do_configue log file?

    We need to figure why the dts files are not being copied into your WORKDIR... On my weekly CI, those projects are building without any issues so I would also suggest a fresh clean build...

    - Nuno Sá

  • I was using 2021_R1, at the time of creating my project that was the most recent branch, I just switched to 2021_R2, that fixed the issue. Thank you for bringing that to my attention!

  • I was using 2021_R1, at the time of creating my project that was the most recent branch, I just switched to 2021_R2, that fixed the issue.

    Yeah, 2021_R2 is the one to use for the petalinux version you're using