bananapi: add initramfs fwupdate support

This commit is contained in:
Calin Crisan 2017-03-17 20:27:32 +02:00
parent 36f441a690
commit 2e7c4ff074
7 changed files with 30 additions and 5 deletions

View File

@ -1,8 +1,8 @@
setenv bootargs console=tty1 root=/dev/mmcblk0p2 rootwait panic=10 earlyprintk quiet loglevel=1 ipv6.disable=1 ${extra}
setenv fdt_high ffffffff
setenv video-mode sunxi:1024x768-24@60,monitor=hdmi,hpd=1,edid=1
fatload mmc 0 0x43000000 sun7i-a20-bananapi.dtb
fatload mmc 0 0x41000000 uImage
fatload mmc 0 0x43000000 sun7i-a20-bananapi.dtb
fatload mmc 0 0x45000000 uInitrd
bootm 0x43000000 0x41000000 0x45000000
bootm 0x41000000 0x45000000 0x43000000

View File

@ -1,7 +1,7 @@
setenv bootargs console=tty1 root=/dev/mmcblk0p2 rootwait panic=10 earlyprintk quiet loglevel=1 ipv6.disable=1 ${extra}
setenv fdt_high ffffffff
setenv video-mode sunxi:1024x768-24@60,monitor=hdmi,hpd=1,edid=1
fatload mmc 0 0x43000000 sun7i-a20-bananapi.dtb
fatload mmc 0 0x41000000 uImage
bootm 0x43000000 - 0x45000000
fatload mmc 0 0x43000000 sun7i-a20-bananapi.dtb
bootm 0x41000000 - 0x43000000

View File

@ -0,0 +1,7 @@
#!/bin/sh
if [ -f /boot/boot-normal.scr ]; then
mv /boot/boot.scr /boot/boot-fwupdater.scr
mv /boot/boot-normal.scr /boot/boot.scr
fi

View File

@ -1,6 +1,6 @@
#!/bin/bash
if [ -f /boot/boot-fwupdater.scr ] then
if [ -f /boot/boot-fwupdater.scr ]; then
mv /boot/boot.scr /boot/boot-normal.scr
mv /boot/boot-fwupdater.scr /boot/boot.scr
fi

View File

@ -8,3 +8,5 @@ cp $IMG_DIR/sun7i-a20-bananapi.dtb $BOOT_DIR
$UBOOT_HOST_DIR/tools/mkimage -C none -A arm -T script -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
$UBOOT_HOST_DIR/tools/mkimage -C none -A arm -T script -d $BOARD_DIR/boot-fwupdater.cmd $BOOT_DIR/boot-fwupdater.scr
cp $BOARD_DIR/uInitrd $BOOT_DIR

BIN
board/bananapi/uInitrd Normal file

Binary file not shown.

View File

@ -0,0 +1,16 @@
BR2_arm=y
BR2_cortex_a7=y
BR2_ARM_FPU_NEON_VFPV4=y
BR2_DL_DIR="$(TOPDIR)/.download"
BR2_CCACHE=y
BR2_CCACHE_DIR="$(TOPDIR)/.buildroot-ccache-bananapi-initramfs"
BR2_OPTIMIZE_2=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TARGET_OPTIMIZATION="-pipe"
BR2_ROOTFS_SKELETON_CUSTOM=y
BR2_ROOTFS_SKELETON_CUSTOM_PATH="board/common/skeleton-initramfs"
BR2_ROOTFS_OVERLAY="board/common/overlay-initramfs board/bananapi/overlay-initramfs"
BR2_PACKAGE_BUSYBOX_CONFIG="board/common/busybox_initramfs.config"
BR2_TARGET_ROOTFS_CPIO=y
BR2_TARGET_ROOTFS_CPIO_UIMAGE=y
# BR2_TARGET_ROOTFS_TAR is not set