[PATCH 3/3] arm: rmobile: rzg2_beacon: Auto select Linux device tree by SoC

Marek Vasut marek.vasut at mailbox.org
Sun Nov 19 21:06:38 CET 2023


On 10/27/23 04:12, Adam Ford wrote:
> On Thu, Oct 26, 2023 at 8:44 PM Marek Vasut <marex at denx.de> wrote:
>>
>> On 10/26/23 01:13, Adam Ford wrote:
>>> There is a function inside the board file to autodetect which device
>>> tree is needed by U-Boot to properly load its own device tree, but
>>> it currently defaults to always loading RZ/G2M for Linux.  This is
>>> not correct for other SoC variants.  Add board_late_init function
>>> to query the SoC name and use that to determine which device tree
>>> is loaded for booting Linux.
>>
>> Can't this be scripted in environment instead ?
> 
> Do you have a recommendation for how to read the SoC type from a script?

If you want to read PRR from script:

$ setexpr prrcontent *0xFFF00044
$ printenv prrcontent



More information about the U-Boot mailing list