For the cores that support early boot, it is expected that the firmware is available on the boot partition, for U-Boot, as well as on the rootfs partition, for Linux. Therefore copy the default firmware image from the rootfs to the boot partition. The boot partition format is vfat, so it does not support symlinks. Follow symlinks as necessary to get the firmware image into the boot partition.
Signed-off-by: Jacob Stiffler <j-stiff...@ti.com> --- create-sdcard.sh | 50 ++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 10 deletions(-) diff --git a/create-sdcard.sh b/create-sdcard.sh index 5c02a12..c7eb942 100644 --- a/create-sdcard.sh +++ b/create-sdcard.sh @@ -1097,16 +1097,6 @@ fi echo "" echo "" -echo "Syncing..." -sync -sync -sync -sync -sync -sync -sync -sync - if [ "$KERNELFILESOPTION" == "2" ] then @@ -1138,6 +1128,46 @@ then fi + +# The following firmware are required for early boot, and therefore must be +# copied to the boot partition. +RPROC_EARLYBOOT_FIRMWARE = " \ + dra7-ipu1-fw.xem4 \ +" + +for fw in $RPROC_EARLYBOOT_FIRMWARE +do + fw_path="$PATH_TO_SDROOTFS/lib/firmware/$fw" + + # Handle links specifally as they may be absolute paths with respect to the rootfs + if [ -L "$fw_path" ] + then + fw_link=$(readlink "$fw_path") + if [[ "$fw_link" == /* ]] + then + # Absolute path + fw_path="$(readlink "$fw_path" | sed -e "s|^/|$PATH_TO_SDROOTFS/|")" + else + # Relative path + fw_path="$(dirname "$fw_path")/$fw_link" + fi + fi + + # this is a global list of firmwares, so do not fail + cp -f "$fw_path" $PATH_TO_SDBOOT 2> /dev/null || true +done + +echo " " +echo "Syncing..." +sync +sync +sync +sync +sync +sync +sync +sync + echo " " echo "Un-mount the partitions " sudo umount -f $PATH_TO_SDBOOT -- 1.9.1 _______________________________________________ meta-arago mailing list meta-arago@arago-project.org http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago