We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

Showing results for 
Search instead for 
Did you mean: 
Registered: ‎10-14-2017

Booting linux from SD card fails - ** No boot file defined **


I'm trying to get started with embedded linux on my zynq-7000 board (z-turn z7020). More precisely I'm trying to create a bootable linux for my SD card. I've manged to create BOOT.bin, uImage, device tree and ramdisk files and put them onto my SD cards first partion which is formated to FAT32 (thers also a second partition on the card formated to ext4). When trying to boot the linux on my board I can see from the terminal that u-boot gets loaded sucessfully, but loading the kernel fails. U-boot says that "no boot file defined" however I do have a kernel file on my SD card.

I understand that I probably need to write the uEnv file or load the kernel manually in monitor by specifying load address etc. However non of the tutorials I've followed (the z-turn official "Linux Development Manual" or this instructable) give any details about that. I've started reading about uboot and embedded linux, however there is a lot of material to go through and I would just like to get started. So maybe someone can point out what did I miss and what needs to be added?

Also, if someone knows any good tutorials or guides on this subject, please share them.

The full printout from my terminal when booting is as follows:


U-Boot 2013.10 (Mar 21 2019 - 21:26:00)

Memory: ECC disabled
DRAM:  1 GiB
MMC:   zynq_sdhci: 0
SF: Detected W25Q128BV with page size 256 Bytes, erase size 4 KiB, total 16 MiB
In:    serial
Out:   serial
Err:   serial
Net:   Gem.e000b000
Hit any key to stop autoboot:  0
Device: zynq_sdhci
Manufacturer ID: 9c
OEM: 534f
Name: USD00
Tran Speed: 50000000
Rd Block Len: 512
SD version 3.0
High Capacity: Yes
Capacity: 7.3 GiB
Bus Width: 4-bit
reading uEnv.txt
** Unable to read file uEnv.txt **
- load to PL...
** No boot file defined **



0 Kudos
1 Reply
Registered: ‎10-14-2017

Re: Booting linux from SD card fails - ** No boot file defined **

I had a look at the uboot environment variables hardcoded when compiling the uboot. From there I see that it tries to load the bit image to RAM from address 0x200000 however I do not have a bit file which is why it hangs. When I load the kernel, device tree and ramdisk manually using these commands:

setenv devicetree_image zynq-zturn.dtb

fatload mmc 0 ${kernel_load_address} ${kernel_image} fatload mmc 0 ${devicetree_load_address} ${devicetree_image} fatload mmc 0 ${ramdisk_load_address} ${ramdisk_image}

and then launch the kernel with a command

bootm ${kernel_load_address} ${ramdisk_load_address} ${devicetree_load_address}

it works and kernel get loaded and runs. However now I've run into a new problem which is that kernel hangs for some reason at the lines:

can: broadcast manager protocol (rev 20120528 t)
can: netlink gateway (rev 20130117) max_hops=1
Registering SWP/SWPB emulation handler

I've still not figured out why this is, but at least I've made progress.

If the whole printout of Kernel starting up is needed for someone to help me, then let me know and I will add that as a text file.

0 Kudos