内核和UBOOT的负载和进入地址
第二阶段引导加载程序如何知道它应该加载uboot的地址以及UBOOT如何知道在哪里加载内核。
1-我们是否通过配置文件或设备树提供这些地址信息?
2-我们如何找到这些地址? 谢谢
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
第二阶段引导加载程序如何知道它应该加载uboot的地址以及UBOOT如何知道在哪里加载内核。
1-我们是否通过配置文件或设备树提供这些地址信息?
2-我们如何找到这些地址? 谢谢
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(1)
因此,当硬件加载U-Boot时,地址是特定于SOC的,并由该SOC记录在手册中。 U-Boot将在构建时间进行配置,以了解此位置并在此处链接。通常,这是一个两个阶段的过程,首先加载了“ U-Boot SPL”,而SPL则加载了“ U-Boot”。在这里使用类似的逻辑来了解有效的起始位置要运行。对于内核和相关部分,这是在对于常见情况,需要考虑考虑这两个SOC特定的特定事物,例如DDR映射的地方地址空间以及OS图像的典型约束,以大小和对齐方式。
So, when the hardware loads U-Boot, the address is SoC specific, and documented by that SoC in their manuals. U-Boot will be configured at build time to know this location and be linked there. Typically this is a two stage process with "U-Boot SPL" being loaded first and "U-Boot" proper being loaded by SPL. Similar logic is used here to know a valid starting location to run at. For the kernel and related portions, this is documented at https://u-boot.readthedocs.io/en/latest/usage/environment.html#image-locations for the common case and needs to take in to account both SoC specific things such as where DDR is mappped in address space as well as the typical constraints of the OS image in terms of size and alignment.