<div dir="ltr"><div>Hi!!</div><div>I attach the boot log: <br></div><div><br></div><div><b>U-Boot SPL 2018.01 (Dec 04 2019 - 08:25:44)<br>EL Level:       EL3<br>Trying to boot from MMC1<br>reading u-boot.bin<br>reading atf-uboot.ub<br>reading atf-uboot.ub<br>NOTICE:  ATF running on XCZU9EG/silicon v3/RTL5.1 at 0xfffea000, with PMU firmwe<br>NOTICE:  BL31: Secure code at 0x0<br>NOTICE:  BL31: Non secure code at 0x8000000<br>NOTICE:  BL31: v1.5(release):<br>NOTICE:  BL31: Built : 08:25:34, Dec  4 2019<br>PMUFW:  v1.1<br>                                                                                <br>                                                                                <br>U-Boot 2018.01 (Dec 04 2019 - 08:25:44 +0100) Xilinx ZynqMP ZCU102 rev1.0       <br>                                                                                <br>I2C:   ready                                                                    <br>DRAM:  4 GiB                                                                    <br>EL Level:       EL2                                                             <br>Chip ID:        zu9eg                                                           <br>MMC:   sdhci@ff170000: 0 (SD)                                                   <br>*** Warning - bad CRC, using default environment                                <br>                                                                                <br>In:    serial@ff000000                                                          <br>Out:   serial@ff000000                                                          <br>Err:   serial@ff000000                                                          <br>Bootmode: LVL_SHFT_SD_MODE1                                                     <br>Net:   ZYNQ GEM: ff0e0000, phyaddr c, interface rgmii-id                        <br>                                                                                <br>Warning: ethernet@ff0e0000 (eth0) using random MAC address - 0a:3a:e6:2f:ab:08  <br>eth0: ethernet@ff0e0000                                                         <br>Hit any key to stop autoboot:  0                                                <br>switch to partitions #0, OK                                                     <br>mmc0 is current device                                                          <br>Device: sdhci@ff170000                                                          <br>Manufacturer ID: 3                                                              <br>OEM: 5344                                                                       <br>Name: SL16G                                                                     <br>Tran Speed: 50000000                                                            <br>Rd Block Len: 512                                                               <br>SD version 3.0                                                                  <br>High Capacity: Yes                                                              <br>Capacity: 14.8 GiB                                                              <br>Bus Width: 4-bit                                                                <br>Erase Group Size: 512 Bytes                                                     <br>reading system.dtb                                                              <br>37887 bytes read in 15 ms (2.4 MiB/s)                                           <br>reading Image                                                                   <br>14825984 bytes read in 982 ms (14.4 MiB/s)                                      <br>## Flattened Device Tree blob at 04000000                                       <br>   Booting using the fdt blob at 0x4000000                                      <br>   Loading Device Tree to 000000000fff3000, end 000000000ffff3fe ... OK         <br>                                                                                <br>Starting kernel ...                                                             <br>                                                                                <br>[    0.000000] Booting Linux on physical CPU 0x0                                <br>[    0.000000] Linux version 4.14.0 (adrian@adrian) (gcc version 7.4.0 (Buildro9<br>[    0.000000] Boot CPU: AArch64 Processor [410fd034]                           <br>[    0.000000] Machine model: ZynqMP ZCU102 Rev1.0                              <br>[    0.000000] earlycon: cdns0 at MMIO 0x00000000ff000000 (options '115200n8')  <br>[    0.000000] bootconsole [cdns0] enabled                                      <br>[    0.000000] efi: Getting EFI parameters from FDT:                            <br>[    0.000000] efi: UEFI not found.                                             <br>[    0.000000] cma: Reserved 256 MiB at 0x0000000070000000                      <br>[    0.000000] psci: probing for conduit method from DT.                        <br>[    0.000000] psci: PSCIv1.1 detected in firmware.                             <br>[    0.000000] psci: Using standard PSCI v0.2 function IDs                      <br>[    0.000000] psci: MIGRATE_INFO_TYPE not supported.                           <br>[    0.000000] percpu: Embedded 21 pages/cpu @ffffffc87ff66000 s45080 r8192 d326<br>[    0.000000] Detected VIPT I-cache on CPU0                                    <br>[    0.000000] CPU features: enabling workaround for ARM erratum 845719         <br>[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 1034240   <br>[    0.000000] Kernel command line: earlycon clk_ignore_unused root=/dev/mmcblkt<br>[    0.000000] PID hash table entries: 4096 (order: 3, 32768 bytes)             <br>[    0.000000] Dentry cache hash table entries: 524288 (order: 10, 4194304 byte)<br>[    0.000000] Inode-cache hash table entries: 262144 (order: 9, 2097152 bytes) <br>[    0.000000] software IO TLB [mem 0x6bfff000-0x6ffff000] (64MB) mapped at [ff]<br>[    0.000000] Memory: 3785368K/4194304K available (10108K kernel code, 654K rw)<br>[    0.000000] Virtual kernel memory layout:                                    <br>[    0.000000]     modules : 0xffffff8000000000 - 0xffffff8008000000   (   128 )<br>[    0.000000]     vmalloc : 0xffffff8008000000 - 0xffffffbebfff0000   (   250 )<br>[    0.000000]       .text : 0xffffff8008080000 - 0xffffff8008a60000   ( 10112 )<br>[    0.000000]     .rodata : 0xffffff8008a60000 - 0xffffff8008d80000   (  3200 )<br>[    0.000000]       .init : 0xffffff8008d80000 - 0xffffff8008e00000   (   512 )<br>[    0.000000]       .data : 0xffffff8008e00000 - 0xffffff8008ea3a00   (   655 )<br>[    0.000000]        .bss : 0xffffff8008ea3a00 - 0xffffff80090bf030   (  2158 )<br>[    0.000000]     fixed   : 0xffffffbefe7fd000 - 0xffffffbefec00000   (  4108 )<br>[    0.000000]     PCI I/O : 0xffffffbefee00000 - 0xffffffbeffe00000   (    16 )<br>[    0.000000]     vmemmap : 0xffffffbf00000000 - 0xffffffc000000000   (     4 )<br>[    0.000000]               0xffffffbf00000000 - 0xffffffbf1dc00000   (   476 )<br>[    0.000000]     memory  : 0xffffffc000000000 - 0xffffffc880000000   ( 34816 )<br>[    0.000000] Hierarchical RCU implementation.                                 <br>[    0.000000]  RCU event tracing is enabled.                                   <br>[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.            <br>[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4     <br>[    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0                   <br>[    0.000000] GIC: Adjusting CPU interface base to 0x00000000f902f000          <br>[    0.000000] GIC: Using split EOI/Deactivate mode                             <br>[    0.000000] arch_timer: cp15 timer(s) running at 100.00MHz (phys).           <br>[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycless<br>[    0.000003] sched_clock: 56 bits at 100MHz, resolution 10ns, wraps every 439s<br>[    0.008378] Console: colour dummy device 80x25                               <br>[    0.012463] console [tty0] enabled                                           <br>[    0.015829] bootconsole [cdns0] disabled    </b><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">El mar., 3 dic. 2019 a las 9:44, Adrian martinez munera (<<a href="mailto:adrianmartinezmunera@gmail.com">adrianmartinezmunera@gmail.com</a>>) escribió:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div>Hi Luca, <br></div><div>thanks for your answer!</div><div>How I said to Thomas, I'm trying to compile a Linux image to my ZCU-102 with EPICS (<a href="https://epics.anl.gov" target="_blank">https://epics.anl.gov</a>). But, as first step, I'd want build a simple Linux image, all of this using Buildroot.  <br></div><div>Using yours steps, I've created a pmufw.bin with your builder and the 'pm_cfg_obj.c', created by the Vivado project (xilpm library enabled). <br></div><div>Now I've a new two errors at the boot: <br></div><div>1. boot console [cdns0] disabled <br></div><div>2. The root file system is empty<br></div></div><div><br></div><div><b>defconfig</b> file that I'm using: <br></div><div><br></div><div>BR2_aarch64=y<br>BR2_GLOBAL_PATCH_DIR="board/zynqmp/patches/"<br>BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_14=y<br>BR2_ROOTFS_POST_IMAGE_SCRIPT="board/zynqmp/post-image.sh"<br>BR2_LINUX_KERNEL=y<br>BR2_LINUX_KERNEL_CUSTOM_GIT=y<br>BR2_LINUX_KERNEL_CUSTOM_REPO_URL="git://<a href="http://github.com/Xilinx/linux-xlnx.git" target="_blank">github.com/Xilinx/linux-xlnx.git</a>"<br>BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="xilinx-v2018.3"<br>BR2_LINUX_KERNEL_DEFCONFIG="xilinx_zynqmp"<br>BR2_LINUX_KERNEL_DTS_SUPPORT=y<br>BR2_LINUX_KERNEL_INTREE_DTS_NAME="xilinx/zynqmp-zcu102-rev1.0"<br>BR2_TARGET_ROOTFS_EXT2=y<br>BR2_TARGET_ROOTFS_EXT2_4=y<br># BR2_TARGET_ROOTFS_TAR is not set<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE=y<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_GIT=y<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_REPO_URL="<a href="https://github.com/ARM-software/arm-trusted-firmware.git" target="_blank">https://github.com/ARM-software/arm-trusted-firmware.git</a>"<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_REPO_VERSION="v1.5"<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="zynqmp"<br>BR2_TARGET_ARM_TRUSTED_FIRMWARE_BL31_UBOOT=y<br>BR2_TARGET_UBOOT=y<br>BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y<br>BR2_TARGET_UBOOT_CUSTOM_GIT=y<br>BR2_TARGET_UBOOT_CUSTOM_REPO_URL="git://<a href="http://github.com/xilinx/u-boot-xlnx.git" target="_blank">github.com/xilinx/u-boot-xlnx.git</a>"<br>BR2_TARGET_UBOOT_CUSTOM_REPO_VERSION="228801a215909365ae1dcdd799034195ad7264f7"<br>BR2_TARGET_UBOOT_BOARD_DEFCONFIG="xilinx_zynqmp_zcu102_rev1_0"<br>BR2_TARGET_UBOOT_NEEDS_DTC=y<br>BR2_TARGET_UBOOT_SPL=y<br>BR2_TARGET_UBOOT_SPL_NAME="spl/boot.bin"<br>BR2_TARGET_UBOOT_ZYNQMP=y<br>BR2_TARGET_UBOOT_ZYNQMP_PMUFW="/home/adrian/Documents/ZCU-102/pmufw_builder/zynqmp-pmufw-builder/pmufw.bin"<br>BR2_PACKAGE_HOST_DOSFSTOOLS=y<br>BR2_PACKAGE_HOST_GENIMAGE=y<br>BR2_PACKAGE_HOST_MTOOLS=y</div><div><br></div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">El mar., 26 nov. 2019 a las 17:49, Luca Ceresoli (<<a href="mailto:luca@lucaceresoli.net" target="_blank">luca@lucaceresoli.net</a>>) escribió:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Adrian,<br>
<br>
On 20/11/19 09:21, Adrian martinez munera wrote:<br>
> Hi,<br>
> I'm not sure if I have to write you by this mail. <br>
> <br>
> I'm using buildroot to create a Linux image to my ZCU-102, adding EPICS.<br>
> <br>
> My first attempt are been build  a simple Linux image, without EPICS,<br>
> but it doesn't work.<br>
> <br>
> ¿Could you help me? ¿Could you give me all of necessary files to build<br>
> the image?<br>
<br>
Thomas already replied with some objections, and I agree you should<br>
explain better your problem.<br>
<br>
However, as setting up booting is more complex on ZynqMP platforms than<br>
in other ones, here are a few notes to address booting. They could be<br>
useful for other people as well.<br>
<br>
Buildroot has a defconfig for the ZCU106 board, you can take that as a<br>
starting point. However some things have changed since that was added,<br>
so I recommend a better approach now.<br>
<br>
I assume you already have a Vivado project implementing your FPGA<br>
design. Even a project with a completely empty FPGA is OK, what matters<br>
is that you configure the "ZynqMP block" appropriately for the board<br>
(the Vivado wizard helps you in starting from a default configuration<br>
with proper DDR timings, among others).<br>
<br>
With the Vivado project you can start the Xilinx XSDK to produce a bsp<br>
(don't forget to enable the xilpm library in the wizard). The xilpm<br>
library in the generated bsp has a file called pm_cfg_obj.c. It's the<br>
"configuration object" that tells the PMU FW how to configure peripherals.<br>
<br>
Now you could go for the "old" approach, the one used for the zcu106<br>
defconfig currently in Buildroot: using zynqmp-pmufw-builder [0] you can<br>
generate a pmufw.bin that contains your configuration object hard-coded.<br>
This is how the pmufw binaries in zynqmp-pmufw-binaries [1], and used in<br>
Buildroot for ZCU106, have been generated.<br>
<br>
But I rather suggest to use the "new" approach. U-Boot SPL since<br>
v2019.10 can load the PMUFW configuration object at runtime (just like<br>
Xilinx FSBL does). In this case you can avoid hard-coding the config<br>
object into the pmufw binary, and use a "standard" PMUFW that works for<br>
any ZynqMP board. The v2018.3 PMUFW in [1] has been built in this way.<br>
<br>
For additional explanations on the "new" approach see [2]. I wrote some<br>
suggestions on how to implement such a workflow for yocto on the<br>
meta-xilinx mailing list [3], the underlying idea should apply to<br>
Buildroot as well.<br>
<br>
I hope this is useful for you. As pointed out by Thomas, your question<br>
is not very precise, so please add more details on exactly what you want<br>
to achieve, what you tried and how it failed. Somebody will probably be<br>
able to help you better.<br>
<br>
[0] <a href="https://github.com/lucaceresoli/zynqmp-pmufw-builder" rel="noreferrer" target="_blank">https://github.com/lucaceresoli/zynqmp-pmufw-builder</a><br>
[1] <a href="https://github.com/lucaceresoli/zynqmp-pmufw-binaries" rel="noreferrer" target="_blank">https://github.com/lucaceresoli/zynqmp-pmufw-binaries</a><br>
[2] <a href="https://lucaceresoli.net/zynqmp-uboot-spl-pmufw-cfg-load/" rel="noreferrer" target="_blank">https://lucaceresoli.net/zynqmp-uboot-spl-pmufw-cfg-load/</a><br>
[3] <a href="https://lists.yoctoproject.org/g/meta-xilinx/message/4570" rel="noreferrer" target="_blank">https://lists.yoctoproject.org/g/meta-xilinx/message/4570</a><br>
<br>
-- <br>
Luca<br>
</blockquote></div></div>
</blockquote></div>