at91/image/sama5.mk: check for sama5d4_xplained device
authorSandeep Sheriker M <sandeep.sheriker@microchip.com>
Wed, 14 Aug 2019 21:02:17 +0000 (21:02 +0000)
committerHauke Mehrtens <hauke@hauke-m.de>
Sat, 17 Aug 2019 21:09:04 +0000 (23:09 +0200)
check for sama5d4_xplained device while copying at91bootstrap binary
to sdcard image.

Signed-off-by: Sandeep Sheriker M <sandeep.sheriker@microchip.com>
target/linux/at91/image/sama5.mk

index 4fee464a001ab395d9ab7b68b9a70d02ce66dc69..a737ba508b61ce446665b6433645f1e3a4e2fbb8 100644 (file)
@@ -23,9 +23,13 @@ define Build/at91-sdcard
       mcopy -i $@.boot \
           $(BIN_DIR)/u-boot-$(DEVICE_NAME:at91-%=%)_mmc/u-boot.bin \
           ::u-boot.bin
-      mcopy -i $@.boot \
-          $(BIN_DIR)/at91bootstrap-$(DEVICE_NAME:at91-%=%)sd_uboot/at91bootstrap.bin \
-          ::BOOT.bin)
+      $(if $(findstring sama5d4_xplained, $@), \
+          mcopy -i $@.boot \
+              $(BIN_DIR)/at91bootstrap-$(DEVICE_NAME:at91-%=%)sd_uboot_secure/at91bootstrap.bin \
+              ::BOOT.bin,
+          mcopy -i $@.boot \
+              $(BIN_DIR)/at91bootstrap-$(DEVICE_NAME:at91-%=%)sd_uboot/at91bootstrap.bin \
+              ::BOOT.bin))
 
   $(CP) uboot-env.txt $@-uboot-env.txt
   sed -i '2d;3d' $@-uboot-env.txt