Actions
PinePhoneBraveheartBootloader¶
Boot log¶
When it was leant to me, the person lending it to me tried many distros. The last distro tried was PostMarketOS.
U-Boot SPL 2020.01 (Jan 09 2020 - 12:17:54 +0000) DRAM: 2048 MiB Trying to boot from MMC1 NOTICE: BL31: v2.1(release):v3.10.0_rc3-151-ga4b61dc7d9 NOTICE: BL31: Built : 16:21:59, Jun 12 2019 NOTICE: BL31: Detected Allwinner A64/H64/R18 SoC (1689) NOTICE: BL31: Found U-Boot DTB at 0x408e1a8, model: Pine64 LTS NOTICE: BL31: PMIC: Detected AXP803 on RSB. U-Boot 2020.01 (Jan 09 2020 - 12:17:54 +0000) Allwinner Technology CPU: Allwinner A64 (SUN50I) Model: Pine64 LTS DRAM: 2 GiB MMC: mmc@1c0f000: 0, mmc@1c11000: 1 Loading Environment from FAT... Unable to use mmc 1:1... In: serial Out: serial Err: serial Net: phy interface7 Could not get PHY for ethernet@1c30000: addr 1 No ethernet found. starting USB... Bus usb@1c1a000: USB EHCI 1.00 Bus usb@1c1a400: USB OHCI 1.0 Bus usb@1c1b000: USB EHCI 1.00 Bus usb@1c1b400: USB OHCI 1.0 scanning bus usb@1c1a000 for devices... 1 USB Device(s) found scanning bus usb@1c1a400 for devices... 1 USB Device(s) found scanning bus usb@1c1b000 for devices... 1 USB Device(s) found scanning bus usb@1c1b400 for devices... 1 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0 switch to partitions #0, OK mmc0 is current device Scanning mmc 0:1... Found U-Boot script /boot.scr 919 bytes read in 7 ms (127.9 KiB/s) ## Executing script at 4fc00000 gpio: pin 114 (gpio 114) value is 1 Booting from SD 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=if fdt addr ${fdt_addr_r}; then bootefi bootmgr ${fdt_addr_r};else bootefi bootmgr ${fdtcontroladdr};fi;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}${boot_syslinux_conf} boot_net_usb_start=usb start boot_prefixes=/ /boot/ boot_script_dhcp=boot.scr.uimg boot_scripts=boot.scr.uimg boot.scr boot_syslinux_conf=extlinux/extlinux.conf boot_targets=fel mmc_auto usb0 pxe dhcp bootargs=init=/init.sh rw console=tty0 console=ttyS0,115200 no_console_suspend earlycon=uart,mmio32,0x01c28000 panic=10 consoleblank=0 loglevel=1 cma=256M PMOS_NO_OUTPUT_REDIRECT pmos_boot=/dev/mmcblk0p1 pmos_root=/dev/mmcblk0p2 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=devnum=0; run mmc_boot bootcmd_mmc1=devnum=1; run mmc_boot bootcmd_mmc_auto=if test ${mmc_bootdev} -eq 1; then run bootcmd_mmc1; run bootcmd_mmc0; elif test ${mmc_bootdev} -eq 0; then run bootcmd_mmc0; run bootcmd_mmc1; fi bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi bootcmd_usb0=devnum=0; run usb_boot bootdelay=2 bootdev=0 bootfstype=ext4 bootm_size=0xa000000 console=ttyS0,115200 cpu=armv8 devplist=1 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:83:c7:f4:f3 fdt_addr_r=0x4FA00000 fdtcontroladdr=b9f31258 fdtfile=allwinner/sun50i-a64-pine64-lts.dtb fileaddr=4fc00000 filesize=397 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 devtype=mmc; run scan_dev_for_boot_part; fi mmc_bootdev=0 partitions=name=loader1,start=8k,size=32k,uuid=${uuid_gpt_loader1};name=loader2,size=984k,uuid=${uuid_gpt_loader2};name=esp,size=128M,bootable,uuid=${uuid_gpt_esp};name=system,size=-,uuid=${uuid_gpt_system}; 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; setenv devplist 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}${boot_syslinux_conf}; then echo Found ${prefix}${boot_syslinux_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#=92c08dba83c7f4f3 soc=sunxi stderr=serial,vidconsole stdin=serial,usbkbd stdout=serial,vidconsole usb_boot=usb start; if usb dev ${devnum}; then devtype=usb; run scan_dev_for_boot_part; fi uuid_gpt_esp=c12a7328-f81f-11d2-ba4b-00a0c93ec93b uuid_gpt_system=b921b045-1df0-41c3-af44-4c6f280d3fae Environment size: 4745/131068 bytes Loading DTB 30085 bytes read in 14 ms (2 MiB/s) Loading Initramfs 4584216 bytes read in 220 ms (19.9 MiB/s) Loading Kernel 15091720 bytes read in 708 ms (20.3 MiB/s) gpio: pin 115 (gpio 115) value is 1 Resizing FDT Booting kernel gpio: pin 116 (gpio 116) value is 1 ## Loading init Ramdisk from Legacy Image at 4fe00000 ... Image Name: uInitrd Image Type: AArch64 Linux RAMDisk Image (uncompressed) Data Size: 4584152 Bytes = 4.4 MiB Load Address: 00000000 Entry Point: 00000000 Verifying Checksum ... OK ## Flattened Device Tree blob at 4fa00000 Booting using the fdt blob at 0x4fa00000 EHCI failed to shut down host controller. Loading Ramdisk to 49ba0000, end 49fff2d8 ... OK Loading Device Tree to 0000000049b95000, end 0000000049b9ffff ... OK Starting kernel ... [ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034] [ 0.000000] Linux version 5.4.0 (pmos@msi) (gcc version 9.2.0 (Alpine 9.2.0)) #3-postmarketos-allwinner SMP Sat Jan 18 16:55:25 UTC 2020 [ 0.000000] Machine model: PinePhone [ 0.000000] earlycon: uart0 at MMIO32 0x0000000001c28000 (options '') [ 0.000000] printk: bootconsole [uart0] enabled ### postmarketOS initramfs ### Configuring kernel firmware image search path modprobe: module sun6i_mipi_dsi not found in modules.dep modprobe: module sun4i_drm not found in modules.dep modprobe: module pwm_sun4i not found in modules.dep modprobe: module sun8i_mixer not found in modules.dep modprobe: module ext4 not found in modules.dep modprobe: module usb_f_rndis not found in modules.dep NOTE: Waiting 10 seconds for the framebuffer /dev/fb0. If your device does not have a framebuffer, disable this with: no_framebuffer=true in <https://postmarketos.org/deviceinfo> Setting framebuffer mode to: U:720x1440p-0 Setup usb network /sys/class/android_usb does not exist, skipping android_usb Setting up an USB gadget through configfs Starting udhcpd Using interface usb0 Start the dhcpcd daemon (forks into background) Mount boot partition (/dev/mmcblk0p1) Extract /boot/initramfs-postmarketos-allwinner-extra 31639 blocks Check/repair root filesystem (/dev/mmcblk0p2) e2fsck 1.45.5 (07-Jan-2020) pmOS_root: recovering journal Clearing orphaned inode 81454 (uid=10000, gid=10000, mode=0100600, size=17344) Clearing orphaned inode 81296 (uid=10000, gid=10000, mode=0100600, size=8896) Clearing orphaned inode 81253 (uid=10000, gid=10000, mode=0100600, size=47218) Clearing orphaned inode 81241 (uid=10000, gid=10000, mode=0100600, size=1024) Setting free inodes count to 27171 (was 27176) Setting free blocks count to 81716 (was 81737) pmOS_root: clean, 72989/100160 files, 562892/644608 blocks Resize root filesystem (/dev/mmcblk0p2) resize2fs 1.45.5 (07-Jan-2020) The filesystem is already 644608 (4k) blocks long. Nothing to do! Mount root partition (/dev/mmcblk0p2) umount: can't unmount /dev: Invalid argument OpenRC 0.42.1.6a467d4a81 is starting up Linux 5.4.0 (aarch64) /lib/rc/sh/init.sh: line 15: can't create /dev/null: Read-only file system * md5sum is missing, which suggests /usr is not mounted * If you have separate /usr, it must be mounted by initramfs * If not, you should check coreutils is installed correctly * Mounting /proc ... [ ok ] * Mounting /run ... * /run/openrc: creating directory * /run/lock: creating directory * /run/lock: correcting owner /lib/rc/sh/gendepends.sh: line 28: can't create /dev/null: Read-only file system * Caching service dependencies ... [ ok ] * Clock skew detected with `(null)' * Adjusting mtime of `/run/openrc/deptree' to Sat Jan 18 19:20:37 2020 * WARNING: clock skew detected! * Mounting devtmpfs on /dev ... [ ok ] * Mounting /dev/mqueue ... [ ok ] * Mounting /dev/pts ... [ ok ] * Mounting /dev/shm ... [ ok ] * Mount subpartitions of /dev/mmcblk0 device-mapper: reload ioctl on mmcblk0p1 failed: Resource busy create/reload failed on mmcblk0p1 device-mapper: reload ioctl on mmcblk0p2 failed: Resource busy create/reload failed on mmcblk0p2 * Mount subpartitions of /dev/mmcblk2 * Mounting /sys ... [ ok ] * Mounting security filesystem ... [ ok ] * Mounting debug filesystem ... [ ok ] * Mounting config filesystem ... [ ok ] * Mounting persistent storage (pstore) filesystem ... [ ok ] * Starting udev ... [ ok ] * Generating a rule to create a /dev/root symlink ... [ ok ] * Populating /dev with existing devices through uevents ... [ ok ] * WARNING: clock skew detected! * Loading modules ... [ ok ] * Setting system clock using the hardware clock [UTC] ... [ ok ] * Setting the local clock based on last shutdown time ... [ ok ] * Checking local filesystems .../dev/mmcblk2p2 is in use. e2fsck: Cannot continue, aborting. * Operational error [ !! ] * Remounting root filesystem read/write ... [ ok ] * Remounting filesystems ... [ ok ] * Mounting local filesystems ... [ ok ] * Configuring kernel parameters ...sysctl: error: 'net.ipv4.tcp_syncookies' is an unknown key [ ok ] * Creating user login records ... [ ok ] * Wiping /tmp directory ... [ ok ] * Setting hostname ... [ ok ] * Starting busybox syslog ... [ ok ] * WARNING: clock skew detected! * Starting System Message Bus ... [ ok ] * Starting RNG Daemon ... [ ok ] * Could not find a wireless interface * Starting WPA Supplicant ... [ ok ] * Starting networkmanager ... [ ok ] * Starting chronyd ... [ ok ] * Enabling EG25 WWAN module ... * /run/lightdm: creating directory * /run/lightdm: correcting owner * Starting Display Manager ... [ ok ] * Starting oFono ... [ ok ] * Starting sshd ... [ ok ] * Activating swap file ...Configured swap file size is 0, skipping creation. [ ok ] * Starting urfkill ... [ ok ] * Starting local ... [ ok ] Welcome to postmarketOS Kernel 5.4.0 on an aarch64 (/dev/ttyS0) pine64-pinephone login:
list of available commands¶
=> help ? - alias for 'help' base - print or set address offset bdinfo - print Board Info structure blkcache - block cache diagnostics and control boot - boot default, i.e., run 'bootcmd' bootd - boot default, i.e., run 'bootcmd' bootefi - Boots an EFI payload from memory bootelf - Boot from an ELF image in memory booti - boot Linux kernel 'Image' format from memory bootm - boot application image from memory bootp - boot image via network using BOOTP/TFTP protocol bootvx - Boot vxWorks from an ELF image cmp - memory compare coninfo - print console devices and information cp - memory copy crc32 - checksum calculation dhcp - boot image via network using DHCP/TFTP protocol dm - Driver model low level access echo - echo args to console editenv - edit environment variable env - environment handling commands exit - exit script ext2load - load binary file from a Ext2 filesystem ext2ls - list files in a directory (default /) ext4load - load binary file from a Ext4 filesystem ext4ls - list files in a directory (default /) ext4size - determine a file's size false - do nothing, unsuccessfully fatinfo - print information about filesystem fatload - load binary file from a dos filesystem fatls - list files in a directory (default /) fatmkdir - create a directory fatrm - delete a file fatsize - determine a file's size fatwrite - write file into a dos filesystem fdt - flattened device tree utility commands fstype - Look up a filesystem type go - start application at address 'addr' gpio - query and control gpio pins gpt - GUID Partition Table gzwrite - unzip and write memory to block device help - print command description/usage iminfo - print header information for application image imxtract - extract a part of a multi-image itest - return true/false on integer compare lcdputs - print string on video framebuffer ln - Create a symbolic link load - load binary file from a filesystem loadb - load binary file over serial line (kermit mode) loads - load S-Record file over serial line loadx - load binary file over serial line (xmodem mode) loady - load binary file over serial line (ymodem mode) loop - infinite loop on address range ls - list files in a directory (default /) lzmadec - lzma uncompress a memory region md - memory display mdio - MDIO utility commands mii - MII utility commands mm - memory modify (auto-incrementing address) mmc - MMC sub system mmcinfo - display MMC info mw - memory write (fill) nfs - boot image via network using NFS protocol nm - memory modify (constant address) part - disk partition related commands ping - send ICMP ECHO_REQUEST to network host printenv - print environment variables pxe - commands to get and boot from pxe files random - fill memory with random pattern reset - Perform RESET of the CPU run - run commands in an environment variable save - save file to a filesystem saveenv - save environment variables to persistent storage setcurs - set cursor position within screen setenv - set environment variables setexpr - set environment variable as the result of eval expression sf - SPI flash sub-system showvar - print local hushshell variables size - determine a file's size sleep - delay execution for some time source - run script from memory sysboot - command to get and boot from syslinux files test - minimal test like /bin/sh tftpboot - boot image via network using TFTP protocol true - do nothing, successfully unzip - unzip a memory region usb - USB sub-system usbboot - boot from USB device version - print monitor, compiler and linker version
Environement¶
=> 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=if fdt addr ${fdt_addr_r}; then bootefi bootmgr ${fdt_addr_r};else bootefi bootmgr ${fdtcontroladdr};fi;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}${boot_syslinux_conf} boot_net_usb_start=usb start boot_prefixes=/ /boot/ boot_script_dhcp=boot.scr.uimg boot_scripts=boot.scr.uimg boot.scr boot_syslinux_conf=extlinux/extlinux.conf boot_targets=fel mmc_auto 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=devnum=0; run mmc_boot bootcmd_mmc1=devnum=1; run mmc_boot bootcmd_mmc_auto=if test ${mmc_bootdev} -eq 1; then run bootcmd_mmc1; run bootcmd_mmc0; elif test ${mmc_bootdev} -eq 0; then run bootcmd_mmc0; run bootcmd_mmc1; fi bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi bootcmd_usb0=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:83:c7:f4:f3 fdt_addr_r=0x4FA00000 fdtcontroladdr=b9f31258 fdtfile=allwinner/sun50i-a64-pine64-lts.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 devtype=mmc; run scan_dev_for_boot_part; fi mmc_bootdev=0 partitions=name=loader1,start=8k,size=32k,uuid=${uuid_gpt_loader1};name=loader2,size=984k,uuid=${uuid_gpt_loader2};name=esp,size=128M,bootable,uuid=${uuid_gpt_esp};name=system,size=-,uuid=${uuid_gpt_system}; 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; setenv devplist 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}${boot_syslinux_conf}; then echo Found ${prefix}${boot_syslinux_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#=92c08dba83c7f4f3 soc=sunxi stderr=serial,vidconsole stdin=serial,usbkbd stdout=serial,vidconsole usb_boot=usb start; if usb dev ${devnum}; then devtype=usb; run scan_dev_for_boot_part; fi uuid_gpt_esp=c12a7328-f81f-11d2-ba4b-00a0c93ec93b uuid_gpt_system=b921b045-1df0-41c3-af44-4c6f280d3fae Environment size: 4448/131068 bytes =>
Updated by Denis 'GNUtoo' Carikli over 4 years ago · 2 revisions