使用imx8qxp官方代码: 编译完成后uboot的log显示
0
In boota get fastboot lock status error. Set lock status
Magic is incorrect.
Error validating A/B metadata from disk. Resetting and writing new A/B metadata to disk.
Writing A/B metadata to disk.
verify OK, boot 'boot_a'
Kernel load addr 0x80280000 size 38875 KiB
kernel @ 80280000 (40828928)
ramdisk @ 86400000 (8505831)
fdt @ 82af0400 (92113)
Moving Image from 0x80280000 to 0x80400000, end=82af0000
## Flattened Device Tree blob at 82af0400
Booting using the fdt blob at 0x82af0400
Using Device Tree in place at 0000000082af0400, end 0000000082b09bd0
Disable mu@31580000 rsrc 505 not owned
Disable i2c@37230000 rsrc 288 not owned
Disable clock-controller@37630000 rsrc 288 not owned
Disable intmux@37400000 rsrc 289 not owned
Disable clock-controller@37620000 rsrc 287 not owned
Disable clock-controller@5a4d0000 rsrc 62 not owned
Disable i2c@5a810000 rsrc 97 not owned
Disable clock-controller@5ac90000 rsrc 102 not owned
Disable clock-controller@5ac10000 rsrc 97 not owned
Disable clock-controller@5acd0000 rsrc 105 not owned
Disable clock-controller@585a0000 rsrc 411 not owned
Disable imx8x_cm4@0 rsrc 278 not owned
Disable imx8x_cm4@0 rsrc 297 not owned
下面一大堆Disabled的相关的东西。 后面调试后发现,我与这些对应的Disabled的东西,比如 i2c@37230000和imx8x_cm4@0相关的东西,在kernel设备树里面进行配置后无法枚举,也不会去加载驱动。对应的外设也不能沟调试。 后面自己去查看了一下,nxp上对应的问题是android11里面有M4对应的处理器,如果编译了M4对应的一些资源就会被M4占有,我将无法控制。 以前每玩过IMX8QXP也没遇到这种,后面一咬牙一跺脚,直接去修改了他的脚本。
# :/MX8QXP/device/nxp$ git diff imx8q/mek_8q/AndroidUboot.mk
diff --git a/imx8q/mek_8q/AndroidUboot.mk b/imx8q/mek_8q/AndroidUboot.mk
index b60d3e0e..cff846cc 100644
--- a/imx8q/mek_8q/AndroidUboot.mk
+++ b/imx8q/mek_8q/AndroidUboot.mk
@@ -106,7 +106,7 @@ define build_imx_uboot
else \
REV=`echo B0`; \
fi; \
- if [ `echo $(2) | rev | cut -d '-' -f1` = "uuu" ]; then \
+ if [ `echo $(2) | rev | cut -d '-' -f1` != "uuu" ]; then \
FLASH_TARGET=`echo flash`; \
else \
FLASH_TARGET=`echo flash_linux_m4`; \
# :/MX8QXP/device/nxp$ git diff common/build/uboot.mk
diff --git a/common/build/uboot.mk b/common/build/uboot.mk
index 5b7a3f8c..163c1341 100644
--- a/common/build/uboot.mk
+++ b/common/build/uboot.mk
@@ -123,7 +123,7 @@ $(UBOOTENVSH): | $(UBOOT_OUT)
$(UBOOT_BIN): $(UBOOTENVSH) | $(UBOOT_COLLECTION) $(UBOOT_OUT)
$(hide) echo "Building $(UBOOT_ARCH) $(UBOOT_VERSION) U-Boot ..."
- $(hide) $(call build_m4_image)
+ $(hide) $(call build_flash)
$(hide) for ubootplat in $(TARGET_BOOTLOADER_CONFIG); do \
UBOOT_PLATFORM=`echo $$ubootplat | cut -d':' -f1`; \
UBOOT_CONFIG=`echo $$ubootplat | cut -d':' -f2`; \
修改后uboot的 log显示:
flash target is MMC:0
Net: Could not get PHY for FEC0: addr 0
Could not get PHY for FEC0: addr 0
Could not get PHY for FEC1: addr 0
Could not get PHY for FEC1: addr 0
No ethernet found.
Fastboot: Normal
Normal Boot
Hit any key to stop autoboot: 0
In boota get fastboot lock status error. Set lock status
Magic is incorrect.
Error validating A/B metadata from disk. Resetting and writing new A/B metadata to disk.
Writing A/B metadata to disk.
verify OK, boot 'boot_a'
Kernel load addr 0x80280000 size 38875 KiB
kernel @ 80280000 (40828928)
ramdisk @ 86400000 (8505831)
fdt @ 82af0400 (92113)
Moving Image from 0x80280000 to 0x80400000, end=82af0000
## Flattened Device Tree blob at 82af0400
Booting using the fdt blob at 0x82af0400
ERROR: reserving fdt memory region failed (addr=90400000 size=100000)
Using Device Tree in place at 0000000082af0400, end 0000000082b09bd0
Disable clock-controller@5a4d0000 rsrc 62 not owned
Disable clock-controller@5ac90000 rsrc 102 not owned
Disable clock-controller@585a0000 rsrc 411 not owned
成功了。
修改后的问题,使用sudo ./uuu_imx_android_flash.sh -f imx8qxp -e -u c0 命令无法一次烧录成功。 需要先执行命令:
sudo uuu -b emmc flash.bin
这个会显示失败!(flash.bin在vendor/nxp-opensource/imx-mkimage/iMX8QX目录下生成)自己拷贝过来。
uuu (Universal Update Utility) for nxp imx chips -- libuuu_1.4.139-0-g1a8f760
Success 0 Failure 1
3:33 4/ 7 [partition does not exist ] FB: flash bootloader flash.bin
问题不大,不用理他,再次执行命令
sudo ./uuu_imx_android_flash.sh -f imx8qxp -e -u c0
This script is validated with uuu 1.4.139 version, it is recommended to align with this version.
dtbo is supported
dual slot is supported
dynamic parttition is supported
vendor_boot parttition is supported
generate lines to flash u-boot-imx8qxp-c0.imx to the partition of bootloader0
generate lines to flash partition-table.img to the partition of gpt
generate lines to flash dtbo-imx8qxp.img to the partition of dtbo_a
generate lines to flash boot.img to the partition of boot_a
generate lines to flash vendor_boot.img to the partition of vendor_boot_a
generate lines to flash vbmeta-imx8qxp.img to the partition of vbmeta_a
generate lines to flash dtbo-imx8qxp.img to the partition of dtbo_b
generate lines to flash boot.img to the partition of boot_b
generate lines to flash vendor_boot.img to the partition of vendor_boot_b
generate lines to flash vbmeta-imx8qxp.img to the partition of vbmeta_b
generate lines to flash super.img to the partition of super
uuu script generated, start to invoke uuu with the generated uuu script
uuu (Universal Update Utility) for nxp imx chips -- libuuu_1.4.139-0-g1a8f760
Success 1 Failure 0
3:33 23/23 [Done ] FB: done
哒哒!先这样自己调外设吧。后面在去解决这个M4的问题。
|