-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
boot: Fix UUU tagging, extend to fslc
Using the UUU-tagged bootloader image directly with UUU can cause UUU to hang. The bootloader image is split on a certain transmit size, and the hang occurs if the tag does not fit with the final bytes of the bootloader image and must be split into a new transmit package. The UUU tag is needed by UUU only in the SD Card image file itself so that UUU can find the end of the boot partition. Rework the design so the default bootloader and the default imx-boot binaries are not tagged. Also, extend the UUU tagging to fslc so it can gain the same benefit. Fixes: #1762 Fixes: nxp-imx/mfgtools#416 Co-authored-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com> (cherry picked from commit ef8b4c4)
- Loading branch information
1 parent
c30f12b
commit 161f1b3
Showing
12 changed files
with
33 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,20 @@ | ||
# Append a tag to the bootloader image used in the SD card image. The tag | ||
# contains the size of the bootloader image so UUU can easily find the end of | ||
# the bootloader in the SD card image. | ||
# Create a tagged boot partition file for the SD card image file. The tag | ||
# contains the size of the boot partition image so UUU can easily find | ||
# the end of it in the SD card image file. | ||
# | ||
# IMPORTANT: The tagged boot partition file should never be used directly with | ||
# UUU, as it can cause UUU to hang. | ||
|
||
UUU_BOOTLOADER = "${UBOOT_BINARY}" | ||
UUU_BOOTLOADER:mx8-generic-bsp = "${@d.getVar('UBOOT_PROVIDES_BOOT_CONTAINER') == '0' and 'imx-boot' or 'flash.bin'}" | ||
UUU_BOOTLOADER:mx9-generic-bsp = "${@d.getVar('UBOOT_PROVIDES_BOOT_CONTAINER') == '0' and 'imx-boot' or 'flash.bin'}" | ||
|
||
do_deploy:append() { | ||
if [ "${UUU_BOOTLOADER}" != "" ]; then | ||
cp ${DEPLOYDIR}/${UUU_BOOTLOADER} ${DEPLOYDIR}/${UUU_BOOTLOADER_TAGGED} | ||
cp ${DEPLOYDIR}/${UUU_BOOTLOADER} ${DEPLOYDIR}/${UUU_BOOTLOADER_UNTAGGED} | ||
ln -sf ${UUU_BOOTLOADER_TAGGED} ${DEPLOYDIR}/${UUU_BOOTLOADER} | ||
stat -L -cUUUBURNXXOEUZX7+A-XY5601QQWWZ%sEND ${DEPLOYDIR}/${UUU_BOOTLOADER_TAGGED} \ | ||
>> ${DEPLOYDIR}/${UUU_BOOTLOADER_TAGGED} | ||
cp ${DEPLOYDIR}/${UUU_BOOTLOADER} \ | ||
${DEPLOYDIR}/${UUU_BOOTLOADER}.tagged | ||
stat -L -cUUUBURNXXOEUZX7+A-XY5601QQWWZ%sEND \ | ||
${DEPLOYDIR}/${UUU_BOOTLOADER}.tagged \ | ||
>> ${DEPLOYDIR}/${UUU_BOOTLOADER}.tagged | ||
fi | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters