工具/软件:
大家好!
根据以下信息、Linux 可能从 eMMC 正常引导、也可能在搜索器件后尝试从 LAN 引导。
由于 DIP-SW 设置为主器件 SD 和辅助器件 eMMC、因此似乎不太可能搜索 LAN。
在搜索方面、u-boot 是否需要执行一些操作?
此致、
ITO
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
工具/软件:
大家好!
根据以下信息、Linux 可能从 eMMC 正常引导、也可能在搜索器件后尝试从 LAN 引导。
由于 DIP-SW 设置为主器件 SD 和辅助器件 eMMC、因此似乎不太可能搜索 LAN。
在搜索方面、u-boot 是否需要执行一些操作?
此致、
ITO
尊敬的 Bin:
对不起,我忘了附上文本。
此致、
ITO
尊敬的 Bin:
我将在 Excel 中列出参考资料。
主器件设置为 SD、辅助器件设置为 eMMC、但您是否了解为什么要搜索 LAN?
此致、
ITO
尊敬的 Bin:
这是日志。
Boot SPL 2025.01-00406-gcd91d7360181 (Mar 25 2025 - 16:14:37 +0000) SYSFW ABI: 4.0 (firmware rev 0x000b '11.0.7--v11.00.07 (Fancy Rat)') Changed A53 CPU frequency to 1250000000Hz (T grade) in DT SPL initial stack usage: 13424 bytes Trying to boot from MMC1 Skipping authentication on GP device Skipping authentication on GP device Skipping authentication on GP device Skipping authentication on GP device Skipping authentication on GP device Starting ATF on ARM64 core... NOTICE: BL31: v2.12.0(release):11.00.08-1-gb11beb2b6-dirty NOTICE: BL31: Built : 12:35:58, Mar 24 2025 U-Boot SPL 2025.01-00406-gcd91d7360181 (Mar 25 2025 - 16:14:37 +0000) SYSFW ABI: 4.0 (firmware rev 0x000b '11.0.7--v11.00.07 (Fancy Rat)') SPL initial stack usage: 1952 bytes MMC: no card present ** Bad device specification mmc 1 ** Couldn't find partition mmc 1:1 Error: could not access storage. Trying to boot from MMC1 Skipping authentication on GP device Skipping authentication on GP device U-Boot 2025.01-00406-gcd91d7360181 (Mar 25 2025 - 16:14:37 +0000) SoC: AM62X SR1.0 GP Model: Texas Instruments AM625 SK DRAM: 2 GiB Core: 83 devices, 32 uclasses, devicetree: separate MMC: mmc@fa10000: 0, mmc@fa00000: 1 Loading Environment from nowhere... OK In: serial Out: serial Err: serial Net: eth0: ethernet@8000000port@1 Hit any key to stop autoboot: 2 1 0 MMC: no card present MMC: no card present ** Bad device specification mmc 1 ** MMC: no card present ** Bad device specification mmc 1 ** Couldn't find partition mmc 1:2 Can't set block device MMC: no card present ** Bad device specification mmc 1 ** Couldn't find partition mmc 1:2 Can't set block device libfdt fdt_check_header(): FDT_ERR_BADMAGIC No FDT memory address configured. Please configure the FDT address via "fdt addr <address>" command. Aborting! Bad Linux ARM64 Image magic! Scanning for bootflows in all bootdevs Seq Method State Uclass Part Name Filename --- ----------- ------ -------- ---- ------------------------ ---------------- Scanning bootdev 'mmc@fa00000.bootdev': MMC: no card present MMC: no card present MMC: no card present Scanning bootdev 'mmc@fa10000.bootdev': Bus usb@31100000: generic_phy_get_bulk : no phys property Register 1000840 NbrPorts 1 Starting the controller USB XHCI 1.10 scanning bus usb@31100000 for devices... 1 USB Device(s) found ethernet@8000000port@1 Waiting for PHY auto negotiation to complete......... TIMEOUT ! am65_cpsw_nuss_port ethernet@8000000port@1: phy_startup failed am65_cpsw_nuss_port ethernet@8000000port@1: am65_cpsw_start end error BOOTP broadcast 1 BOOTP broadcast 2 BOOTP broadcast 3 BOOTP broadcast 4 BOOTP broadcast 5 BOOTP broadcast 6 BOOTP broadcast 7 BOOTP broadcast 8 BOOTP broadcast 9 BOOTP broadcast 10 BOOTP broadcast 11 BOOTP broadcast 12 BOOTP broadcast 13 BOOTP broadcast 14 BOOTP broadcast 15 BOOTP broadcast 16 BOOTP broadcast 17 Retry time exceeded; starting again ethernet@8000000port@1 Waiting for PHY auto negotiation to complete......... TIMEOUT ! am65_cpsw_nuss_port ethernet@8000000port@1: phy_startup failed am65_cpsw_nuss_port ethernet@8000000port@1: am65_cpsw_start end error BOOTP broadcast 1 BOOTP broadcast 2 BOOTP broadcast 3 BOOTP broadcast 4 BOOTP broadcast 5 BOOTP broadcast 6 BOOTP broadcast 7 BOOTP broadcast 8 BOOTP broadcast 9 BOOTP broadcast 10 BOOTP broadcast 11 BOOTP broadcast 12 BOOTP broadcast 13 BOOTP broadcast 14 BOOTP broadcast 15 BOOTP broadcast 16 BOOTP broadcast 17 Retry time exceeded; starting again No more bootdevs --- ----------- ------ -------- ---- ------------------------ ---------------- (0 bootflows, 0 valid) =>
此日志似乎正在尝试获取 IP 地址。
此致、
ITO
您好:
A53 U-Boot 不使用 SYSBOOT 来引导 Linux 内核。 相反、它使用“bootcmd"环境“环境变量。
[12:06:52.654] => printenv bootcmd
[12:07:02.236] bootcmd=run envboot; run bootcmd_ti_mmc; bootflow scan -lb
[12:07:02.242] => printenv bootcmd_ti_mmc
[12:07:06.731] bootcmd_ti_mmc=run init_${boot}; run update_do_main_cpsw0_qsgmii_phyinit; if test ${do_main_cpsw0_qsgmii_phyinit} -eq 1; then run main_cpsw0_qsgmii_phyinit; fi; run boot_rprocs; if test ${boot_fit} -eq 1; then run get_fit_${boot}; run get_fit_overlaystring; run run_fit; else; run get_kern_${boot}; run get_fdt_${boot}; run get_overlay_${boot}; run run_kern; fi;
根据上述情况、它会首先尝试加载“uEnv.txt"文件“文件、作为“envboot"变量“变量中列出的命令的一部分。 然后、它将尝试从由“mmcdev"和“和“bootpart"变量“变量确定的 MMC 设备引导内核。 如果此操作失败、则将执行“bootflow"命令“命令。
“mmcdev"和“和“bootpart"变量“变量的默认值设置为“1"和“和“1:2“。 这将使 A53 U-Boot 从 SD 卡引导内核。
我假设您没有插入 SD 卡、因此 U-Boot 无法引导 Linux 内核、因此您可以看到所有这些日志。
如果您想从 eMMC 引导、则必须修改“mmcdev"和“和“bootpart"变量“变量、如下所示、然后运行“boot"命令“命令:
=> setenv mmcdev 0 => setenv bootpart 0:1 => boot
尊敬的 Shivhare:
感谢您的答复。
我曾尝试将 uEnv.tx 置于引导下、但未加载。
位置有问题吗?
此外、如果在应答方法中使用 bootcmd、
您必须始终使用 bootcmd 执行它、否则无法从 eMMC 引导。
我认为 bootcmd 中有一个 saveenv、但我认为它不能使用(无法保存)。
如果您不使用 bootcmd、您是否需要为 eMMC 重写 uboot 侧的 env 部分?
此致、
ITO
您好:
如果不使用 bootcmd、是否需要为 eMMC 重写 uboot 侧的 env 部分?
要从 eMMC 自动引导、您必须在 U-Boot 源代码中应用以下补丁:
diff --git a/board/ti/am62x/am62x.env b/board/ti/am62x/am62x.env
index 60b5fd5e6ca..6d6ccada945 100644
--- a/board/ti/am62x/am62x.env
+++ b/board/ti/am62x/am62x.env
@@ -16,8 +16,8 @@ run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
boot_targets=mmc1 mmc0 usb pxe dhcp
boot=mmc
-mmcdev=1
-bootpart=1:2
+mmcdev=0
+bootpart=0:1
bootdir=/boot
rd_spec=-
我尝试将 uEnv.TX 置于引导状态、但它没有加载。
您现在可以跳过此步骤。 Linux 也会在有或没有 uEnv.txt 文件的情况下启动。
此致、
Prashant
您好、Prashant、
感谢您提供该补丁。
在 SDK 中、saveenv 在构建过程中被禁用、
因此、我认为更改初始(即启动)环境变量的最快方法是在源代码中编辑**.env 并重新编译。
bootcmd 环境变量设置命令从 u-boot 引导 Linux 内核、
因此、可以暂时覆盖它并从 eMMC 引导、但由于 saveenv(保存到闪存)被禁用、设置将在下次引导时恢复到其原始状态。
这种理解是否正确?
是否在原始 OSS u-boot 中默认禁用 uEnv.txt、而不仅仅是 TI 的 u-boot?
该补丁将 mmcdev 设置为 0 并设置 eMMC、我认为它是从 eMMC 的分区 1 引导的。
如果您在 uboot 这种状态下从 microSD 引导、我认为它也会从 eMMC 引导。
在这种情况下、您可以更改 eMMC 和 microSD 吗?
此外、您能否在引导期间进行扫描并在 microSD 和 eMMC 之间切换 mmcdev?
此致、
ITO
您好:
这一理解是否正确?
是的。
在原始 OSS u-boot 中默认禁用 uEnv.txt、而不仅仅是 TI 的 u-boot?
在 TI U-Boot 中未禁用该功能。 加载“uEnv.txt"失败“失败、因为 A53 U-Boot 在由“mmcdev"变量“变量选择的 MMC 器件中格式化为 FAT 的第一个分区中需要“uEnv.txt"。“。
因此、将“mmcdev"设置“设置为 0 后、eMMC 第一个 FAT 分区中需要“uEnv.txt"文件“文件。
此致、
Prashant