瀏覽代碼

dubhe: images: Fix Dubhe 80 fail to generate proper binaries
dd command need to be done twice, else resulting in a 9kB image.
Fix typo in qspi-nfs-image recipe.

Signed-off-by: weiheng.cheng <weiheng.cheng@starfivetech.com>

weiheng.cheng 7 月之前
父節點
當前提交
86e315fd7d

+ 3 - 1
recipes-core/images/dubhe-image-minimal_0.1.bb

@@ -28,8 +28,10 @@ IMAGE_CMD:qspi_ext4 (){
         dd if=${DEPLOY_DIR_IMAGE}/dubhe90_fpga_ext4.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ext4-image.bin bs=32 seek=129 count=255
         dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ext4-image.bin bs=32 seek=384
 
-	cp ${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ext4-image.bin ${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ext4-image.bin
+	dd if=${DEPLOY_DIR_IMAGE}/bootcode_min.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ext4-image.bin bs=32 seek=0 count=128
+        dd if=${DEPLOY_DIR_IMAGE}/bootjump.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ext4-image.bin bs=32 seek=128 count=1
         dd if=${DEPLOY_DIR_IMAGE}/dubhe80_fpga_ext4.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ext4-image.bin bs=32 seek=129 count=255
+        dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ext4-image.bin bs=32 seek=384
 }
 
 IMAGE_CMD:qspi_sd (){

+ 3 - 1
recipes-core/images/qspi-image_0.1.bb

@@ -21,6 +21,8 @@ IMAGE_CMD:qspi () {
 	dd if=${DEPLOY_DIR_IMAGE}/dubhe90_fpga.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-initramfs-image.bin bs=32 seek=129 count=255
 	dd if=${DEPLOY_DIR_IMAGE}/fw_payload_initramfs.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-initramfs-image.bin bs=32 seek=384
 
-	cp ${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-initramfs-image.bin ${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-initramfs-image.bin
+	dd if=${DEPLOY_DIR_IMAGE}/bootcode.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-initramfs-image.bin bs=32 seek=0 count=128
+        dd if=${DEPLOY_DIR_IMAGE}/bootjump.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-initramfs-image.bin bs=32 seek=128 count=1
         dd if=${DEPLOY_DIR_IMAGE}/dubhe80_fpga.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-initramfs-image.bin bs=32 seek=129 count=255
+        dd if=${DEPLOY_DIR_IMAGE}/fw_payload_initramfs.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-initramfs-image.bin bs=32 seek=384
 }

+ 4 - 2
recipes-core/images/qspi-nfs-image_0.1.bb

@@ -8,7 +8,7 @@ DEPENDS += "opensbi deploy-bootfiles quilt quilt-native"
 
 LIC_FILES_CHKSUM = ""
 
-IMAGE_FSTYPTES += "qspi_nfs"
+IMAGE_FSTYPES += "qspi_nfs"
 
 require qspi-nfs-essential.inc
 
@@ -36,6 +36,8 @@ IMAGE_CMD:qspi_nfs (){
         dd if=${DEPLOY_DIR_IMAGE}/dubhe90_fpga_nfs.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-nfs-image.bin bs=32 seek=129 count=255
         dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-nfs-image.bin bs=32 seek=384
 
-	cp ${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-nfs-image.bin ${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-nfs-image.bin
+	dd if=${DEPLOY_DIR_IMAGE}/bootcode_min.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-nfs-image.bin bs=32 seek=0 count=128
+        dd if=${DEPLOY_DIR_IMAGE}/bootjump.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-nfs-image.bin bs=32 seek=128 count=1
         dd if=${DEPLOY_DIR_IMAGE}/dubhe80_fpga_nfs.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-nfs-image.bin bs=32 seek=129 count=255
+        dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-nfs-image.bin bs=32 seek=384
 }

+ 4 - 1
recipes-core/images/qspi-ubifs-image_0.1.bb

@@ -37,7 +37,10 @@ IMAGE_CMD:qspi_ubifs () {
         dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ubifs-image.bin bs=32 seek=384 count=1048192
 	dd if=${IMGDEPLOYDIR}/qspi-ubifs-starfive-dubhe.ubi of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ubifs-image.bin bs=64KiB seek=512
 
-	cp ${DEPLOY_DIR_IMAGE}/starfive-dubhe-90-qspi-ubifs-image.bin ${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin
+	dd if=${DEPLOY_DIR_IMAGE}/bootcode.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin bs=32 seek=0 count=128
+        dd if=${DEPLOY_DIR_IMAGE}/bootjump.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin bs=32 seek=128 count=1
         dd if=${DEPLOY_DIR_IMAGE}/dubhe80_fpga_ubi.dtb of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin bs=32 seek=129 count=255
+        dd if=${DEPLOY_DIR_IMAGE}/fw_payload.bin of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin bs=32 seek=384 count=1048192
+        dd if=${IMGDEPLOYDIR}/qspi-ubifs-starfive-dubhe.ubi of=${DEPLOY_DIR_IMAGE}/starfive-dubhe-80-qspi-ubifs-image.bin bs=64KiB seek=512
 }