This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x boot from zImage - problem

Hello, 

I have problem with starting kernel. I compiled my kernel with am335x-evm_defconfing. Before compilation I added initramfs, and I shown my own rootfs. When the compilations was end, I transfered my zImage to NFS folder. I restarted NFS demon, and turned on Sitara. In main menu u-Boot I executed this command. 

setenv bootfile zImage

setenv fdtfile am335x.dtb

setenv serverip <serverip>

dhcp

After this command a whole image was transfered.

tftp ${fdtaddr} ${fdtfile};

bootz ${loadaddr} - ${fdtaddr};

After this command I saw this  console lines

## Flattened Device Tree blob at 80f80000
Booting using the fdt blob at 0x80f80000
Loading Device Tree to 8f321000, end 8f32c4e6 ... OK

Starting kernel ...

And in this stage process was hang. Any suggestion about it.? Maybe I do something wrong. 

 

  • Hi,

    I will forward this to the SW team.

  • Hi,

    Please see the kernel output console setting. If it is ttyO0 or ttyS0.

    BR
    Ivan

  • arch=arm
    baudrate=115200
    board=am335x
    board_name=FLogicSi
    board_rev=B.01
    boot_fdt=try
    boot_targets= mmc0 nand
    bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
    bootcmd_mmc0=setenv devnum 0; setenv rootpart 2; run mmc_boot;
    bootcmd_nand=run nandboot;
    bootcmd_usb=setenv devnum 0; run usb_boot;
    bootdelay=3
    bootdir=/boot
    bootenv=uEnv.txt
    bootfile=kernelDM
    bootpart=0:2
    console=ttyO0,115200n8
    cpu=armv7
    dfu_alt_info_emmc=rawemmc mmc 0 3751936
    dfu_alt_info_mmc=boot part 0 1;rootfs part 0 2;MLO fat 0 1;MLO.raw mmc 100 100;u-boot.img.raw mmc 300 400;spl-os-args.raw mmc 80 80;spl-os-image.raw mmc 900 2000;spl-o1
    dfu_alt_info_nand=NAND.SPL part 0 1;NAND.SPL.backup1 part 0 2;NAND.SPL.backup2 part 0 3;NAND.SPL.backup3 part 0 4;NAND.u-boot-spl-os part 0 5;NAND.u-boot part 0 6;NAND0
    dfu_alt_info_ram=kernel ram 0x80200000 0xD80000;fdt ram 0x80F80000 0x80000;ramdisk ram 0x81000000 0x4000000
    dnsip=10.0.0.1
    eth1addr=d0:ff:50:b3:58:2e
    ethact=cpsw
    ethaddr=d0:ff:50:b3:58:2c
    fdt_high=0xa0000000
    fdtaddr=0x80F80000
    fdtfile=am335x-flsi-usb.dtb
    fileaddr=80f80000
    filesize=84e7
    findfdt=if test $board_name = A335BONE; then setenv fdtfile am335x-bone.dtb; fi; if test $board_name = A335BNLT; then setenv fdtfile am335x-boneblack.dtb; fi; if test
    gatewayip=10.0.0.1
    importbootenv=echo Importing environment from mmc ...; env import -t $loadaddr $filesize
    ipaddr=10.0.0.32
    loadaddr=0x80200000
    loadbootenv=load mmc ${mmcdev} ${loadaddr} ${bootenv}
    loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}
    loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}
    loadramdisk=load mmc ${mmcdev} ${rdaddr} ramdisk.gz
    mmc_boot=setenv devtype mmc; if mmc dev ${devnum}; then run mmcargs;run scan_boot; run mmcboot;setenv mmcdev 1; setenv bootpart 1:2; run mmcboot;fi
    mmcargs=setenv bootargs console=${console} ${optargs} root=${mmcroot} rootfstype=${mmcrootfstype}
    mmcboot=mmc dev ${mmcdev}; if mmc rescan; then echo SD/MMC found on device ${mmcdev};if run loadbootenv; then echo Loaded environment from ${bootenv};run importbootenv;
    mmcdev=0
    mmcloados=run mmcargs; if test ${boot_fdt} = yes || test ${boot_fdt} = try; then if run loadfdt; then bootz ${loadaddr} - ${fdtaddr}; else if test ${boot_fdt} = try; t;
    mmcroot=/dev/mmcblk0p2 ro
    mmcrootfstype=ext4 rootwait
    mtdids=nand0=nand.0
    mtdparts=mtdparts=nand.0:128k(NAND.SPL),128k(NAND.SPL.backup1),128k(NAND.SPL.backup2),128k(NAND.SPL.backup3),256k(NAND.u-boot-spl-os),1m(NAND.u-boot),128k(NAND.u-boot-)
    nandargs=setenv bootargs console=${console} ${optargs} root=${nandroot} rootfstype=${nandrootfstype}
    nandboot=echo Booting from nand ...; run nandargs; nand read ${fdtaddr} NAND.u-boot-spl-os; nand read ${loadaddr} NAND.kernel; bootz ${loadaddr} - ${fdtaddr}
    nandroot=ubi0:rootfs rw ubi.mtd=NAND.file-system,2048
    nandrootfstype=ubifs rootwait=1
    netargs=setenv bootargs console=${console} ${optargs} root=/dev/nfs nfsroot=${serverip}:${rootpath},${nfsopts} rw ip=dhcp
    netboot=echo Booting from network ...; setenv autoload no; dhcp; tftp ${loadaddr} ${bootfile}; tftp ${fdtaddr} ${fdtfile}; run netargs; bootz ${loadaddr} - ${fdtaddr}
    netmask=255.0.0.0
    nfsopts=nolock
    partitions=uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    ramargs=setenv bootargs console=${console} ${optargs} root=${ramroot} rootfstype=${ramrootfstype}
    ramboot=echo Booting from ramdisk ...; run ramargs; bootz ${loadaddr} ${rdaddr} ${fdtaddr}
    ramroot=/dev/ram0 rw ramdisk_size=65536 initrd=${rdaddr},64M
    ramrootfstype=ext2
    rdaddr=0x81000000
    rootpart=2
    rootpath=/export/rootfs
    scan_boot=echo Scanning ${devtype} ${devnum}...; for prefix in ${bootdir}; do for script in ${bootfile}; do run script_boot; done; done;
    script_boot=if load ${devtype} ${devnum}:${rootpart} ${loadaddr} ${bootdir}/${bootfile}; then run findfdt; load ${devtype} ${devnum}:${rootpart} ${fdtaddr} ${bootdir}/;
    serverip=10.0.0.10
    soc=am33xx
    spiargs=setenv bootargs console=${console} ${optargs} root=${spiroot} rootfstype=${spirootfstype}
    spiboot=echo Booting from spi ...; run spiargs; sf probe ${spibusno}:0; sf read ${loadaddr} ${spisrcaddr} ${spiimgsize}; bootz ${loadaddr}
    spibusno=0
    spiimgsize=0x362000
    spiroot=/dev/mtdblock4 rw
    spirootfstype=jffs2
    spisrcaddr=0xe0000
    static_ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}::off
    stderr=serial
    stdin=serial
    stdout=serial
    usb_boot=setenv devtype usb; run usb_init; if usb dev 0; then run usbargs;run scan_boot; bootz ${loadaddr} - ${fdtaddr}; fi
    usb_init=usb start 0;
    usbargs=setenv bootargs console=${console} ${optargs} root=${usbroot} rootfstype=${usbrootfstype}
    usbnet_devaddr=d0:ff:50:b3:58:2e
    usbroot=/dev/sda2 rw
    usbrootfstype=ext4 rootwait
    vendor=ti
    ver=U-Boot 2013.10-00189-g78d8ebd-dirty (Oct 15 2014 - 17:35:33)

    Environment size: 5565/131067 bytes

    This is output of printenv. I think variable console is correct. 

    And in the menuconfig of the kernel i have this value:

    root=/dev/mmcblk0p2 rootwait console=ttyO0,115200 

    BR

    Daniel 

  • Hi Daniel,

    Please see the:
    processors.wiki.ti.com/.../Linux_Core_U-Boot_User%27s_Guide
    and Networking Environment

    Also see the post "e2e.ti.com/.../1163824" if your case is not the same

    BR
    Ivan