Re: [U-Boot] [PATCH v2 7/8] board: Add new slimbootloader board

2019-07-08 Thread Bin Meng
Hi Aiden, On Tue, Jul 9, 2019 at 8:02 AM Park, Aiden wrote: > > Hi Bin, > > > -Original Message- > > From: Park, Aiden > > Sent: Monday, July 8, 2019 9:48 AM > > To: Bin Meng > > Cc: U-Boot Mailing List ; Simon Glass > > > > Subject: RE: [PATCH v2 7/8] board: Add new slimbootloader

[U-Boot] [PATCH v6 3/5] arm64: dts: ti: k3-am65: add mcu cpsw node

2019-07-08 Thread Keerthy
From: Grygorii Strashko Add mcu cpsw and its components along with scm_conf node to have ethernet functional. Signed-off-by: Grygorii Strashko Signed-off-by: Keerthy Reviewed-by: Tom Rini Acked-by: Joe Hershberger --- Changes in v6: * Added Joe's Ack. arch/arm/dts/k3-am65.dtsi

[U-Boot] [PATCH v6 4/5] arm64: dts: k3-am654-base-board: add mcu cpsw nuss pinmux and phy defs

2019-07-08 Thread Keerthy
From: Grygorii Strashko Add mcu cpsw nuss pinmux and phy defs required by cpsw. Signed-off-by: Grygorii Strashko Signed-off-by: Keerthy Reviewed-by: Tom Rini Acked-by: Joe Hershberger --- Changes in v6: * Added Joe's Ack. arch/arm/dts/k3-am654-base-board-u-boot.dtsi | 59

[U-Boot] [PATCH v6 5/5] configs: am65x_evm_a53: enable networking

2019-07-08 Thread Keerthy
From: Grygorii Strashko Enable TI K3 AM65x CPSW NUSS driver. Signed-off-by: Grygorii Strashko Signed-off-by: Keerthy Reviewed-by: Tom Rini Acked-by: Joe Hershberger --- Changes in v6: * Removed unused HEXDUMP config. * Added Joe's Ack. configs/am65x_evm_a53_defconfig | 6 ++ 1

[U-Boot] [PATCH v6 2/5] net: ethernet: ti: Introduce am654 gigabit eth switch subsystem driver

2019-07-08 Thread Keerthy
Add new driver for the TI AM65x SoC Gigabit Ethernet Switch subsystem (CPSW NUSS). It has two ports and provides Ethernet packet communication for the device and can be configured as an Ethernet switch. CPSW NUSS features: the Reduced Gigabit Media Independent Interface (RGMII), Reduced Media

[U-Boot] [PATCH v6 0/5] net: ethernet: ti: Introduce am654 gigabit eth switch subsystem driver

2019-07-08 Thread Keerthy
Add new driver for the TI AM65x SoC Gigabit Ethernet Switch subsystem (CPSW NUSS). It has two ports and provides Ethernet packet communication for the device and can be configured as an Ethernet switch. CPSW NUSS features: the Reduced Gigabit Media Independent Interface (RGMII), Reduced Media

[U-Boot] [PATCH v6 1/5] driver: net: ti: cpsw-mdio: use phys_addr_t for mdio_base addr

2019-07-08 Thread Keerthy
Use phys_addr_t for mdio_base address to avoid build warnings on arm64 and dra7. Cast it to uintprt_t before assigning to regs. Signed-off-by: Grygorii Strashko Signed-off-by: Keerthy Reviewed-by: Tom Rini Acked-by: Joe Hershberger --- Changes in v6: * Added Joe's Ack.

Re: [U-Boot] [PATCH v5 5/5] configs: am65x_evm_a53: enable networking

2019-07-08 Thread Keerthy
On 09/07/19 4:27 AM, Joe Hershberger wrote: On Thu, Jun 6, 2019 at 7:15 AM Keerthy wrote: From: Grygorii Strashko Enable TI K3 AM65x CPSW NUSS driver. Signed-off-by: Grygorii Strashko Signed-off-by: Keerthy Reviewed-by: Tom Rini Question below, but... Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH v5 2/5] net: ethernet: ti: Introduce am654 gigabit eth switch subsystem driver

2019-07-08 Thread Keerthy
On 09/07/19 3:52 AM, Joe Hershberger wrote: On Thu, Jun 6, 2019 at 7:14 AM Keerthy wrote: From: Grygorii Strashko Add new driver for the TI AM65x SoC Gigabit Ethernet Switch subsystem (CPSW NUSS). It has two ports and provides Ethernet packet communication for the device and can be

Re: [U-Boot] [PATCH] common: fdt_support: Add missing cpu_to_fdt32() to fdt_pci_dma_ranges()

2019-07-08 Thread Marek Vasut
On 7/9/19 2:49 AM, Marek Vasut wrote: > The fdt_pci_dma_ranges() cannot work on e.g. ARM, since the DT entries > endianness is not adjusted at all. Fix this. > > Signed-off-by: Marek Vasut > Cc: Tom Rini +CC Simon > --- > common/fdt_support.c | 25 ++--- > 1 file changed,

[U-Boot] [PATCH V2] ARM: renesas: Update Gen3 PCIe dma-ranges before boot

2019-07-08 Thread Marek Vasut
Update "dma-ranges" DT property of all PCIe controllers in the system with the up-to-date DRAM layout. This allows the PCIe controller take full advantage of all the available DRAM. Signed-off-by: Marek Vasut Cc: Nobuhiro Iwamatsu --- V2: - Drop support for older kernels - Mark memory as

[U-Boot] [PATCH] common: fdt_support: Add missing cpu_to_fdt32() to fdt_pci_dma_ranges()

2019-07-08 Thread Marek Vasut
The fdt_pci_dma_ranges() cannot work on e.g. ARM, since the DT entries endianness is not adjusted at all. Fix this. Signed-off-by: Marek Vasut Cc: Tom Rini --- common/fdt_support.c | 25 ++--- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git

[U-Boot] [PATCH] ARM: renesas: Update Gen3 PCIe dma-ranges before boot

2019-07-08 Thread Marek Vasut
Update "dma-ranges" DT property of all PCIe controllers in the system with the up-to-date DRAM layout. This allows the PCIe controller take full advantage of all the available DRAM, at least in theory. This patch only populates up to two dma-ranges entry though, this is because older versions of

Re: [U-Boot] [PATCH v2 7/8] board: Add new slimbootloader board

2019-07-08 Thread Park, Aiden
Hi Bin, > -Original Message- > From: Park, Aiden > Sent: Monday, July 8, 2019 9:48 AM > To: Bin Meng > Cc: U-Boot Mailing List ; Simon Glass > > Subject: RE: [PATCH v2 7/8] board: Add new slimbootloader board > > Hi Bin, > > > -Original Message- > > From: Bin Meng

[U-Boot] [PATCH 4/5] ext4: gracefully fail on divide-by-0

2019-07-08 Thread Paul Emge
This patch checks for 0 in several ext4 headers and gracefully fails instead of raising a divide-by-0 exception. Signed-off-by: Paul Emge --- fs/ext4/ext4_common.c | 12 1 file changed, 12 insertions(+) diff --git a/fs/ext4/ext4_common.c b/fs/ext4/ext4_common.c index

[U-Boot] [PATCH 5/5] CVE-2019-13106: ext4: fix out-of-bounds memset

2019-07-08 Thread Paul Emge
In ext4fs_read_file in ext4fs.c, a memset can overwrite the bounds of the destination memory region. This patch adds a check to disallow this. Signed-off-by: Paul Emge --- fs/ext4/ext4fs.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/fs/ext4/ext4fs.c

[U-Boot] [PATCH 3/5] CVE-2019-13104: ext4: check for underflow in ext4fs_read_file

2019-07-08 Thread Paul Emge
in ext4fs_read_file, it is possible for a broken/malicious file system to cause a memcpy of a negative number of bytes, which overflows all memory. This patch fixes the issue by checking for a negative length. Signed-off-by: Paul Emge --- fs/ext4/ext4fs.c | 8 +--- 1 file changed, 5

[U-Boot] [PATCH 2/5] CVE-2019-13105: ext4: fix double-free in ext4_cache_read

2019-07-08 Thread Paul Emge
ext_cache_read doesn't null cache->buf, after freeing, which results in a later function double-freeing it. This patch fixes ext_cache_read to call ext_cache_fini instead of free. Signed-off-by: Paul Emge --- fs/ext4/ext4fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[U-Boot] [PATCH 1/5] CVE-2019-13103: disk: stop infinite recursion in DOS Partitions

2019-07-08 Thread Paul Emge
part_get_info_extended and print_partition_extended can recurse infinitely while parsing a self-referential filesystem or one with a silly number of extended partitions. This patch adds a limit to the number of recursive partitions. Signed-off-by: Paul Emge --- disk/part_dos.c | 18

Re: [U-Boot] [PATCH 6/6] net: macb: apply sane DMA configuration

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:51 AM Ramon Fried wrote: > > DMA configuration was heavily dependent on the HW > defaults, add function to properly set the required > fields, including the new dma_burst_length. > > Signed-off-by: Ramon Fried Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH 5/6] net: macb: add dma_burst_length config

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:39 AM Ramon Fried wrote: > > GEM support higher DMA burst writes/reads than the default (4). > add configuration structure with dma burst length so it could be > applied later to DMA configuration. > > Signed-off-by: Ramon Fried Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH 4/6] net: macb: add support for SGMII phy interface

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:50 AM Ramon Fried wrote: > > This patch adds support for the sgmii phy interface, > available only to DM users, dictated by current driver > design. > > Signed-off-by: Ramon Fried Acked-by: Joe Hershberger ___ U-Boot

Re: [U-Boot] [PATCH 3/6] net: macb: use bit access macro from header file

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:52 AM Ramon Fried wrote: > > macb.h provides macros for reading/setting bitfields, > in macb registers and descriptors. use that instead > of redefining them in the source file. > > Signed-off-by: Ramon Fried Acked-by: Joe Hershberger

[U-Boot] [PATCH 2/2] efi_loader: Return non-zero for error in efi_add_memory_map()

2019-07-08 Thread Bryan O'Donoghue
If we are trying to map address zero, as is the case on raspberrypi, then we have no way of telling the difference between a valid efi_add_memory_map() at zero and an overlapping error at zero. Instead of returning zero, return EFI_NO_MAPPING on carve-out errors. In include/efi.h we can see that

[U-Boot] [PATCH 0/2] efi_loader: Fix inconsistencies in efi_add_memory_map usage

2019-07-08 Thread Bryan O'Donoghue
These two patches fix some inconsistent usage around efi_add_memory_map(). The first patch fixes the case where there is a mapping for an address starting at 0 as is the case on RPI3. We should not print an error for this. efi_add_memory_map(start = 0, ...) succeeds but efi_carve_out_dt_rsv()

[U-Boot] [PATCH 1/2] efi_loader: Check the result of efi_add_memory_map against input addr

2019-07-08 Thread Bryan O'Donoghue
We should check the result of efi_add_memory_map() against the first input parameter, not against zero. In efi_carve_out_dt_rsv() add_efi_memory_map() gets passed addr = 0. The function succeeds but the parsing routine interprets zero as an error. Fix that now by comparing the result code of

Re: [U-Boot] [PATCH 2/6] net: macb: add support for faster clk rates

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:40 AM Ramon Fried wrote: > > add support for clock rates higher than 2.4Mhz > > Signed-off-by: Ramon Fried Acked-by: Joe Hershberger ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot

Re: [U-Boot] [PATCH 1/6] net: macb: sync header definitions as taken from Linux

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 10:51 AM Ramon Fried wrote: > > Few registers and bits were added by Cadence and > they were not updated in the headers. > Take the latest definitions as defined in Linux > header (5.1) that also includes some comments > about existing registers. > > One register was

Re: [U-Boot] [PATCH v3] net: phy: cortina: Use block layer to read from mmc

2019-07-08 Thread Joe Hershberger
On Tue, Jun 11, 2019 at 1:27 AM Yinbo Zhu wrote: > > This patch is to use block layer to read from mmc in cortina > > Signed-off-by: Yinbo Zhu Acked-by: Joe Hershberger ___ U-Boot mailing list U-Boot@lists.denx.de

Re: [U-Boot] [RESEND Patch] net: mscc: refactor mscc_miim

2019-07-08 Thread Joe Hershberger
On Sun, Jun 9, 2019 at 8:28 AM Horatiu Vultur wrote: > > Because all MSCC SoC use the same MDIO bus, put the implementation in > one common file(mscc_miim) and make all the other MSCC network drivers to > use these functions. > > Signed-off-by: Horatiu Vultur Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH 2/2] net: macb: Add support for 1000-baseX

2019-07-08 Thread Joe Hershberger
On Fri, Jun 7, 2019 at 8:48 AM Radu Pirea wrote: > > Macb can be used with Xilinx PCS/PMA PHY in fpga which is a 1000-baseX > phy(lpa 0x41e0). This patch adds checks for LPA_1000XFULL and > LPA_1000XHALF bits. > > Signed-off-by: Radu Pirea Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH 1/2] net: macb: Fixed reading MII_LPA register

2019-07-08 Thread Joe Hershberger
On Fri, Jun 7, 2019 at 8:48 AM Radu Pirea wrote: > > If macb is gem and is gigabit capable, lpa value is not read from > the right register(MII_LPA) and is read from MII_STAT1000. This patch > fixes reading of the lpa value. > > Signed-off-by: Radu Pirea Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH v5 5/5] configs: am65x_evm_a53: enable networking

2019-07-08 Thread Joe Hershberger
On Thu, Jun 6, 2019 at 7:15 AM Keerthy wrote: > > From: Grygorii Strashko > > Enable TI K3 AM65x CPSW NUSS driver. > > Signed-off-by: Grygorii Strashko > Signed-off-by: Keerthy > Reviewed-by: Tom Rini Question below, but... Acked-by: Joe Hershberger > --- >

Re: [U-Boot] [PATCH v5 4/5] arm64: dts: k3-am654-base-board: add mcu cpsw nuss pinmux and phy defs

2019-07-08 Thread Joe Hershberger
On Thu, Jun 6, 2019 at 7:15 AM Keerthy wrote: > > From: Grygorii Strashko > > Add mcu cpsw nuss pinmux and phy defs required by cpsw. > > Signed-off-by: Grygorii Strashko > Signed-off-by: Keerthy > Reviewed-by: Tom Rini Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH v5 3/5] arm64: dts: ti: k3-am65: add mcu cpsw node

2019-07-08 Thread Joe Hershberger
On Thu, Jun 6, 2019 at 7:15 AM Keerthy wrote: > > From: Grygorii Strashko > > Add mcu cpsw and its components along with scm_conf node > to have ethernet functional. > > Signed-off-by: Grygorii Strashko > Signed-off-by: Keerthy > Reviewed-by: Tom Rini Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH v5 2/5] net: ethernet: ti: Introduce am654 gigabit eth switch subsystem driver

2019-07-08 Thread Joe Hershberger
On Thu, Jun 6, 2019 at 7:14 AM Keerthy wrote: > > From: Grygorii Strashko > > Add new driver for the TI AM65x SoC Gigabit Ethernet Switch subsystem (CPSW > NUSS). It has two ports and provides Ethernet packet communication for the > device and can be configured as an Ethernet switch. CPSW NUSS

Re: [U-Boot] [EXT] Re: [PATCH 1/2 v3] net: introduce MDIO DM class for MDIO devices

2019-07-08 Thread Alex Marginean
On 7/9/2019 12:40 AM, Joe Hershberger wrote: On Fri, Jun 14, 2019 at 1:26 PM Alex Marginean wrote: Hi Nevo, On 6/14/2019 7:55 PM, Nevo Hed wrote: Hi Alex In another thread (https://lists.denx.de/pipermail/u-boot/2019-June/371933.html) I asked Ken (before learning of their cut-backs) if I

Re: [U-Boot] [ANN] U-Boot v2019.07 released

2019-07-08 Thread Tom Rini
On Mon, Jul 08, 2019 at 10:50:12PM +0100, Peter Robinson wrote: > Hi Tom, > > > So it is release day and once again we've had a few important fixes come > > in over the last few days. But I still feel comfortable doing the > > release today. Our next release is v2019.10 and I am hopeful this

Re: [U-Boot] [PATCH v5 1/5] driver: net: ti: cpsw-mdio: use phys_addr_t for mdio_base addr

2019-07-08 Thread Joe Hershberger
On Thu, Jun 6, 2019 at 7:13 AM Keerthy wrote: > > Use phys_addr_t for mdio_base address to avoid build > warnings on arm64 and dra7. Cast it to uintprt_t before > assigning to regs. > > Signed-off-by: Grygorii Strashko > Signed-off-by: Keerthy > Reviewed-by: Tom Rini Acked-by: Joe Hershberger

Re: [U-Boot] [ANN] U-Boot v2019.07 released

2019-07-08 Thread Peter Robinson
Hi Tom, > So it is release day and once again we've had a few important fixes come > in over the last few days. But I still feel comfortable doing the > release today. Our next release is v2019.10 and I am hopeful this cycle > of fixes coming in at the end will happen, rather than seeing

Re: [U-Boot] [PATCH v5 0/5] net: ethernet: ti: Introduce am654 gigabit eth switch subsystem driver

2019-07-08 Thread Joe Hershberger
On Tue, Jul 2, 2019 at 12:07 AM Keerthy wrote: > > > > On 06/06/19 5:43 PM, Keerthy wrote: > > Add new driver for the TI AM65x SoC Gigabit Ethernet Switch subsystem (CPSW > > NUSS). It has two ports and provides Ethernet packet communication for the > > device and can be configured as an Ethernet

Re: [U-Boot] [EXT] Re: [PATCH 1/2 v3] net: introduce MDIO DM class for MDIO devices

2019-07-08 Thread Joe Hershberger
On Fri, Jun 14, 2019 at 1:26 PM Alex Marginean wrote: > > Hi Nevo, > > On 6/14/2019 7:55 PM, Nevo Hed wrote: > > Hi Alex > > > > In another thread > > (https://lists.denx.de/pipermail/u-boot/2019-June/371933.html) > > I asked Ken (before learning of their cut-backs) if I should take a > > stab

Re: [U-Boot] [PATCH] net: mscc: serval: Remove delay when serdes is configured

2019-07-08 Thread Joe Hershberger
On Thu, May 23, 2019 at 2:48 PM Horatiu Vultur wrote: > > When serdes configuration was written in hardware there was a delay > of 100ms to be sure that configuration was written. But the delay is not > needed because already the function serdes_write it is checking that the > operation finished.

Re: [U-Boot] [u-boot 2/2] drivers/fsl-mc: Support DPSPARSER object and apply spb command

2019-07-08 Thread Joe Hershberger
On Wed, May 15, 2019 at 4:10 AM Florinel Iordache wrote: > > Add support for DPSPARSER object (create/destroy, open/close, apply spb) > required to configure Soft Parser by using MC. Also add uboot command to > apply a Soft Parser Blob by using a command like: fsl_mc apply spb > > >

[U-Boot] [PATCH v2 31/31] binman: Add a test for nested and aligned sections

2019-07-08 Thread Simon Glass
Current test coverage is likely sufficient for the logic used to place sections in the image. However it seems useful to add a test specifically for nested sections, since these could have some unusual interactions. Add a new test for this and aligned sections. This test failed before the

[U-Boot] [PATCH v2 21/31] binman: Allow listing the entries in an image

2019-07-08 Thread Simon Glass
It is useful to be able to summarise all the entries in an image, e.g. to display this to this user. Add a new ListEntries() method to Entry, and set up a way to call it through the Image class. Signed-off-by: Simon Glass --- Changes in v2: - Add the Entry object to EntryInfo as well - Change

[U-Boot] [PATCH v2 19/31] binman: Support FDT update for CBFS

2019-07-08 Thread Simon Glass
It is useful to add the CBFS file information (offset, size, etc.) into the FDT so that the layout is complete. Add support for this. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/etype/cbfs.py| 49 +-- tools/binman/ftest.py

[U-Boot] [PATCH v2 25/31] binman: Convert Image to a subclass of Entry

2019-07-08 Thread Simon Glass
When support for sections (and thus hierarchical images) was added to binman, the decision was made to create a new Section class which could be used by both Image and an Entry_section class. The decision between using inheritance and composition was tricky to make, but in the end it was decided

[U-Boot] [PATCH v2 24/31] binman: Support reading an image into an Image object

2019-07-08 Thread Simon Glass
It is possible to read an Image, locate its FDT map and then read it into the binman data structures. This allows full access to the entries that were written to the image. Add support for this. Signed-off-by: Simon Glass --- Changes in v2: - Deal with travis's old lz4 version by skipping tests

[U-Boot] [PATCH v2 26/31] binman: Support listing an image

2019-07-08 Thread Simon Glass
Add support for listing the entries in an image. This relies on the image having an FDT map. Signed-off-by: Simon Glass --- Changes in v2: - Adjust the test to not rely on lz4 compression version - Allow listing subsets of the image - Change list command from 'list' to 'ls' - Deal with travis's

[U-Boot] [PATCH v2 20/31] binman: Detect bad CBFS file types

2019-07-08 Thread Simon Glass
Detect when an unknown or unsupported file type is specified and report an error. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/etype/cbfs.py | 3 +++ tools/binman/ftest.py | 6 ++ tools/binman/test/126_cbfs_bad_type.dts | 17

[U-Boot] [PATCH v2 16/31] binman: Allow device-tree entries to be compressed

2019-07-08 Thread Simon Glass
At present the logic skips the blob class' handling of compression, so this is not supported with device tree entries. Fix this. Signed-off-by: Simon Glass --- Changes in v2: - Update test to use _DoReadFileRealDtb() helper tools/binman/etype/blob.py | 25 +

[U-Boot] [PATCH v2 07/31] binman: Convert to use ArgumentParser

2019-07-08 Thread Simon Glass
This class is the new way to handle arguments in Python. Convert binman over to use it. At the same time, introduce commands so that we can separate out the different parts of binman functionality. Signed-off-by: Simon Glass --- Changes in v2: - Don't allow global arguments after the command -

[U-Boot] [PATCH v2 11/31] binman: Fix up ProcessUpdateContents error and comments

2019-07-08 Thread Simon Glass
This function raises an exception with its arguments around the wrong way so the message is incorrect. Fix this as well as a few minor comment problems. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/entry.py | 8 tools/binman/ftest.py | 2 +- 2 files changed, 5

[U-Boot] [PATCH v2 22/31] binman: Support locating an FDT map

2019-07-08 Thread Simon Glass
Add support for locating an image's Fdt map which is used to determine the contents and structure of the image. Signed-off-by: Simon Glass --- Changes in v2: - Adjust LocateFdtmap() to return the position of the header - Update commit subject to more accurately describe this patch - Update test

[U-Boot] [PATCH v2 30/31] binman: Add an 'extract' command

2019-07-08 Thread Simon Glass
It is useful to be able to extract all binaries from the image, or a subset of them. Add a new 'extract' command to handle this. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README | 25 +- tools/binman/cmdline.py | 13 +++ tools/binman/control.py | 60

[U-Boot] [PATCH v2 12/31] binman: Call ProcessUpdateContents() consistently

2019-07-08 Thread Simon Glass
SetContents() should only be called to set the contents of an entry from within the ObtainContents() call, since it has no guard against increasing the size of the contents, thus triggering incorrect operation. Change all such calls to use ProcessUpdateContents() instead. Signed-off-by: Simon

[U-Boot] [PATCH v2 28/31] binman: Allow reading an entry from an image

2019-07-08 Thread Simon Glass
It is useful to be able to extract entry contents from an image to see what is inside. Add a simple function to read the contents of an entry, decompressing it by default. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/control.py| 20 ++

[U-Boot] [PATCH v2 23/31] binman: Support locating an image header

2019-07-08 Thread Simon Glass
Add support for locating an image header in an image. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/etype/image_header.py | 23 +++ tools/binman/ftest.py | 27 +++ 2 files changed, 50 insertions(+) diff --git

[U-Boot] [PATCH v2 06/31] binman: Add an image header

2019-07-08 Thread Simon Glass
It is useful to be able to quickly locate the FDT map in the image. An easy way to do this is with a pointer at the start or end of the image. Add an 'image header' entry, which places a magic number followed by a pointer to the FDT map. This can be located at the start or end of the image, or at

[U-Boot] [PATCH v2 29/31] binman: Support reading from CBFS entries

2019-07-08 Thread Simon Glass
CBFS is a bit like a section but with a custom format. Provide the list of entries and the compression type to binman so that it can extract the data from the CBFS, just like any other part of the image. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/cbfs_util.py | 14

[U-Boot] [PATCH v2 18/31] binman: Use the cbfs memlen field only for uncompressed length

2019-07-08 Thread Simon Glass
The purpose of this badly named field is a bit ambiguous. Adjust the code to use it only to store the uncompressed length of a file, leaving it set to None if there is no compression used. This makes it easy to see if the value in this field is relevant / useful. Also set data_len for compressed

[U-Boot] [PATCH v2 14/31] binman: Add a control for post-pack entry expansion

2019-07-08 Thread Simon Glass
We plan to support changing the size of entries after they have been packed. For now it will always be enabled. But to aid testing of both cases (in the event that we want to add a command-line flag, for example), add a setting to control it. Signed-off-by: Simon Glass --- Changes in v2: None

[U-Boot] [PATCH v2 15/31] binman: Allow entries to expand after packing

2019-07-08 Thread Simon Glass
Add support for detecting entries that change size after they have already been packed, and re-running packing when it happens. This removes the limitation that entry size cannot change after PackEntries() is called. Signed-off-by: Simon Glass --- Changes in v2: - Avoid dual assignment in

[U-Boot] [PATCH v2 27/31] binman: Allow for logging information to be displayed

2019-07-08 Thread Simon Glass
Binman generally operates silently but in some cases it is useful to see what Binman is actually doing at each step. Enable some logging output with different logging levels selectable via the -v flag. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README | 19

[U-Boot] [PATCH v2 17/31] binman: Provide the actual data address for cbfs files

2019-07-08 Thread Simon Glass
At present a file with no explicit CBFS offset is placed in the next available location but there is no way to find out where it ended up. Update and rename the get_data() function to provide this information. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/cbfs_util.py | 31

[U-Boot] [PATCH v2 09/31] binman: Drop an unused arg in Entry.Lookup()

2019-07-08 Thread Simon Glass
The first argument is not used. Remove it. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/entry.py | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tools/binman/entry.py b/tools/binman/entry.py index 82ed5f0..00bb1d190a9 100644 ---

[U-Boot] [PATCH v2 08/31] binman: Move compression into the Entry base class

2019-07-08 Thread Simon Glass
Compression is currently available only with blobs. However we want to report the compression algorithm and uncompressed size for all entries, so that other entry types can support compression. This will help with the forthcoming 'list' feature which lists entries in the image. Move the

[U-Boot] [PATCH v2 10/31] binman: Allow easy importing of entry modules

2019-07-08 Thread Simon Glass
At present entry modules can only be accessed using Entry.Lookup() or Entry.Create(). Most of the time this is fine, but sometimes a module needs to provide constants or helper functions useful to other modules. It is easier in this case to use 'import'. Add an __init__ file to permit this.

[U-Boot] [PATCH v2 13/31] binman: Add a return value to ProcessContentsUpdate()

2019-07-08 Thread Simon Glass
At present if this function tries to update the contents such that the size changes, it raises an error. We plan to add the ability to change the size of entries after packing is completed, since in some cases it is not possible to determine the size in advance. An example of this is with a

[U-Boot] [PATCH v2 05/31] binman: Add an FDT map

2019-07-08 Thread Simon Glass
An FDT map is an entry which holds a full description of the image entries, in FDT format. It can be discovered using the magic string at its start. Tools can locate and read this entry to find out what entries are in the image and where each entry is located. Signed-off-by: Simon Glass ---

[U-Boot] [PATCH v2 03/31] binman: Update help for new features

2019-07-08 Thread Simon Glass
A few new features have been added. This has rendered part of the README obsolete. Update it. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tools/binman/README b/tools/binman/README index

[U-Boot] [PATCH v2 04/31] binman: Add a convenience functions for real-DTB tests

2019-07-08 Thread Simon Glass
Quite a few tests will use a real device tree and need it updated with the binman metadata. Add a helper function for this. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/ftest.py | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git

[U-Boot] [PATCH v2 02/31] binman: Update future features

2019-07-08 Thread Simon Glass
A few features have been completed and a few items are added. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tools/binman/README b/tools/binman/README index 2f4c7fec21e..1851a4e536d 100644

[U-Boot] [PATCH v2 01/31] binman: Simplify the entry test

2019-07-08 Thread Simon Glass
The current test for the 'entry' module is a bit convoluted since it has to import the module multiple times. It also relies on ordering, in that test1EntryNoImportLib() must run before test2EntryImportLib() if they are running in the same Python process. This is unreliable since neither the

[U-Boot] [PATCH v2 00/31] binman: Allow reading of images to list contents

2019-07-08 Thread Simon Glass
This series adds features to allow binman to read its own images. Using an 'FDT map' inside the image (basically a cut-down copy of the input config with some pieces added) it can reverse-engineer the image and figure out what is where. Uses of this feature are - a new 'ls' command, which allows

Re: [U-Boot] [u-boot 1/2] drivers/fsl-mc: Create Kconfig file to manage driver specific configs better

2019-07-08 Thread Joe Hershberger
On Wed, May 15, 2019 at 4:09 AM Florinel Iordache wrote: > > Create drivers/net/fsl-mc/Kconfig and move fsl-mc specific configs > from arch/arm/cpu/armv8/fsl-layerscape/Kconfig to this new Kconfig > > Signed-off-by: Florinel Iordache Acked-by: Joe Hershberger

Re: [U-Boot] [PATCH] net: phy: ti: Fix clock output DT property

2019-07-08 Thread Joseph Hershberger
> -Original Message- > From: Trent Piepho > Sent: Friday, May 10, 2019 12:49 PM > To: u-boot@lists.denx.de > Cc: Trent Piepho ; Joseph Hershberger > ; Janine Hagemann > ; Grygorii Strashko > Subject: [EXTERNAL] [PATCH] net: phy: ti: Fix clock output DT property > > The code block

Re: [U-Boot] [PATCH] net: phy: ti: Use default values for tx/rx delay and fifo size

2019-07-08 Thread Joseph Hershberger
> -Original Message- > From: Trent Piepho > Sent: Thursday, May 09, 2019 2:42 PM > To: u-boot@lists.denx.de > Cc: Trent Piepho ; Joseph Hershberger > ; Janine Hagemann > ; Grygorii Strashko > Subject: [EXTERNAL] [PATCH] net: phy: ti: Use default values for tx/rx delay > and fifo size >

[U-Boot] [PATCH v2 19/37] binman: Don't assume there is an ME region

2019-07-08 Thread Simon Glass
At present having a descriptor means that there is an ME (Intel Management Engine) entry as well. The descriptor provides the ME location and assumes that it is present. For some SoCs this is not true. Before providing the location of a potentially non-existent entry, check if it is present.

[U-Boot] [PATCH v2 32/37] patman: Add a function to write ifwitool

2019-07-08 Thread Simon Glass
This tool has quite a few arguments and options, so put the functionality in a function so that we call it from one place and hopefully get it right. Signed-off-by: Simon Glass --- Changes in v2: None tools/patman/tools.py | 33 + 1 file changed, 33

[U-Boot] [ANN] U-Boot v2019.07 released

2019-07-08 Thread Tom Rini
Hey all, So it is release day and once again we've had a few important fixes come in over the last few days. But I still feel comfortable doing the release today. Our next release is v2019.10 and I am hopeful this cycle of fixes coming in at the end will happen, rather than seeing problems

[U-Boot] [PATCH v2 28/37] binman: Fix up the _DoTestFile() function -u argument

2019-07-08 Thread Simon Glass
This should be -u, not -up, since we don't need to preserve the output directory in this case. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/ftest.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py index

[U-Boot] [PATCH v2 37/37] binman: Add support for fixed-offset files in CBFS

2019-07-08 Thread Simon Glass
A feature of CBFS is that it allows files to be positioned at particular offset (as with binman in general). This is useful to support execute-in-place (XIP) code, since this may not be relocatable. Add a new cbfs-offset property to control this. Signed-off-by: Simon Glass --- Changes in v2: -

[U-Boot] [PATCH v2 08/37] patman: Add a way to set the search path for tools

2019-07-08 Thread Simon Glass
Sometimes tools can be located by looking in other locations. Add a way to direct the search. Signed-off-by: Simon Glass --- Changes in v2: None tools/patman/tools.py | 42 +- 1 file changed, 37 insertions(+), 5 deletions(-) diff --git

[U-Boot] [PATCH v2 36/37] binman: Pad empty areas of the CBFS with files

2019-07-08 Thread Simon Glass
When there is lots of open space in a CBFS it is normally padded with 'empty' files so that sequentially scanning the CBFS can skip from one to the next without a break. Add support for this. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/cbfs_util.py | 68

[U-Boot] [PATCH v2 22/37] patman: Add functions to compress and decompress data

2019-07-08 Thread Simon Glass
Add utility functions to compress and decompress using lz4 and lzma algorithms. In the latter case these use the legacy lzma support favoured by coreboot's CBFS. No tests are provided as these functions will be tested by the CBFS tests in a separate patch. Signed-off-by: Simon Glass ---

Re: [U-Boot] [PULL] u-boot-mips

2019-07-08 Thread Tom Rini
On Fri, Jul 05, 2019 at 05:29:43PM +0200, Daniel Schwierzeck wrote: > Hi Tom, > > please pull a fix for network instability on MT7688 Gardena Smart Gateway. > This should go into 2019.07, thanks. > > > The following changes since commit 1f83431f0053f6fb20c511c391ffc687433848cf: > > board:

[U-Boot] [PATCH v2 30/37] binman: Allow preserving test directories

2019-07-08 Thread Simon Glass
Sometimes when debugging tests it is useful to keep the input and output directories so they can be examined later. Add an option for this and update the binman tests to support it. This affects both the test class and the tearDown() function called after each test. Signed-off-by: Simon Glass

[U-Boot] [PATCH v2 23/37] binman: Use the tools.Decompress method

2019-07-08 Thread Simon Glass
Update the compression test to use the tools module to decompress the output data. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/ftest.py | 13 ++--- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py index

[U-Boot] [PATCH v2 34/37] binman: Add support for CBFS entries

2019-07-08 Thread Simon Glass
Add support for putting CBFSs (Coreboot Filesystems) in an image. This allows binman to produce firmware images used by coreboot to boot. Signed-off-by: Simon Glass --- Changes in v2: - Deal with travis's old lz4 version by skipping tests as necessary - Skip use of cbfstool in tests if it is

[U-Boot] [PATCH v2 10/37] binman: Add missing comments to bsection

2019-07-08 Thread Simon Glass
Some functions lack comments in this file. Add comments to cover this functionality. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/bsection.py | 23 +++ 1 file changed, 23 insertions(+) diff --git a/tools/binman/bsection.py b/tools/binman/bsection.py

[U-Boot] [PATCH v2 27/37] binman: Support ELF files for TPL

2019-07-08 Thread Simon Glass
We currenty support using the ELF file in U-Boot proper and SPL, but not TPL. Add this as it is useful both with sandbox and for CBFS to allow adding TPL as a 'stage'. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README.entries | 11 +++

[U-Boot] [PATCH v2 29/37] binman: Allow verbosity control when running tests

2019-07-08 Thread Simon Glass
At present the -v flag is ignored with tests, so that (for example) -v2 does not have any effect. Update binman to pass this flag through to tests so that they work just like running binman normally, except in a few special cases where we are actually testing behaviour with different levels of

[U-Boot] [PATCH v2 33/37] binman: Add a utility library for coreboot CBFS

2019-07-08 Thread Simon Glass
Coreboot uses a simple flash-based filesystem called Coreboot Filesystem (CBFS) to organise files used during boot. This allows files to be named and their position in the flash to be set. It has special features for dealing with x86 devices which typically memory-map their SPI flash to the top of

[U-Boot] [PATCH v2 35/37] binman: Add support for Intel IFWI entries

2019-07-08 Thread Simon Glass
An Integrated Firmware Image is used to hold various binaries used for booting with Apollolake and some later devices. Add support for this. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/etype/intel_descriptor.py| 6 +- tools/binman/etype/intel_ifwi.py

[U-Boot] [PATCH v2 26/37] binman: Correct comment in u_boot_spl_elf

2019-07-08 Thread Simon Glass
This comment mentions the wrong default filename. Fix it. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/README.entries | 2 +- tools/binman/etype/u_boot_spl_elf.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/binman/README.entries

[U-Boot] [PATCH v2 24/37] binman: Drop unnecessary debug handling

2019-07-08 Thread Simon Glass
The -D option enables debug mode, but we only need to add -D to the command line once. Drop the duplicate code. Also drop the comment about enabling debugging since this can be done with -D. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/binman.py | 5 - 1 file changed,

[U-Boot] [PATCH v2 13/37] binman: Use a better error for missing Intel descriptor

2019-07-08 Thread Simon Glass
FD is a bit confusing so write this out in full. Also avoid splitting the string so that people can grep for the error message more easily. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/etype/intel_descriptor.py | 2 +- tools/binman/ftest.py | 4 ++-- 2

[U-Boot] [PATCH v2 17/37] binman: Ensure that coverage has access to site packages

2019-07-08 Thread Simon Glass
Code coverage tests fail on binman due to dist-packages being dropped from the python path on Ubuntu 16.04. Add them in so that we can find the elffile module, which is required by binman. Signed-off-by: Simon Glass --- Changes in v2: None tools/binman/binman.py | 8 1 file changed,

  1   2   >