Need help : Issue in running compiled kernel with tftp+uboot
#1
Question 
Hi All,

I have tried compiling following component for Pine 64 1GB board (as instruction mentioned at https://github.com/apritzel/pine64)

uboot - (git://git.denx.de/u-boot.git master branch)
kernel -(https://github.com/apritzel/linux.git a64-v4 branch)
( command used to create uImage  "mkimage -A arm64 -O linux -T kernel -C none -a 0x80008000 -e 0x80008000 -n "Linux kernel" -d arch/arm64/boot/Image uImage")
Uboot runs successfully but kernel loading  does not proceed and hangs at "Starting kernel ..." messages  

What I am trying to do is to boot board with NFS+tftp, but not able to proceed beyond uboot.

Detail logs are as follows 

HELLO! BOOT0 is starting!
boot0 commit : 045061a8bb2580cb3fa02e301f52a015040c158f
 
boot0 version : 4.0.0
set pll start
set pll end
rtc[0] value = 0x00000000
rtc[1] value = 0x00000000
rtc[2] value = 0x00000000
rtc[3] value = 0x00000000
rtc[4] value = 0x00000000
rtc[5] value = 0x00000000
DRAM driver version: V1.1
rsb_send_initseq: rsb clk 400Khz -> 3Mhz
PMU: AXP81X
ddr voltage = 1500 mv
DRAM Type = 3 (2:DDR2,3:DDR3,6:LPDDR2,7:LPDDR3)
DRAM clk = 672 MHz
DRAM zq value: 003b3bbb
DRAM single rank full DQ OK
DRAM size = 1024 MB
DRAM init ok
dram size =1024
card boot number = 0, boot0 copy = 0
card no is 0
sdcard 0 line count 4
[mmc]: mmc driver ver 2015-05-08 20:06
[mmc]: sdc0 spd mode error, 2
[mmc]: Wrong media type 0x00000000
[mmc]: ***Try SD card 0***
[mmc]: HSSDR52/SDR25 4 bit
[mmc]: 50000000 Hz
[mmc]: 7388 MB
[mmc]: ***SD/MMC 0 init OK!!!***
sdcard 0 init ok
The size of uboot is 00070000.
sum=816b3f69
src_sum=816b3f69
Succeed in loading uboot from sdmmc flash.
boot0: start load other image
boot0: Loading BL3-1
Loading file 0 at address 0x40000000,size 0x00000200 success
boot0: Loading scp
Loading file 2 at address 0x00040000,size 0x0000c200 success
set arisc reset to de-assert state
Ready to disable icache.
Jump to secend Boot.
NOTICE:  BL3-1: Running on A64/H64 (1689) in SRAM A2 (@0x44000)
NOTICE:  Configuring SPC Controller
NOTICE:  BL3-1: v1.0(debug):cd7fa48
NOTICE:  BL3-1: Built : 02:16:30, Jan 26 2017
NOTICE:  Configuring AXP PMIC
NOTICE:  PMIC: already configured for RSB
NOTICE:  PMIC: setup successful
INFO:    BL3-1: Initializing runtime services
INFO:    BL3-1: Preparing for EL3 exit to normal world
INFO:    BL3-1: Next image address: 0x4a000000, SPSR: 0x3c9


U-Boot 2017.01-00305-gf2b0c00-dirty (Jan 26 2017 - 13:10:48 +0530) Allwinner Technology

CPU:   Allwinner A64 (SUN50I)
Model: Pine64+
DRAM:  1 GiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   phy interface7
eth0: [email protected]
starting USB...
USB0:   USB EHCI 1.00
USB1:   USB OHCI 1.0
scanning bus 0 for devices... 1 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found
Hit any key to stop autoboot:  2 0 
=> 
=> 
=> 
=> 
=> 
=> 
=> printenv 
arch=arm
baudrate=115200
board=sunxi
board_name=sunxi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
boot_efi_binary=load ${devtype} ${devnum}:${distro_bootpart} ${kernel_addr_r} efi/boot/bootaa64.efi; if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r};else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
boot_net_usb_start=usb start
boot_prefixes=/ /boot/
boot_script_dhcp=boot.scr.uimg
boot_scripts=boot.scr.uimg boot.scr
boot_targets=fel mmc0 usb0 pxe dhcp 
bootcmd=run distro_bootcmd
bootcmd_dhcp=run boot_net_usb_start; if dhcp ${scriptaddr} ${boot_script_dhcp}; then source ${scriptaddr}; fi;setenv efi_fdtfile ${fdtfile}; setenv efi_old_vci ${bootp_vci};setenv efi_old_arch ${bootp_arch};setenv bootp_vci PXEClient:Arch:00011:UNDI:003000;setenv bootp_arch 0xb;if dhcp ${kernel_addr_r}; then tftpboot ${fdt_addr_r} dtb/${efi_fdtfile};if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r}; else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi;fi;setenv bootp_vci ${efi_old_vci};setenv bootp_arch ${efi_old_arch};setenv efi_fdtfile;setenv efi_old_arch;setenv efi_old_vci;
bootcmd_fel=if test -n ${fel_booted} && test -n ${fel_scriptaddr}; then echo '(FEL boot)'; source ${fel_scriptaddr}; fi
bootcmd_mmc0=setenv devnum 0; run mmc_boot
bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi
bootcmd_usb0=setenv devnum 0; run usb_boot
bootdelay=2
bootm_size=0xa000000
console=ttyS0,115200
cpu=armv8
dfu_alt_info_ram=kernel ram 0x40080000 0x1000000;fdt ram 0x4FA00000 0x100000;ramdisk ram 0x4FE00000 0x4000000
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
efi_dtb_prefixes=/ /dtb/ /dtb/current/
ethaddr=02:ba:6c:c3:9a:7a
fdt_addr_r=0x4FA00000
fdtcontroladdr=7bf32d38
fdtfile=sun50i-a64-pine64-plus.dtb
kernel_addr_r=0x40080000
load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${prefix}${efi_fdtfile}
mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi
preboot=usb start
pxefile_addr_r=0x4FD00000
ramdisk_addr_r=0x4FE00000
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;run scan_dev_for_efi;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
scan_dev_for_efi=setenv efi_fdtfile ${fdtfile}; for prefix in ${efi_dtb_prefixes}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${efi_fdtfile}; then run load_efi_dtb; fi;done;if test -e ${devtype} ${devnum}:${distro_bootpart} efi/boot/bootaa64.efi; then echo Found EFI removable media binary efi/boot/bootaa64.efi; run boot_efi_binary; echo EFI LOAD FAILED: continuing...; fi; setenv efi_fdtfile
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scriptaddr=0x4FC00000
serial#=92c000ba6cc39a7a
soc=sunxi
stderr=serial
stdin=serial,usbkbd
stdout=serial
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi

Environment size: 3850/131068 bytes
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> ping 10.1.1.134 
*** ERROR: `ipaddr' not set
ping failed; host 10.1.1.134 is not alive
=> printenv 
arch=arm
baudrate=115200
board=sunxi
board_name=sunxi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
boot_efi_binary=load ${devtype} ${devnum}:${distro_bootpart} ${kernel_addr_r} efi/boot/bootaa64.efi; if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r};else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
boot_net_usb_start=usb start
boot_prefixes=/ /boot/
boot_script_dhcp=boot.scr.uimg
boot_scripts=boot.scr.uimg boot.scr
boot_targets=fel mmc0 usb0 pxe dhcp 
bootcmd=run distro_bootcmd
bootcmd_dhcp=run boot_net_usb_start; if dhcp ${scriptaddr} ${boot_script_dhcp}; then source ${scriptaddr}; fi;setenv efi_fdtfile ${fdtfile}; setenv efi_old_vci ${bootp_vci};setenv efi_old_arch ${bootp_arch};setenv bootp_vci PXEClient:Arch:00011:UNDI:003000;setenv bootp_arch 0xb;if dhcp ${kernel_addr_r}; then tftpboot ${fdt_addr_r} dtb/${efi_fdtfile};if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r}; else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi;fi;setenv bootp_vci ${efi_old_vci};setenv bootp_arch ${efi_old_arch};setenv efi_fdtfile;setenv efi_old_arch;setenv efi_old_vci;
bootcmd_fel=if test -n ${fel_booted} && test -n ${fel_scriptaddr}; then echo '(FEL boot)'; source ${fel_scriptaddr}; fi
bootcmd_mmc0=setenv devnum 0; run mmc_boot
bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi
bootcmd_usb0=setenv devnum 0; run usb_boot
bootdelay=2
bootm_size=0xa000000
console=ttyS0,115200
cpu=armv8
dfu_alt_info_ram=kernel ram 0x40080000 0x1000000;fdt ram 0x4FA00000 0x100000;ramdisk ram 0x4FE00000 0x4000000
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
efi_dtb_prefixes=/ /dtb/ /dtb/current/
[email protected]
ethaddr=02:ba:6c:c3:9a:7a
fdt_addr_r=0x4FA00000
fdtcontroladdr=7bf32d38
fdtfile=sun50i-a64-pine64-plus.dtb
kernel_addr_r=0x40080000
load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${prefix}${efi_fdtfile}
mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi
preboot=usb start
pxefile_addr_r=0x4FD00000
ramdisk_addr_r=0x4FE00000
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;run scan_dev_for_efi;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
scan_dev_for_efi=setenv efi_fdtfile ${fdtfile}; for prefix in ${efi_dtb_prefixes}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${efi_fdtfile}; then run load_efi_dtb; fi;done;if test -e ${devtype} ${devnum}:${distro_bootpart} efi/boot/bootaa64.efi; then echo Found EFI removable media binary efi/boot/bootaa64.efi; run boot_efi_binary; echo EFI LOAD FAILED: continuing...; fi; setenv efi_fdtfile
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scriptaddr=0x4FC00000
serial#=92c000ba6cc39a7a
soc=sunxi
stderr=serial
stdin=serial,usbkbd
stdout=serial
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi

Environment size: 3877/131068 bytes
=> ser e et tenv serial# erverip 10.1.1.134
=> setenv serverip 10.1.1.134 5 10.1.1.135 10.1.1.135 10.1.1.135 10.1.1.135 10.1.1.135 10.1.1.135 10.1.1.135 10.1.1.135 i 10.1.1.135 p 10.1.1.135 a 10.1.1.135 d 10.1.1.135 d 10.1.1.135 r 10.1.1.135
=> setenv ipaddr 10.1.1.135                         setenv serverip 10.1.1.134                           printenv         ping 10.1.1.134 
Using [email protected] device
host 10.1.1.134 is alive
=> save
  save saveenv
=> saveenv  
Saving Environment to MMC...
Writing to MMC(0)... done
=> sync
Unknown command 'sync' - try 'help'
=> sync     saveenv         ping 10.1.1.134 
Using et[email protected] device
host 10.1.1.134 is alive
=> tftpboot 0x80200000 uImage_pinr e64
Using [email protected] device
TFTP from server 10.1.1.134; our IP address is 10.1.1.135
Filename 'uImage_pine64'.
Load address: 0x80200000
Loading: * #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
########################
5.1 MiB/s
done
Bytes transferred = 11798080 (b40640 hex)
=> bootm 0x8000 200000
## Booting kernel from Legacy Image at 80200000 ...
   Image Name:   Linux kernel
   Image Type:   AArch64 Linux Kernel Image (uncompressed)
   Data Size:    11798016 Bytes = 11.3 MiB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK

Starting kernel ...
  Reply
#2
Your "bootm 0x8000 200000" is wrong. You should use "booti" with 3 arguments after having also done tftp on uInitrd and sun50i-a64-pine64-plus.dtb :

booti ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}
  Reply
#3
(01-29-2017, 04:33 PM)martinayotte Wrote: Your "bootm 0x8000 200000" is wrong. You should use "booti" with 3 arguments after having also done tftp on uInitrd and sun50i-a64-pine64-plus.dtb :

booti ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}

Hi martinayotte,

Thanks for the reply, Actually I was trying it from last two days to get kernel running but could not proceed further ..

I will try with loading ramdisk and dtb file and booting from the same.
  Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  PineA64+: Audio in 5.0 Kernel puzzles 6 303 11-13-2019, 09:41 AM
Last Post: roel
  Rockpro64 NFS root mount (kernel 4.20) - ethernet help? tenspd137 0 264 12-06-2018, 01:14 AM
Last Post: tenspd137
  NVMe and new kernel bjbb17 0 252 09-25-2018, 03:39 PM
Last Post: bjbb17
  Real-time linux kernel Artyom 45 12,303 09-11-2018, 01:08 AM
Last Post: zzwpine
  DKMS on kernel 3.10.107-pine64 obrienmd 5 706 06-21-2018, 05:45 PM
Last Post: evilbunny
  Kernel for A64 git longsleep 179 58,834 03-25-2018, 03:25 PM
Last Post: Luke
  Gentoo for pine64 - longsleep kernel incoherent 0 827 12-09-2017, 08:14 AM
Last Post: incoherent
  Fedora Running On Pine64! cztian 26 5,264 10-26-2017, 05:51 PM
Last Post: gregjo
  Can't boot headless after running update_uboot.sh Borglesnorgle Williams 2 363 08-17-2017, 04:08 AM
Last Post: Borglesnorgle Williams
  [SOLVED] UEFI + Fedora Mainline Kernel Booting! cztian 0 775 07-13-2017, 08:38 PM
Last Post: cztian

Forum Jump:


Users browsing this thread: 1 Guest(s)