June 18, 2024

Antminer S9 U-boot install - U-boot environment

I typed "printenv" while I was at the u-boot prompt running my shortcut SD card and this is what I saw before I made additions so that it would do network booting.
baudrate=115200
bitstream_image=system.bit.bin
boot_image=BOOT.bin
boot_size=0xF00000
bootargs=noinitrd mem=496M console=ttyPS0,115200 root=ubi0:rootfs ubi.mtd=1 rootfstype=ubifs rw rootwait
bootcmd=run $modeboot
bootdelay=3
bootenv=uEnv.txt
devicetree_image=devicetree.dtb
devicetree_size=0x20000
ethact=Gem.e000b000
ethaddr=00:0a:35:00:01:22
fdt_high=0x20000000
importbootenv=echo Importing environment from SD ...; env import -t ${loadbootenv_addr} $filesize
initrd_high=0x20000000
ipaddr=10.10.70.102
jtagboot=echo TFTPing Linux to RAM... && tftpboot 0x3000000 ${kernel_image} && tftpboot 0x2A00000 ${devicetree_image} && tftpboot 0x2000000 ${ramdisk_image} && bootm 0x3000000 0x2000000 0x2A00000
kernel_image=uImage
kernel_size=0x800000
loadbit_addr=0x100000
loadbootenv=fatload mmc 0 ${loadbootenv_addr} ${bootenv}
loadbootenv_addr=0x2000000
mmc_loadbit_fat=echo Loading bitstream from SD/MMC/eMMC to RAM.. && mmcinfo && fatload mmc 0 ${loadbit_addr} ${bitstream_image} && fpga load 0 ${loadbit_addr} ${filesize}
modeboot=sdboot
nandboot=echo Copying Linux from NAND flash to RAM... && nand read 0x2000000 0x1100000 ${kernel_size} && nand read 0x3000000 0x1020000 ${devicetree_size} && bootm 0x2000000 - 0x3000000
nandroot=/dev/mtdblock2
nandrootfstype=jffs2
norboot=echo Copying Linux from NOR flash to RAM... && cp.b 0xE2100000 0x3000000 ${kernel_size} && cp.b 0xE2600000 0x2A00000 ${devicetree_size} && echo Copying ramdisk... && cp.b 0xE2620000 0x2000000 ${ramdisk_size} && bootm 0x3000000 0x2000000 0x2A00000
qspiboot=echo Copying Linux from QSPI flash to RAM... && sf probe 0 0 0 && sf read 0x3000000 0x100000 ${kernel_size} && sf read 0x2A00000 0x600000 ${devicetree_size} && echo Copying ramdisk... && sf read 0x2000000 0x620000 ${ramdisk_size} && bootm 0x3000000 0x2000000 0x2A00000
ramdisk_image=uramdisk.image.gz
ramdisk_size=0x5E0000
rsa_jtagboot=echo TFTPing Image to RAM... && tftpboot 0x100000 ${boot_image} && zynqrsa 0x100000 && bootm 0x3000000 0x2000000 0x2A00000
rsa_nandboot=echo Copying Image from NAND flash to RAM... && nand read 0x100000 0x0 ${boot_size} && zynqrsa 0x100000 && bootm 0x3000000 0x2000000 0x2A00000
rsa_norboot=echo Copying Image from NOR flash to RAM... && cp.b 0xE2100000 0x100000 ${boot_size} && zynqrsa 0x100000 && bootm 0x3000000 0x2000000 0x2A00000
rsa_qspiboot=echo Copying Image from QSPI flash to RAM... && sf probe 0 0 0 && sf read 0x100000 0x0 ${boot_size} && zynqrsa 0x100000 && bootm 0x3000000 0x2000000 0x2A00000
rsa_sdboot=echo Copying Image from SD to RAM... && fatload mmc 0 0x100000 ${boot_image} && zynqrsa 0x100000 && bootm 0x3000000 0x2000000 0x2A00000
sdboot=if mmcinfo; then run uenvboot; echo Copying Linux from SD to RAM... && fatload mmc 0 0x2000000 ${kernel_image} && fatload mmc 0 0x3000000 ${devicetree_image} && fatload mmc 0 0x4000000 ${ramdisk_image} && bootm 0x2000000 0x4000000 0x3000000; fi
serverip=10.10.70.101
stderr=serial
stdin=serial
stdout=serial
uenvboot=if run loadbootenv; then echo Loaded environment from ${bootenv}; run importbootenv; fi; if test -n $uenvcmd; then echo Running uenvcmd ...; run uenvcmd; fi
usbboot=if usb start; then run uenvboot; echo Copying Linux from USB to RAM... && fatload usb 0 0x3000000 ${kernel_image} && fatload usb 0 0x2A00000 ${devicetree_image} && fatload usb 0 0x2000000 ${ramdisk_image} && bootm 0x3000000 0x2000000 0x2A00000; fi

Feedback? Questions? Drop me a line!

Tom's Computer Info / [email protected]