Add sun8i target config.
This commit is contained in:
15
projects/sun8i-h2_domo/uboot/boot.cmd
Normal file
15
projects/sun8i-h2_domo/uboot/boot.cmd
Normal file
@@ -0,0 +1,15 @@
|
||||
gpio set PL10
|
||||
gpio set PG11
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
setenv machid 1029
|
||||
setenv bootm_boot_mode sec
|
||||
setenv bootargs "console=ttyS0,115200 rootwait cgroup_enable=memory swapaccount=1 sunxi_ve_mem_reserve=0 sunxi_g2d_mem_reserve=0 sunxi_no_mali_mem_reserve sunxi_fb_mem_reserve=16 panic=10 consoleblank=0 enforcing=0"
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
fatload mmc 0 ${fdt_addr_r} script.bin
|
||||
fatload mmc 0 ${ramdisk_addr_r} rootfs.cpio.uboot
|
||||
fatload mmc 0 ${kernel_addr_r} zImage
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
bootz ${kernel_addr_r} ${ramdisk_addr_r}
|
||||
20
projects/sun8i-h2_domo/uboot/dev.cmd
Normal file
20
projects/sun8i-h2_domo/uboot/dev.cmd
Normal file
@@ -0,0 +1,20 @@
|
||||
gpio set PL10
|
||||
gpio set PG11
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
setenv machid 1029
|
||||
setenv bootm_boot_mode sec
|
||||
setenv bootargs "console=ttyS0,115200 rootwait cgroup_enable=memory swapaccount=1 sunxi_ve_mem_reserve=0 sunxi_g2d_mem_reserve=0 sunxi_no_mali_mem_reserve sunxi_fb_mem_reserve=16 panic=10 consoleblank=0 enforcing=0"
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
fatload mmc 0 ${fdt_addr_r} script.bin
|
||||
|
||||
setenv ipaddr 192.168.9.50
|
||||
setenv serverip 192.168.9.174
|
||||
|
||||
# dhcp ${ramdisk_addr_r} rootfs.cpio.uboot
|
||||
tftp ${ramdisk_addr_r} rootfs.cpio.uboot
|
||||
tftp ${kernel_addr_r} zImage
|
||||
|
||||
#--------------------------------------------------------------------------------------------------------------------------------
|
||||
bootz ${kernel_addr_r} ${ramdisk_addr_r}
|
||||
34
projects/sun8i-h2_domo/uboot/uEnv.txt
Normal file
34
projects/sun8i-h2_domo/uboot/uEnv.txt
Normal file
@@ -0,0 +1,34 @@
|
||||
cpu=armv7
|
||||
arch=arm
|
||||
baudrate=115200
|
||||
board=sunxi
|
||||
board_name=sunxi
|
||||
bootdelay=2
|
||||
soc=sunxi
|
||||
stderr=serial
|
||||
stdin=serial
|
||||
stdout=serial
|
||||
boot_prefixes=/ /boot/
|
||||
boot_scripts=boot.scr boot.scr.uimg
|
||||
boot_targets=fel mmc0 mmc1
|
||||
bootcmd=run distro_bootcmd
|
||||
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
|
||||
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_mmc1=setenv devnum 1; run mmc_boot
|
||||
mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi
|
||||
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_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_scripts; done;
|
||||
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
|
||||
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
|
||||
console=ttyS0,115200
|
||||
mac_addr=00:1B:A0:15:0F:AF
|
||||
scriptaddr=0x43100000
|
||||
fdt_addr_r=0x43000000
|
||||
kernel_addr_r=0x42000000
|
||||
ramdisk_addr_r=0x43300000
|
||||
dev=run dev_boot
|
||||
dev_boot=mmc dev 0; fatload mmc 0:1 ${scriptaddr} dev.scr; source ${scriptaddr}
|
||||
update=run update_scr
|
||||
update_scr=mmc dev 0; fatload mmc 0:1 ${scriptaddr} update.scr; source ${scriptaddr}
|
||||
is_configured=0
|
||||
13
projects/sun8i-h2_domo/uboot/update.cmd
Normal file
13
projects/sun8i-h2_domo/uboot/update.cmd
Normal file
@@ -0,0 +1,13 @@
|
||||
|
||||
|
||||
|
||||
|
||||
usb start
|
||||
dhcp ${kernel_addr_r} zImage
|
||||
fatwrite mmc 0:1 ${fileaddr} zImage ${filesize}
|
||||
tftp ${fdt_addr_r} bcm2708-rpi-b.dtb
|
||||
fatwrite mmc 0:1 ${fileaddr} bcm2708-rpi-b-plus.dtb ${filesize}
|
||||
tftp ${ramdisk_addr_r} rootfs.cpio.uboot
|
||||
fatwrite mmc 0:1 ${fileaddr} rootfs.cpio.uboot ${filesize}
|
||||
setenv bootargs console=ttyAMA0,115200
|
||||
bootz ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}
|
||||
Reference in New Issue
Block a user