From mboxrd@z Thu Jan 1 00:00:00 1970 From: Priyanka Jain Date: Tue, 29 Aug 2017 08:54:13 +0000 Subject: [U-Boot] [PATCH] board/ls2080ardb: Update board env based on SoC In-Reply-To: References: <1503558415-21649-1-git-send-email-priyanka.jain@nxp.com> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de > -----Original Message----- > From: York Sun > Sent: Friday, August 25, 2017 8:53 PM > To: Priyanka Jain ; u-boot at lists.denx.de > Subject: Re: [PATCH] board/ls2080ardb: Update board env based on SoC > > On 08/24/2017 09:52 PM, Priyanka Jain wrote: > > > > > >> -----Original Message----- > >> From: York Sun > >> Sent: Thursday, August 24, 2017 8:26 PM > >> To: Priyanka Jain ; u-boot at lists.denx.de > >> Subject: Re: [PATCH] board/ls2080ardb: Update board env based on SoC > >> > >> On 08/24/2017 12:07 AM, Priyanka Jain wrote: > >>> As per current implemenetation, default value of board env is based > >>> on board filename i.e ls2080ardb. > >>> > >>> With distro support changes, this env is used to decide upon kernel > >>> dtb which is different for other SoCs (ls2088a, ls2081a) combination > >>> supported with this board. > >>> > >>> Add support to modify board env based on SoC type > >> > >> Please point me to where environmental variable "board" is used for distro > boot. > >> I only see it for PXE. > > Please refer to file end part in "ENV_SETTINGS" section in file > > "include/configs/ls2080ardb.h", Linux boot commands like "nor_bootcmd" > uses command "bootm $loadr_addr#$board" > > Depending upon board value, kernel dtb is chosen. > > I see. It is not a variable used by U-Boot itself. I wonder if you can use multiple > configurations in FIT image to maximize the flexibility to load different device > tree image. > > York This is mainly useful when we are booting using separate images , not a FIT image. Example of use case: LS2080ARDB can supports ls2080a, ls2081a, ls2088a socs. Single flash image is build for the board which can support either combination of SoC. kernel is booted with same itb which is flex_installer_arm64.itb which depending on $board env selects dtb image on NOR flash. flex_installer_arm64.itb has configuration like: configurations { default = "ls2088ardb"; ls2080ardb { description = "config for ls2080ardb"; kernel = "kernel"; ramdisk = "initrd-installer"; fdt = "ls2080ardb-dtb"; }; ls2088ardb { description = "config for ls2088ardb"; kernel = "kernel"; ramdisk = "initrd-installer"; fdt = "ls2088ardb-dtb"; }; Priyanka