[U-Boot] [PATCH v4 15/20] sunxi: defconfig: add supported DT list for Pine64

Andre Przywara andre.przywara at arm.com
Mon May 8 13:44:29 UTC 2017


Hi,

On 05/05/17 20:55, Jagan Teki wrote:
> On Wed, Apr 26, 2017 at 6:02 AM, Andre Przywara <andre.przywara at arm.com> wrote:
>> When a board uses a FIT image to load U-Boot proper, it requires a list
>> of supported device trees to be supplied in CONFIG_OF_LIST, from which it
>> chooses the right one at runtime.
>> For boards with just one possible DT (like the OrangePi PC2) this
>> defaults to CONFIG_DEFAULT_DEVICE_TREE, but for the Pine64 with its two
>> possible models we provide all compatible DTs in this config symbol.
>>
>> Signed-off-by: Andre Przywara <andre.przywara at arm.com>
>> ---
>>  configs/pine64_plus_defconfig | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/configs/pine64_plus_defconfig b/configs/pine64_plus_defconfig
>> index 92bda60..593e24a 100644
>> --- a/configs/pine64_plus_defconfig
>> +++ b/configs/pine64_plus_defconfig
>> @@ -3,6 +3,7 @@ CONFIG_ARCH_SUNXI=y
>>  CONFIG_MACH_SUN50I=y
>>  CONFIG_RESERVE_ALLWINNER_BOOT0_HEADER=y
>>  CONFIG_DEFAULT_DEVICE_TREE="sun50i-a64-pine64-plus"
>> +CONFIG_OF_LIST="sun50i-a64-pine64 sun50i-a64-pine64-plus"
> 
> fdtfile env is compile option now, so it all ways assign
> CONFIG_DEFAULT_DEVICE_TREE so it can't pick sun50i-a64-pine64.dtb
> here, are you manage this in runtime board code?

There may be a confusion about two different uses of DT:
CONFIG_DEFAULT_DEVICE_TREE and CONFIG_OF_LIST are there to tell which DT
U-Boot (proper) *itself* uses: and yes, we pick one of OF_LIST at
runtime (based on some board-specific code, for instance 512MB RAM on
the Pine64(non-plus).
The "fdtfile" environment variable is to give a filename stub for
loading an *external* DT for the *OS*.
Eventually we hopefully won't need that variable and .dtb loading at
all, instead we just pass U-Boot's DT ($fdtcontroladdr) on the OS. This
removes the churn distributions have these days with having to provide
.dtb files for each and every board they want to support.

Cheers,
Andre.


More information about the U-Boot mailing list