From 9e4231e908d4d1f62db34295466419d49af8ab49 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Tue, 8 Oct 2019 14:01:55 +0200 Subject: more basic support for sd card creation for phytec-imx6 --- scripts/install.sh | 17 +++++++++++++---- target/arm/Makefile | 2 +- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/scripts/install.sh b/scripts/install.sh index 5f929b26a..9f0debac9 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash #- -# Copyright © 2010-2017 +# Copyright © 2010-2019 # Waldemar Brodkorb # Thorsten Glaser # @@ -155,7 +155,7 @@ tgt=$2 src=$3 case $target { -(banana-pro|orange-pi0|pcengines-apu|phytec-wega|raspberry-pi|raspberry-pi0|raspberry-pi2|raspberry-pi3|raspberry-pi3-64|raspberry-pi3p|raspberry-pi3p-64|solidrun-imx6|solidrun-clearfog|default) ;; +(banana-pro|orange-pi0|pcengines-apu|phytec-imx6|phytec-wega|raspberry-pi|raspberry-pi0|raspberry-pi2|raspberry-pi3|raspberry-pi3-64|raspberry-pi3p|raspberry-pi3p-64|solidrun-imx6|solidrun-clearfog|default) ;; (*) print -u2 "Unknown target '$target', exiting" exit 1 ;; @@ -551,7 +551,7 @@ case $target { (solidrun-clearfog) dd if="$fwdir/u-boot-spl.kwb" of="$tgt" bs=512 seek=1 > /dev/null 2>&1 ;; -(solidrun-imx6) +(solidrun-imx6|phytec-imx6) dd if="$fwdir/SPL" of="$tgt" bs=1024 seek=1 > /dev/null 2>&1 dd if="$fwdir/u-boot.img" of="$tgt" bs=1024 seek=69 > /dev/null 2>&1 ;; @@ -581,7 +581,7 @@ if (( datafssz )); then (banana-pro|orange-pi0|solidrun-clearfog) echo "/dev/mmcblk0p2 /data ext4 rw 0 0" >> "$R"/etc/fstab ;; - (solidrun-imx6) + (solidrun-imx6|phytec-imx6) echo "/dev/mmcblk1p2 /data ext4 rw 0 0" >> "$R"/etc/fstab ;; } @@ -645,6 +645,15 @@ case $target { -n "SolidrunImx6" \ -d $fwdir/boot.script.imx6 $R/boot/boot.scr.uimg ;; +(phytec-imx6) + for x in "$fwdir"/*.dtb; do + [[ -e "$x" ]] && cp "$fwdir"/*.dtb "$R/boot/" + break + done + mkimage -A arm -O linux -T script -C none -a 0 -e 0 \ + -n "PhytecImx6" \ + -d $fwdir/boot.script.phytec $R/boot/boot.scr.uimg + ;; (orange-pi0) for x in "$fwdir"/*.dtb; do [[ -e "$x" ]] && cp "$fwdir"/*.dtb "$R/boot/" diff --git a/target/arm/Makefile b/target/arm/Makefile index 5b7be214b..b5530bb0f 100644 --- a/target/arm/Makefile +++ b/target/arm/Makefile @@ -81,7 +81,7 @@ ifeq ($(ADK_TARGET_SYSTEM_PHYTEC_WEGA),y) endif ifeq ($(ADK_TARGET_SYSTEM_PHYTEC_IMX6),y) @echo "Use following command to install it on SD card:" - @echo "sudo ./scripts/install.sh phytec-mira /dev/sdX $(FW_DIR)/$(ROOTFSTARBALL)" + @echo "sudo ./scripts/install.sh phytec-imx6 /dev/sdX $(FW_DIR)/$(ROOTFSTARBALL)" @echo endif ifeq ($(ADK_TARGET_SYSTEM_BANANA_PRO),y) -- cgit v1.2.3