Linux hangs on Tegra 2 / U-Boot board

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

As I explained in a previous post, I have a Tegra2 based board (Harmony)
and (thanks to your help) I successfully managed to flash and boot U-Boot.

However, I’ve been trying to boot Linux from U-Boot but to no avail. Once the
device runs U-boot, I load a Linux image into memory over TFTP, run the
command “bootm”, and then Linux immediately hangs after printing message
“Starting kernel ...".

I’ve tried multiple suggestions I’ve seen online: defining linux console
boot in the “bootargs” parameter in case it is a console misconfiguration,
recompile the kernel with CONFIG_DEBUG_LL to diagnose the problem, and check
the machine id (by providing machine id 0xAAB in the environment var
“machid”). In all these attempts there is no change whatsoever in the output.

I’d be really grateful if someone could give me a hand on this. So, here’s
the details.

1. I’m using the kernel from git://nv-tegra.nvidia.com/linux-2.6.git,
pulled today and configured as indicated in the doc (make tegra_defconfig);
the compilation also creates a uImage for U-Boot. I’m using the latest version
of U-Boot, compiled locally using the standard procedure.

2. First, I flash U-boot and boot the device. U-boot looks for the bootstrap
scripts on several locations and it fails (as it would be expected). At this
point the current environment variables are:

----------------------------------------
Tegra2 (Harmony) # printenv
arch=arm
baudrate=115200
board=harmony
boot_fstypes=ext2  fat
boot_prefixes=/ /boot/
boot_scripts=boot.scr.uimg boot.scr
boot_targets=mmc1 mmc0 usb0 dhcp
bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
bootcmd_dhcp=run usb_init; if dhcp ${scriptaddr} boot.scr.uimg; then source
        ${scriptaddr}; fi
bootcmd_mmc0=setenv devnum 0; run mmc_boot;
bootcmd_mmc1=setenv devnum 1; run mmc_boot;
bootcmd_usb0=setenv devnum 0; run usb_boot;
bootdelay=2
bootfile=;
cpu=armv7
devnum=0
devtype=usb
ethact=sms0
fdt_high=01100000
fdt_load=0x01000000
loadaddr=0x408000
mmc_boot=setenv devtype mmc; if mmc dev ${devnum}; then run scan_boot; fi
rootpart=1
scan_boot=echo Scanning ${devtype} ${devnum}...; for fs in ${boot_fstypes};
        do for prefix in ${boot_prefixes}; do for script in ${boot_scripts};
        do run script_boot; done; done; done;
script_boot=if ${fs}load ${devtype} ${devnum}:${rootpart} ${scriptaddr}
        ${prefix}${script}; then echo ${script} found! Executing ...;source
        ${scriptaddr};fi;
scriptaddr=0x400000
soc=tegra2
stderr=serial
stdin=serial
stdout=serial
usb_boot=setenv devtype usb; run usb_init; if usb dev ${devnum}; then 
        run scan_boot; fi
usb_init=if ${usb_need_init}; then set usb_need_init false; usb start 0; fi
usb_need_init=false
vendor=nvidia
----------------------------------------

3. Then, I define some vars to tell U-boot how to fetch the uImage remotely. 
Here’s the sequence of commands:

----------------------------------------
Tegra2 (Harmony) # setenv autoload no
Tegra2 (Harmony) # dhcp
Waiting for Ethernet connection... done.
BOOTP broadcast 1
BOOTP broadcast 2
*** Unhandled DHCP Option in OFFER/ACK: 252
...
*** Unhandled DHCP Option in OFFER/ACK: 52
DHCP client bound to address <my-device-ip>
Tegra2 (Harmony) # setenv serverip <my-host-ip>
Tegra2 (Harmony) # setenv bootfile uImage
Tegra2 (Harmony) # setenv bootargs "mem=1024M console=ttyS0,115200n8
        root=/dev/sda1 rw rootwait"
----------------------------------------

4. Next, I tell u-boot to load the uImage file:

----------------------------------------
Tegra2 (Harmony) # tftpboot
Waiting for Ethernet connection... done.
Using sms0 device
TFTP from server <my-host-ip>; our IP address is <my-device-ip>
Filename 'uImage'.
Load address: 0x408000
Loading: EHCI timed out on TD - token=0x8008d80
T #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         #################################################################
         ##########################################
done
Bytes transferred = 3540180 (3604d4 hex)
----------------------------------------

5. And then tell it to boot the kernel from memory:

----------------------------------------
Tegra2 (Harmony) # bootm
## Booting kernel from Legacy Image at 00408000 ...
   Image Name:   Linux-2.6.36.3
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3540116 Bytes = 3.4 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...
----------------------------------------

And then it hangs here. When I compile the kernel with the debug flag, I see
no additional output. I’ve also tried to load uImage to a different address
without any changes.

Many thanks in advance!
--Nuno

--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [ARM Kernel]     [Linux ARM]     [Linux ARM MSM]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux