[PATCH v1] rockchip: mkimage: add rockchip nand support

2022-06-03 Thread Johan Jonker
The Rockchip boot ROM requires a particular file format for booting from NAND: * It starts with 512-byte, rc4 encoded header and is aligned to NAND page size. * Then 2KB pieces of spl and tpl data aligned to the NAND page size in a * fixed pattern with empty pages. Size of spl and tpl must be

Re: [PATCH] net: enetc: unregister mdiobus

2022-06-03 Thread Tom Rini
On Tue, May 31, 2022 at 06:36:16PM +0200, Michael Walle wrote: > If the device fails to probe - for example, when there is no > ethaddr set - then the private data is automatically freed > but the mdiobus remains registered. > > Fixes: 1e354cb39314 ("drivers: net: fsl_enetc: register internal

Re: [PATCH v2] net: Check for the minimum IP fragmented datagram size

2022-06-03 Thread Tom Rini
On Thu, May 26, 2022 at 11:14:37AM -0300, Fabio Estevam wrote: > From: Fabio Estevam > > Nicolas Bidron and Nicolas Guigo reported the two bugs below: > > " Applied to u-boot/master, thanks! -- Tom signature.asc Description: PGP signature

Re: [PATCH] squashfs: Fix compilation on big endian systems

2022-06-03 Thread Tom Rini
On Wed, Apr 06, 2022 at 11:31:53PM +0200, Pali Rohár wrote: > Signed-off-by: Pali Rohár > Reviewed-by: Miquel Raynal Applied to u-boot/master, thanks! -- Tom signature.asc Description: PGP signature

Re: [PATCH resend 2/2] imx: imx8mq: select CONFIG_CMD_CLK

2022-06-03 Thread Tom Rini
On Mon, May 23, 2022 at 07:38:28PM +0800, Peng Fan (OSS) wrote: > From: Peng Fan > > select CONFIG_CMD_CLK to enable dump clk in uboot shell > > Signed-off-by: Peng Fan Applied to u-boot/master, thanks! -- Tom signature.asc Description: PGP signature

Re: [PATCH resend 1/2] imx: imx8mq: default select CLK_IMX8MQ

2022-06-03 Thread Tom Rini
On Mon, May 23, 2022 at 07:38:27PM +0800, Peng Fan (OSS) wrote: > From: Peng Fan > > Since the power domain driver default select CONFIG_CLK, so we will > meet lots failures without CLK_IMX8MQ, so default select it. > > Fixes: commit 4eb82c2e56a7c ("imx: power-domain: Get rid of SMCCC

Re: [PATCH] ubifs: Fix lockup/crash when reading files

2022-06-03 Thread Tom Rini
On Tue, May 17, 2022 at 10:45:28PM +0200, Pali Rohár wrote: > Commit b1a14f8a1c2e ("UBIFS: Change ubifsload to not read beyond the > requested size") added optimization to do not read more bytes than it is > really needed. But this commit introduced incorrect handling of the hole at > the end of

Re: [PATCH] armv8: Fix TCR 64-bit writes

2022-06-03 Thread Tom Rini
On Mon, May 09, 2022 at 05:08:49PM +0100, Andre Przywara wrote: > The AArch64 TCR_ELx register is a 64-bit register, and many newer > architecture features use bits in the upper half. So far U-Boot was > igorant of those bits, trying to leave them alone. > However, in an effort to set bit 31 to

Re: [PATCH] board: ti: am64x: Update MAINTAINERS

2022-06-03 Thread Tom Rini
On Fri, Jun 03, 2022 at 02:30:20PM -0500, Dave Gerlach wrote: > Move maintainership of TI AM64x boards to Vignesh. > > Signed-off-by: Dave Gerlach Applied to u-boot/master, thanks! -- Tom signature.asc Description: PGP signature

[PATCH] board: ti: am64x: Update MAINTAINERS

2022-06-03 Thread Dave Gerlach
Move maintainership of TI AM64x boards to Vignesh. Signed-off-by: Dave Gerlach --- board/ti/am64x/MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/board/ti/am64x/MAINTAINERS b/board/ti/am64x/MAINTAINERS index eaca2b865f51..78a21d66af73 100644 ---

Re: [PATCH 0/5] Add support for FLexSPI Boot for i.MX8m

2022-06-03 Thread Fabio Estevam
On Fri, Jun 3, 2022 at 8:39 AM Mamta Shukla wrote: > > This series of patch adds support for generating FlexSPI Header file > and booting from QSPI on i.MX8m. > > > Mamta Shukla (5): > tools: mkimage: Add support to generate FlexSPI Header for i.MX8m > dts: imx8mm-uboot: Add support to pack

Re: [PATCH 3/5] configs: Add config for enabling FSPI boot option for i.MX8m

2022-06-03 Thread Fabio Estevam
Hi Mamta, On Fri, Jun 3, 2022 at 8:39 AM Mamta Shukla wrote: > > Add imx8mm_evk_fspi_defconfig to build QSPI boot image. > This config is based on imx8mm_evk_defconfig with addtional config options for > FSPI Header,SPL offset and imx-image config to boot from FSPI. > > Unneeded blank line.

Re: [PATCH 1/5] tools: mkimage: Add support to generate FlexSPI Header for i.MX8m

2022-06-03 Thread Fabio Estevam
Hi Mamta, On Fri, Jun 3, 2022 at 8:39 AM Mamta Shukla wrote: > void build_image(int ofd) > { > - int file_off, header_hdmi_off = 0, header_image_off; > - int hdmi_fd, ap_fd, sld_fd; > + int file_off, header_hdmi_off = 0, header_image_off, fspi_off; > + int hdmi_fd,

Re: [SPAM] RockPi4B: spl_load_fit_image() writing past end of buffer & MMC errors

2022-06-03 Thread Xavier Drudis Ferran
Sorry for the noise. El Fri, Jun 03, 2022 at 04:58:38PM +0200, Xavier Drudis Ferran deia: > > In my Rock Pi 4B this does not happen. It happily writes the 17 blocks. > Or it's just that I'm not noticing the problem ? Does it hang or give you > an error, or do you just find it out by reading

Re: [PATCH v1 6/9] ARM: dts: Add device tree files for hpe gxp soc

2022-06-03 Thread Tom Rini
On Fri, Jun 03, 2022 at 03:35:51PM +, Hawkins, Nick wrote: > > > You will need to post a sync periodically. Every Linux release (full, not > > -rc) would be great, every couple is fine. > > If there are changes I need in the device tree for u-boot that are not > currently in Linux do they

Re: [SPAM] RockPi4B: spl_load_fit_image() writing past end of buffer & MMC errors

2022-06-03 Thread Jerome Forissier
Hi Xavier, On 6/3/22 16:58, Xavier Drudis Ferran wrote: > El Fri, Jun 03, 2022 at 03:17:05PM +0200, Jerome Forissier deia: >> First, I noticed that spl_load_fit_image() may write memory outside the range >> given in the image node. For example on RockPi 4B I have the following FIT >> (irrelevant

Re: [PATCH 2/2] clk: imx8mp: use usb_core_ref for usb_root_clk

2022-06-03 Thread Fabio Estevam
On 03/06/2022 12:15, Andrey Zhizhikin wrote: Upstream commit 7a2c3be95a50 ("clk: imx8mp: Fill in DWC3 USB, USB PHY, HSIOMIX clock") added usb_core_ref for USB Controller but never set it to be used as a clock source, using rather "osc_32k" instead. This produces following boot log message:

Re: [PATCH 1/2] clk: imx8mp: fix root clock names for ecspi

2022-06-03 Thread Fabio Estevam
On 03/06/2022 12:15, Andrey Zhizhikin wrote: Root clock name contained underscore, which does not match to the actual clock name. Correct the name to match what is present in the FDT. Fixes: 87f958810fcb ("clk: imx8mp: Add ECSPI clocks") Signed-off-by: Andrey Zhizhikin Cc: Fabio Estevam Cc:

RE: [PATCH v1 6/9] ARM: dts: Add device tree files for hpe gxp soc

2022-06-03 Thread Hawkins, Nick
> You will need to post a sync periodically. Every Linux release (full, not > -rc) would be great, every couple is fine. If there are changes I need in the device tree for u-boot that are not currently in Linux do they need to be in Linux first? Or is that what the usage of appending

[PATCH] fs/squashfs: sqfs_read: Prevent arbitrary code execution

2022-06-03 Thread Miquel Raynal
Following Jincheng's report, an out-of-band write leading to arbitrary code execution is possible because on one side the squashfs logic accepts directory names up to 65535 bytes (u16), while U-Boot fs logic accepts directory names up to 255 bytes long. Prevent such an exploit from happening by

[PATCH 2/2] clk: imx8mp: use usb_core_ref for usb_root_clk

2022-06-03 Thread Andrey Zhizhikin
Upstream commit 7a2c3be95a50 ("clk: imx8mp: Fill in DWC3 USB, USB PHY, HSIOMIX clock") added usb_core_ref for USB Controller but never set it to be used as a clock source, using rather "osc_32k" instead. This produces following boot log message: "clk_register: failed to get osc_32k device (parent

[PATCH 1/2] clk: imx8mp: fix root clock names for ecspi

2022-06-03 Thread Andrey Zhizhikin
Root clock name contained underscore, which does not match to the actual clock name. Correct the name to match what is present in the FDT. Fixes: 87f958810fcb ("clk: imx8mp: Add ECSPI clocks") Signed-off-by: Andrey Zhizhikin Cc: Fabio Estevam Cc: Peng Fan Cc: Stefano Babic Cc: uboot-imx ---

[PATCH 0/2] clk: imx8mp: clock names and clock source fixes

2022-06-03 Thread Andrey Zhizhikin
This series addresses few fixes for clock sub-system for i.MX8MP SOC. One is dealing with incorrect names used, while the second one addresses root clock selection which has been apparently omitted during merge and caused the warning to be reported during boot. Andrey Zhizhikin (2): clk:

Re: [PATCH] boot: pxe_utils: Do not use fdtcontroladdr for FIT Image format

2022-06-03 Thread Tom Rini
On Fri, May 27, 2022 at 04:37:25PM +0200, Neil Armstrong wrote: > When patch [1] introduced "fdtcontroladdr" fallback in order to use > built-in DT when no DT in provided in PXE config, it broke FIT image > boot where the DT from the FIT configuration was used. > > This disables the

Re: binman: Why is the first word the compressed size in compressed data

2022-06-03 Thread Stefan Herbrechtsmeier
Am 02.06.2022 um 20:10 schrieb Alper Nebi Yasak: On 01/06/2022 11:29, Stefan Herbrechtsmeier wrote: Hi Simon, I want to compress a FPGA Image on the fly via binman but this doesn't work. I have add a bintool implementation for gzip, add gzip support to comp_util.py and set `compress` and

Re: [SPAM] RockPi4B: spl_load_fit_image() writing past end of buffer & MMC errors

2022-06-03 Thread Xavier Drudis Ferran
El Fri, Jun 03, 2022 at 03:17:05PM +0200, Jerome Forissier deia: > First, I noticed that spl_load_fit_image() may write memory outside the range > given in the image node. For example on RockPi 4B I have the following FIT > (irrelevant parts omitted): > > / { > images { >

Re: [PATCH] squashfs: Fix compilation on big endian systems

2022-06-03 Thread Miquel Raynal
Hi Tom, tr...@konsulko.com wrote on Wed, 1 Jun 2022 10:08:20 -0400: > On Thu, Apr 07, 2022 at 11:58:55AM +0200, Pali Rohár wrote: > > On Thursday 07 April 2022 11:54:55 Miquel Raynal wrote: > > > Hi Pali, > > > > > > p...@kernel.org wrote on Thu, 7 Apr 2022 11:41:59 +0200: > > > > > > > On

Re: [PATCH] xilinx: zynqmp: Do not use null as spl bss start address

2022-06-03 Thread Stefan Herbrechtsmeier
Am 03.06.2022 um 14:12 schrieb Michal Simek: On 6/1/22 16:03, Stefan Herbrechtsmeier wrote: Hi, Am 01.06.2022 um 14:59 schrieb Michal Simek: On 6/1/22 14:27, Stefan Herbrechtsmeier wrote: Hi, Am 01.06.2022 um 13:59 schrieb Michal Simek: Hi, first of all subject is not accurate. We are

Re: [PATCH v1 6/9] ARM: dts: Add device tree files for hpe gxp soc

2022-06-03 Thread Tom Rini
On Thu, Jun 02, 2022 at 08:56:59PM +, Hawkins, Nick wrote: > > > -Original Message- > From: Hawkins, Nick > Sent: Thursday, June 2, 2022 3:56 PM > To: Tom Rini > Cc: Verdun, Jean-Marie ; u-boot@lists.denx.de > Subject: RE: [PATCH v1 6/9] ARM: dts: Add device tree files for hpe gxp

Re: [PATCH resend 1/2] imx: imx8mq: default select CLK_IMX8MQ

2022-06-03 Thread Tom Rini
On Fri, Jun 03, 2022 at 06:57:16AM +, Peng Fan (OSS) wrote: > Stefano, > > > Subject: [PATCH resend 1/2] imx: imx8mq: default select CLK_IMX8MQ > > This patch is needed as a bugfix, please consider pick up. I'm putting together my next batch of must-haves for -rc4, I'll take this series

Re: [PATCH] boot: image-pre-load: drop unused CONFIG_SYS_BOOTM_LEN

2022-06-03 Thread Tom Rini
On Fri, Jun 03, 2022 at 06:44:56AM +, Peng Fan wrote: > Tom, > > > Subject: [PATCH] boot: image-pre-load: drop unused CONFIG_SYS_BOOTM_LEN > > You gave an R-b, but still not pick this up? It's not breaking anything is it? I'll grab it to -next when that opens next week if so. -- Tom

RockPi4B: spl_load_fit_image() writing past end of buffer & MMC errors

2022-06-03 Thread Jerome Forissier
Hi, I am trying to enable FIT image verification by SPL on Rockchip 4B (U-Boot v2022.04) and I hit a couple of issues. First, I noticed that spl_load_fit_image() may write memory outside the range given in the image node. For example on RockPi 4B I have the following FIT (irrelevant parts

Re: [PATCH 2/2] mvebu: uDPU: disable non-present peripherals

2022-06-03 Thread Pali Rohár
On Friday 03 June 2022 12:53:05 Robert Marko wrote: > uDPU like eDPU does not expose SCSI based peripherals like SATA nor PCI > and for sure it does not have the Intel E1000 PCI card. > > So, like for eDPU remove those from the defconfig. > > Signed-off-by: Robert Marko Reviewed-by: Pali Rohár

Re: [PATCH 1/2] mvebu: eDPU: disable SCSI support

2022-06-03 Thread Pali Rohár
On Friday 03 June 2022 12:53:04 Robert Marko wrote: > eDPU does not use SCSI nor it has SATA exposed, and commit > arm: mvebu: a3720: Set BOOT_TARGET_DEVICES list to enabled peripherals > now allows compiling U-boot wihout all of the BOOT_TARGET_DEVICES since > not all boards have all of the

Re: [PATCH 1/8] spl: Kconfig: not select SPL_RAW_IMAGE_SUPPORT for i.MX8M

2022-06-03 Thread Tom Rini
On Fri, Jun 03, 2022 at 03:17:08PM +0800, Peng Fan (OSS) wrote: > From: Peng Fan > > i.MX8M use FIT image, not RAW image. And to support binman symbols, > u_boot_any could be optimized if RAW image is not selected, otherwise > there will be build failure. So not select SPL_RAW_IMAGE_SUPPORT >

Re: [PATCH] xilinx: zynqmp: Do not use null as spl bss start address

2022-06-03 Thread Michal Simek
On 6/1/22 16:03, Stefan Herbrechtsmeier wrote: Hi, Am 01.06.2022 um 14:59 schrieb Michal Simek: On 6/1/22 14:27, Stefan Herbrechtsmeier wrote: Hi, Am 01.06.2022 um 13:59 schrieb Michal Simek: Hi, first of all subject is not accurate. We are not using null as start but address 0. I

[PATCH 1/1] CVE-2022-30767: unbounded memcpy with a failed length check

2022-06-03 Thread gerbert
This patch tries to fix a CVE-2019-14196 fix In if-condition, where NFSV2_FLAG is checked, memcpy call is performed to transfer a reply data of NFS_FHSIZE size. Since the data field in struct rpc_t structure has the size of (1024 / 4) + 26 = 282, while NFS_FHSIZE is only 32, it won't lead to

[PATCH 1/1] CVE-2022-30767: unbounded memcpy with a failed length check

2022-06-03 Thread gerbert
This patch tries to fix a CVE-2019-14196 fix In if-condition, where NFSV2_FLAG is checked, memcpy call is performed to transfer a reply data of NFS_FHSIZE size. Since the data field in struct rpc_t structure has the size of (1024 / 4) + 26 = 282, while NFS_FHSIZE is only 32, it won't lead to

[PATCH 5/5] configs: imx8mm: Define CONFIG_SYS_UBOOT_BASE for i.MX8m

2022-06-03 Thread Mamta Shukla
The macro `CONFIG_SYS_UBOOT_BASE` is used by SPL loaders `"NOR"` and `"XIP"` to determine the base address of u-boot. For `"NOR"` on i.MX8MM it is the base address of QSPI0 plus the offset of the flattened image tree blob. Although `QSPI0_AMBA_BASE` is used to define CONFIG_SYS_UBOOT_BASE in

[PATCH 4/5] board: freescale: Add QSPI Boot support in spl for i.MX8m

2022-06-03 Thread Mamta Shukla
Add QSPI Boot option in u-boot-spl for i.MX8m EVK. Signed-off-by: Mamta Shukla Signed-off-by: Thomas Haemmerle --- board/freescale/imx8mm_evk/spl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/board/freescale/imx8mm_evk/spl.c b/board/freescale/imx8mm_evk/spl.c index

[PATCH 2/5] dts: imx8mm-uboot: Add support to pack FlexSPI Header using binman

2022-06-03 Thread Mamta Shukla
Add definition for FSPI configuration block and subsequently new offsets for u-boot-spl and u-boot-itb for CONFIG_FSPI_HEADER option. Signed-off-by: Mamta Shukla Signed-off-by: Thomas Haemmerle --- arch/arm/dts/imx8mm-u-boot.dtsi | 22 +- 1 file changed, 21 insertions(+), 1

[PATCH 3/5] configs: Add config for enabling FSPI boot option for i.MX8m

2022-06-03 Thread Mamta Shukla
Add imx8mm_evk_fspi_defconfig to build QSPI boot image. This config is based on imx8mm_evk_defconfig with addtional config options for FSPI Header,SPL offset and imx-image config to boot from FSPI. Signed-off-by: Mamta Shukla Signed-off-by: Thomas Haemmerle ---

[PATCH 1/5] tools: mkimage: Add support to generate FlexSPI Header for i.MX8m

2022-06-03 Thread Mamta Shukla
Add struct with Flex SPI Configuration Block and enable generating fspi header using mkimage. Refer i.MX 8M Mini Application Processor Reference Manual for detailed information about parameters for FlexSPI Configuration block. Signed-off-by: Mamta Shukla Signed-off-by: Thomas Haemmerle ---

[PATCH 0/5] Add support for FLexSPI Boot for i.MX8m

2022-06-03 Thread Mamta Shukla
This series of patch adds support for generating FlexSPI Header file and booting from QSPI on i.MX8m. Mamta Shukla (5): tools: mkimage: Add support to generate FlexSPI Header for i.MX8m dts: imx8mm-uboot: Add support to pack FlexSPI Header using binman configs: Add config for enabling

[PATCH 2/2] mvebu: uDPU: disable non-present peripherals

2022-06-03 Thread Robert Marko
uDPU like eDPU does not expose SCSI based peripherals like SATA nor PCI and for sure it does not have the Intel E1000 PCI card. So, like for eDPU remove those from the defconfig. Signed-off-by: Robert Marko --- configs/uDPU_defconfig | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-)

[PATCH 1/2] mvebu: eDPU: disable SCSI support

2022-06-03 Thread Robert Marko
eDPU does not use SCSI nor it has SATA exposed, and commit arm: mvebu: a3720: Set BOOT_TARGET_DEVICES list to enabled peripherals now allows compiling U-boot wihout all of the BOOT_TARGET_DEVICES since not all boards have all of the listed peripherals exposed. So, disable SCSI support in

Re: [PATCH v5 2/3] arm: mvebu: add support for Methode eDPU

2022-06-03 Thread Robert Marko
On Fri, Jun 3, 2022 at 11:42 AM Stefan Roese wrote: > > On 02.06.22 23:58, Pali Rohár wrote: > > On Monday 23 May 2022 11:20:27 Pali Rohár wrote: > >> On Monday 23 May 2022 11:18:23 Robert Marko wrote: > >>> On Mon, May 23, 2022 at 10:20 AM Pali Rohár wrote: > > On Friday 20 May 2022

[PATCH v2 3/3] drivers: rng: optee_rng: register to CONFIG_OPTEE_SERVICE_DISCOVERY

2022-06-03 Thread Etienne Carriere
Changes optee_rng driver to register itself has a OP-TEE service so that a device is bound for the driver when OP-TEE enumerates the PTA RNG service. Cc: Sughosh Ganu Cc: Patrick Delaunay Signed-off-by: Etienne Carriere --- No change since v1. --- drivers/rng/Kconfig | 1 +

[PATCH v2 2/3] drivers: tee: optee: discover OP-TEE services

2022-06-03 Thread Etienne Carriere
This change defines resources for OP-TEE service drivers to register themselves for being bound to when OP-TEE firmware reports the related service is supported. OP-TEE services are discovered during optee driver probe sequence which mandates optee driver is always probe once bound. Discovery of

[PATCH v2 1/3] drivers: tee: optee: remove unused probe local variable

2022-06-03 Thread Etienne Carriere
Removes local variable child in optee_probe() that is not used. Cc: Patrick Delaunay Signed-off-by: Etienne Carriere --- New change not in v1 series. --- drivers/tee/optee/core.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/tee/optee/core.c

Re: [PATCH v5 2/3] arm: mvebu: add support for Methode eDPU

2022-06-03 Thread Stefan Roese
On 02.06.22 23:58, Pali Rohár wrote: On Monday 23 May 2022 11:20:27 Pali Rohár wrote: On Monday 23 May 2022 11:18:23 Robert Marko wrote: On Mon, May 23, 2022 at 10:20 AM Pali Rohár wrote: On Friday 20 May 2022 13:46:32 Robert Marko wrote: Changes in v4: * Remove CMD_PCI as PCI is disabled

Re: [PATCH RFC v2 11/11] ti: dtsi: j721e: Use binman to package tispl.bin

2022-06-03 Thread Roger Quadros
On 01/06/2022 15:47, Andrew Davis wrote: > On 6/1/22 5:55 AM, Roger Quadros wrote: >> >> >> On 01/06/2022 13:42, Neha Malcom Francis wrote: >>> Hi Roger, >>> >>> On 01/06/22 14:53, Roger Quadros wrote: Hi, On 01/06/2022 09:08, Neha Malcom Francis wrote: > Hi Roger, >

[PATCH] mtd: spi-nor-core: Implement spi_nor_read_sfdp_dma_unsafe() for sfdp parse

2022-06-03 Thread Vaishnav Achath
During SFDP header parse and BFPT parse, structures in stack are used to perform spi_nor_read_sfdp() which expects a dma-safe buffer. This commit introduces spi_nor_read_sfdp_dma_unsafe() to wrap spi_nor_read_sfdp() using a kmalloc'ed bounce buffer which is the same implementation in Linux

RE: [PATCH resend 1/2] imx: imx8mq: default select CLK_IMX8MQ

2022-06-03 Thread Peng Fan (OSS)
Stefano, > Subject: [PATCH resend 1/2] imx: imx8mq: default select CLK_IMX8MQ This patch is needed as a bugfix, please consider pick up. Thanks, Peng. > > From: Peng Fan > > Since the power domain driver default select CONFIG_CLK, so we will meet lots > failures without CLK_IMX8MQ, so

RE: [PATCH] boot: image-pre-load: drop unused CONFIG_SYS_BOOTM_LEN

2022-06-03 Thread Peng Fan
Tom, > Subject: [PATCH] boot: image-pre-load: drop unused CONFIG_SYS_BOOTM_LEN You gave an R-b, but still not pick this up? Thanks, Peng. > > From: Peng Fan > > CONFIG_SYS_BOOTM_LEN is not used in this file, drop it. > > Signed-off-by: Peng Fan > --- > boot/image-pre-load.c | 5 - >

RE: [PATCH 0/8] arm64: binman: use binman symbols for imx

2022-06-03 Thread Peng Fan
> Subject: [PATCH 0/8] arm64: binman: use binman symbols for imx Sorry I missed to add V6 in patchset subject, but I do add V6 changelog below, please raise if you have concern, and I could resend with V6 in patch subject. Thanks, Peng. > > From: Peng Fan > > V6: > Drop no-u-boot-any

[PATCH 8/8] imx: imx8mm-icore: migrate to use BINMAN

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan Use BINMAN instead of imx specific packing method. Signed-off-by: Peng Fan --- arch/arm/mach-imx/imx8m/Kconfig | 1 + arch/arm/mach-imx/imx8m/imximage-8mm-lpddr4.cfg | 10 +- configs/imx8mm-icore-mx8mm-ctouch2_defconfig| 2 +-

[PATCH 7/8] binman_sym: guard with CONFIG_IS_ENABLED(BINMAN_SYMBOLS)

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan There is case that CONFIG_BINMAN is defined, but CONFIG_SPL_BINMAN_SYMBOLS is not defined. In that case, there will be build failure. So use CONFIG_SPL_BINMAN_SYMBOLS to guard the macros, and define CONFIG_SPL_BINMAN_SYMBOLS in binman syms test. Tested-by: Tim Harvey

[PATCH 6/8] arm: dts: imx8m: shrink ddr firmware size to actual file size

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan After we switch to use BINMAN_SYMBOLS, there is no need to pad the file size to 0x8000 and 0x4000. After we use BINMAN_SYMBOLS, the u-boot-spl-ddr.bin shrink about 36KB with i.MX8MP-EVK. Tested-by: Tim Harvey #imx8m[m,n,p]-venice Signed-off-by: Peng Fan ---

[PATCH 5/8] ddr: imx8m: helper: load ddr firmware according to binman symbols

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan By reading binman symbols, we no need hard coded IMEM_LEN/DMEM_LEN after we update the binman dtsi to drop 0x8000/0x4000 length for the firmware. And that could save binary size for many KBs. Tested-by: Tim Harvey #imx8m[m,n,p]-venice Signed-off-by: Peng Fan ---

[PATCH 4/8] armv8: u-boot-spl.lds: mark __image_copy_start as symbol

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan In arch/arm/lib/sections.c there is below code: char __image_copy_start[0] __section(".__image_copy_start"); But actually 'objdump -t spl/u-boot-spl' not able to find out symbol '__image_copy_start' for binman update image-pos/size. So update link file Reviewed-by: Tom Rini

[PATCH 3/8] arm: dts: imx8m: update binman ddr firmware node name

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan We are migrating to use BINMAN SYMBOLS, the current name is not a valid binman type, so update to unify them. Also add `type = "blob-ext";` for generating a valid binman symbol The current names are inconsistent across different boards, so unify them. Also add `type =

[PATCH 2/8] configs: imx8mm_data_modul_edm_sbc: not select SPL_RAM_DEVICE

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan i.MX8M use FIT image, not RAW image. And to support binman symbols, u_boot_any could be optimized if RAW image is not selected, otherwise there will be build failure. So not select SPL_RAW_DEVICE Signed-off-by: Peng Fan --- configs/imx8mm_data_modul_edm_sbc_defconfig | 2 -- 1

[PATCH 1/8] spl: Kconfig: not select SPL_RAW_IMAGE_SUPPORT for i.MX8M

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan i.MX8M use FIT image, not RAW image. And to support binman symbols, u_boot_any could be optimized if RAW image is not selected, otherwise there will be build failure. So not select SPL_RAW_IMAGE_SUPPORT Signed-off-by: Peng Fan --- common/spl/Kconfig | 1 + 1 file changed, 1

[PATCH 0/8] arm64: binman: use binman symbols for imx

2022-06-03 Thread Peng Fan (OSS)
From: Peng Fan V6: Drop no-u-boot-any introduced in V5 Drop binman symbol replacement with @ to _, which is not needed Update imx8m config to not select RAM IMAGE and RAM DEVICE Update ddr firmware node name Introduce autoconf.h for binman test V5: Introduce no-u-boot-any property to drop

[PATCH v3 2/2] arm: k3: j721e: add dynamic sf bus override support for j721e

2022-06-03 Thread Vaishnav Achath
implement overrides for spl_spi_boot_bus() and spl_spi_boot_cs() lookup functions according to bootmode selection, so as to support both QSPI and OSPI boot using the same build. Signed-off-by: Vaishnav Achath Reviewed-by: Pratyush Yadav --- V2->V3 : removed unnecessary spl_spi_boot_cs()

[PATCH v3 1/2] common: spl: spl_spi: add support for dynamic override of sf bus

2022-06-03 Thread Vaishnav Achath
Currently the SPI flash to load from is defined through the compile time config CONFIG_SF_DEFAULT_BUS and CONFIG_SF_DEFAULT_CS, this prevents the loading of binaries from different SPI flash using the same build.E.g. supporting QSPI flash boot and OSPI flash boot on J721E platform is not possible

[PATCH v3 0/2] Add support for dynamic overriding of default SF bus

2022-06-03 Thread Vaishnav Achath
Currently the SPI flash to load from is defined through the compile time config CONFIG_SF_DEFAULT_BUS and CONFIG_SF_DEFAULT_CS, this prevents the loading of binaries from different SPI flash using the same build. This series adds support for choosing the flash device based on the selected boot