Re: [U-Boot] [PATCH] cmd: env: fix a typo in a comment of do_env_set_efi()

2019-10-03 Thread Heinrich Schuchardt
On 10/4/19 6:46 AM, AKASHI Takahiro wrote: A wrong function name is referred to in a comment of do_env_set_efi(). Signed-off-by: AKASHI Takahiro Reviewed-by: Heinrich Schuchardt --- cmd/nvedit_efi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/nvedit_efi.c

[U-Boot] [PATCH] efi_loader: device_path: allow for arbitrary length of file path

2019-10-03 Thread AKASHI Takahiro
This patch will lift the upper limit of maximum path length. Signed-off-by: AKASHI Takahiro --- lib/efi_loader/efi_device_path.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lib/efi_loader/efi_device_path.c b/lib/efi_loader/efi_device_path.c index

[U-Boot] [PATCH] cmd: env: fix a typo in a comment of do_env_set_efi()

2019-10-03 Thread AKASHI Takahiro
A wrong function name is referred to in a comment of do_env_set_efi(). Signed-off-by: AKASHI Takahiro --- cmd/nvedit_efi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/nvedit_efi.c b/cmd/nvedit_efi.c index 795c95be0ef7..d882ecdcbb6e 100644 --- a/cmd/nvedit_efi.c +++

[U-Boot] [PATCH] sandbox: fix build error due to missing struct udevice definition

2019-10-03 Thread AKASHI Takahiro
Without this patch, compiling may potentially fail. Signed-off-by: AKASHI Takahiro --- arch/sandbox/include/asm/u-boot-sandbox.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/sandbox/include/asm/u-boot-sandbox.h b/arch/sandbox/include/asm/u-boot-sandbox.h index

Re: [U-Boot] [PATCH v2 37/38] x86: Add various MTRR indexes and values

2019-10-03 Thread Bin Meng
On Wed, Oct 2, 2019 at 10:08 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > Add some new MTRRs used by Apollolake as well as a mask for the MTRR > > type. > > > > Signed-off-by: Simon Glass > > --- > > > > Changes in v2: None > > > >

Re: [U-Boot] [PATCH v2 38/38] x86: Rename turbo ratio MSR to MSR_TURBO_RATIO_LIMIT

2019-10-03 Thread Bin Meng
On Wed, Oct 2, 2019 at 10:08 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > This MSR number is used on most modern Intel processors, so drop the > > confusing NHM prefix (which might mean Nehalem). > > > > Signed-off-by: Simon Glass > > --- > > > > Changes in

Re: [U-Boot] [PATCH v2 34/38] x86: Change condition for using CAR

2019-10-03 Thread Bin Meng
On Wed, Oct 2, 2019 at 10:07 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > At present we assume that CAR (Cache-as-RAM) is used if HOBs (Hand-off > > bLocks) are not, since HOBs typically indicate that an FSP is in use, and > > nits: blocks > > > FSPs handle

Re: [U-Boot] [PATCH v2 35/38] x86: Add more comments to the start-up code

2019-10-03 Thread Bin Meng
On Wed, Oct 2, 2019 at 10:07 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > The full start-up sequence (TPL->SPL->U-Boot) can be a bit confusing since > > each phase has its own 'start' file. Add comments to explain this. > > > > Signed-off-by: Simon Glass >

Re: [U-Boot] [PATCH v2 32/38] x86: fsp: Save usable RAM and hob_list in the handoff area

2019-10-03 Thread Bin Meng
On Fri, Oct 4, 2019 at 11:06 AM Bin Meng wrote: > > On Wed, Oct 2, 2019 at 10:07 PM Bin Meng wrote: > > > > Hi Simon, > > > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > > > The useable RAM is calculated when the RAM is inited. Save this value so > > > that it can be easily used

Re: [U-Boot] [PATCH v2 33/38] x86: fsp: Allow the HOBs to be used after relocation

2019-10-03 Thread Bin Meng
Hi Simon, On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > Allocate memory for the HOBs and copy them before relocation. This ensures > that they can still be accessed after relocation. > > This is needed when relocating the HOB within U-Boot. > > Signed-off-by: Simon Glass > --- > >

Re: [U-Boot] [PATCH v4 10/17] arm: socfpga: agilex: Add CCU support for Agilex

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 4:42 PM Simon Goldschmidt wrote: > > On Thu, Sep 12, 2019 at 12:12 PM Ley Foon Tan wrote: > > > > Add Cache Coherency Unit (CCU) support for Agilex. > > CCU is to ensures consistency of shared data between multi masters > > in the system. > > Wouldn't this better fit into

Re: [U-Boot] [PATCH v4 12/17] ddr: altera: Restructure Stratix 10 SDRAM driver

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 5:09 PM Simon Goldschmidt wrote: > > On Thu, Sep 12, 2019 at 12:12 PM Ley Foon Tan wrote: > > > > Restructure Stratix 10 SDRAM driver. Move common code to separate > > file, in preparation to support SDRAM driver for Agilex. > > > > Signed-off-by: Ley Foon Tan > > > > ---

Re: [U-Boot] [PATCH v2 32/38] x86: fsp: Save usable RAM and hob_list in the handoff area

2019-10-03 Thread Bin Meng
On Wed, Oct 2, 2019 at 10:07 PM Bin Meng wrote: > > Hi Simon, > > On Wed, Sep 25, 2019 at 10:13 PM Simon Glass wrote: > > > > The useable RAM is calculated when the RAM is inited. Save this value so > > that it can be easily used in U-Boot proper. > > > > Also save a pointer to the hob list so

Re: [U-Boot] [PATCH v4 04/17] arm: socfpga: agilex: Add reset manager support

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 6:16 PM Simon Goldschmidt wrote: > > On Wed, Oct 2, 2019 at 11:25 AM Ley Foon Tan wrote: > > > > On Wed, Oct 2, 2019 at 4:26 PM Simon Goldschmidt > > wrote: > > > > > > On Thu, Sep 12, 2019 at 12:11 PM Ley Foon Tan > > > wrote: > > > > > > > > Add reset manager support

Re: [U-Boot] [PATCH v2 3/4] arm: socfpga: Convert system manager from struct to defines

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 5:20 PM Simon Goldschmidt wrote: > > On Tue, Sep 10, 2019 at 10:38 AM Ley Foon Tan wrote: > > > > Convert system manager for Gen5, Arria 10 and Stratix 10 from struct > > to defines. > > No functional change. > > > > Signed-off-by: Ley Foon Tan > > > > --- > > v2: > > -

[U-Boot] [PATCH v3 2/4] fs: add fs_get_type() for current filesystem type

2019-10-03 Thread AKASHI Takahiro
This function is a variant of fs_get_type_name() and returns a filesystem type with which the current device is associated. We don't want to export fs_type variable directly because we have to take care of it consistently within fs.c. Signed-off-by: AKASHI Takahiro --- fs/fs.c | 13

Re: [U-Boot] [PATCH v2 2/4] arm: socfpga: Convert reset manager from struct to defines

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 5:20 PM Simon Goldschmidt wrote: > > On Tue, Sep 10, 2019 at 10:38 AM Ley Foon Tan wrote: > > > > Convert reset manager for Gen5, Arria 10 and Stratix 10 from struct > > to defines. > > No functional change. > > > > Signed-off-by: Ley Foon Tan > > > > --- > > v2: > > -

[U-Boot] [PATCH v3 3/4] efi_loader: disk: install FILE_SYSTEM_PROTOCOL only if available

2019-10-03 Thread AKASHI Takahiro
In the current implementation, EFI_SIMPLEFILE_SYSTEM_PROTOCOL is always installed to all the partitions even if some of them may house no file system. With this patch, that protocol will be installed only if any file system exists. Signed-off-by: AKASHI Takahiro --- lib/efi_loader/efi_disk.c |

[U-Boot] [PATCH v3 4/4] efi_loader: disk: install file system protocol to a whole disk

2019-10-03 Thread AKASHI Takahiro
Currently, a whole disk without any partitions is not associated with EFI_SIMPLE_FILE_SYSTEM_PROTOCOL. So even if it houses some file system, there is a chance that we may not be able to access it, particularly, when accesses are to be attempted after searching that protocol against a device

[U-Boot] [PATCH v3 1/4] fs: export fs_close()

2019-10-03 Thread AKASHI Takahiro
This function is always paired with either fs_set_blk_desc() or fs_set_blk_desc_with_part(). So just export it. Signed-off-by: AKASHI Takahiro --- fs/fs.c | 2 +- include/fs.h | 7 +++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/fs/fs.c b/fs/fs.c index

[U-Boot] [PATCH v3 0/4] efi_loader: disk: install FILE_SYSTEM_PROTOCOL to whole disk

2019-10-03 Thread AKASHI Takahiro
Changes in v3 (Oct 4, 2019) * add patch#1 * use newly-added fs_get_type() instead fo fs_get_type_name() * check for FS_TYPE_ANY to confirm if a file system exists or not * remove a redundant check on whether a device is a partition or a whole disk Changes in v2 (Sept 12, 2019) * add patch#1 and

Re: [U-Boot] [PATCH v2 03/38] dm: gpio: Allow control of GPIO uclass in SPL

2019-10-03 Thread Bin Meng
Hi Simon, On Thu, Oct 3, 2019 at 10:02 AM Bin Meng wrote: > > On Wed, Oct 2, 2019 at 9:56 PM Bin Meng wrote: > > > > On Wed, Sep 25, 2019 at 10:12 PM Simon Glass wrote: > > > > > > At present if CONFIG_SPL_GPIO_SUPPORT is enabled then the GPIO uclass > > > is included in SPL/TPL without any

Re: [U-Boot] [PATCH v2 4/4] arm: socfpga: Convert clock manager from struct to defines

2019-10-03 Thread Ley Foon Tan
On Wed, Oct 2, 2019 at 5:22 PM Simon Goldschmidt wrote: > > On Tue, Sep 10, 2019 at 10:38 AM Ley Foon Tan wrote: > > > > Convert clock manager for Gen5, Arria 10 and Stratix 10 from struct > > to defines. > > No functional change. > > > > Signed-off-by: Ley Foon Tan > > > > --- > > v2: > > -

[U-Boot] [PATCH v3] cmd: env: extend "env [set|print] -e" to manage UEFI variables

2019-10-03 Thread AKASHI Takahiro
With this patch, when setting UEFI variable with "env set -e" command, we will be able to - specify vendor guid with "-guid guid", - specify variable attributes, BOOTSERVICE_ACCESS, RUNTIME_ACCESS, respectively with "-bs" and "-rt", - append a value instead of overwriting with "-a", - use

[U-Boot] Please pull u-boot-x86

2019-10-03 Thread Bin Meng
Hi Tom, This PR contains the following 2 bug fixes for v2019.10: - dm: core: Correct low cell in ofnode_read_pci_addr() - dm: core: Correct bad cast in ofnode_get_addr_size_index() The following changes since commit ea4316cdb340ce1c05db5d6a869d1840dad68508: Merge tag 'rpi-next-2019.10.2' of

Re: [U-Boot] [PATCH 1/1] Makefile: mrproper should remove *.pyc files

2019-10-03 Thread Bin Meng
On Fri, Oct 4, 2019 at 12:46 AM Heinrich Schuchardt wrote: > > *.pyc files contain compiled Python bytecode. 'make mrproper' should remove > them. > > Removing *.pyc files helps for instance sometimes when running into an > error "binman: Unknown entry type 'blob' in node '/binman/blob'". > >

Re: [U-Boot] [PATCH v2 2/3] efi_loader: disk: install FILE_SYSTEM_PROTOCOL only if available

2019-10-03 Thread AKASHI Takahiro
On Thu, Oct 03, 2019 at 03:44:54PM +0200, Heinrich Schuchardt wrote: > On 10/3/19 9:09 AM, AKASHI Takahiro wrote: > >Heinrich, > > > >On Thu, Sep 12, 2019 at 06:51:35PM +0900, AKASHI Takahiro wrote: > >>On Thu, Sep 12, 2019 at 11:43:07AM +0200, Heinrich Schuchardt wrote: > >>>On 9/12/19 11:17 AM,

Re: [U-Boot] [PATCH v2 2/2] efi_loader: device_path: show a host device in understandable form

2019-10-03 Thread AKASHI Takahiro
On Thu, Oct 03, 2019 at 03:58:48PM +0200, Heinrich Schuchardt wrote: > On 10/3/19 8:56 AM, AKASHI Takahiro wrote: > >Heinrich, > > > >On Fri, Sep 13, 2019 at 09:20:53AM +0900, AKASHI Takahiro wrote: > >>On Thu, Sep 12, 2019 at 11:50:04AM +0200, Heinrich Schuchardt wrote: > >>>On 9/12/19 11:07 AM,

Re: [U-Boot] U-Boot build for i.MX board won't boot in corresponding QEMU machine

2019-10-03 Thread Philippe Mathieu-Daudé
Cc'ing the SABRELITE maintainers: $ ./scripts/get_maintainer.pl -f hw/misc/imx6_ccm.c Peter Maydell (odd fixer:SABRELITE / i.MX6) Jean-Christophe Dubois (reviewer:SABRELITE / i.MX6) qemu-...@nongnu.org (open list:SABRELITE / i.MX6) On 10/3/19 1:54 PM, Bin Meng wrote: +QEMU developers ML On

Re: [U-Boot] [PATCH v2] imx: add Boundary Devices Nitrogen8M board support

2019-10-03 Thread Fabio Estevam
On Thu, Oct 3, 2019 at 4:51 PM Patrick Wildt wrote: > > This adds basic support for the Nitrogen8M board. It's based on > the NXP i.MX8MQ and provides 2GB of memory. This code has been > based on the i.MX8M EVK board support, and Boundary Devices' git > repository. So far the eMMC and onboard

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 9:18 PM, Simon Goldschmidt wrote: > Am 03.10.2019 um 21:12 schrieb Marek Vasut: >> [...] >>> Are you aware that DM WDT is enabled in SPL by default for gen5 >>> now? I >> get >>> a message that WDT is not found. I haven't sent a patch to fix that yet, >>> since

[U-Boot] [PATCH v2] imx: add Boundary Devices Nitrogen8M board support

2019-10-03 Thread Patrick Wildt
This adds basic support for the Nitrogen8M board. It's based on the NXP i.MX8MQ and provides 2GB of memory. This code has been based on the i.MX8M EVK board support, and Boundary Devices' git repository. So far the eMMC and onboard Ethernet can be used to boot, with more device support yet to

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Am 03.10.2019 um 21:12 schrieb Marek Vasut: [...] Are you aware that DM WDT is enabled in SPL by default for gen5 now? I get a message that WDT is not found. I haven't sent a patch to fix that yet, since the message is the only thing that happens, works normally otherwise. But if you're

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
[...] > Are you aware that DM WDT is enabled in SPL by default for gen5 now? I get > a message that WDT is not found. I haven't sent a patch to fix that >> yet, > since the message is the only thing that happens, works normally otherwise. > > But if you're working on

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Marek Vasut schrieb am Do., 3. Okt. 2019, 20:13: > On 10/3/19 8:11 PM, Simon Goldschmidt wrote: > > Marek Vasut schrieb am Do., 3. Okt. 2019, 20:09: > > > >> On 10/3/19 8:06 PM, Simon Goldschmidt wrote: > >>> Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: > >>> > On 10/3/19 3:57 AM, Ley

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 8:11 PM, Simon Goldschmidt wrote: > Marek Vasut schrieb am Do., 3. Okt. 2019, 20:09: > >> On 10/3/19 8:06 PM, Simon Goldschmidt wrote: >>> Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: >>> On 10/3/19 3:57 AM, Ley Foon Tan wrote: [...] >> diff --git

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Marek Vasut schrieb am Do., 3. Okt. 2019, 20:09: > On 10/3/19 8:06 PM, Simon Goldschmidt wrote: > > Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: > > > >> On 10/3/19 3:57 AM, Ley Foon Tan wrote: > >> > >> [...] > >> > diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig >

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 8:08 PM, Simon Goldschmidt wrote: > Marek Vasut schrieb am Do., 3. Okt. 2019, 20:06: > >> On 10/3/19 8:03 PM, Simon Goldschmidt wrote: >>> Marek Vasut schrieb am Do., 3. Okt. 2019, 14:19: >>> On 10/3/19 1:40 PM, Marek Vasut wrote: > On 10/3/19 9:55 AM, Jagan Teki wrote: >>

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 8:06 PM, Simon Goldschmidt wrote: > Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: > >> On 10/3/19 3:57 AM, Ley Foon Tan wrote: >> >> [...] >> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig index 6fd9b0a177..ec34993664 100644 ---

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 8:06 PM, Simon Goldschmidt wrote: > Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: > >> On 10/3/19 3:57 AM, Ley Foon Tan wrote: >> >> [...] >> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig index 6fd9b0a177..ec34993664 100644 ---

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Marek Vasut schrieb am Do., 3. Okt. 2019, 20:06: > On 10/3/19 8:03 PM, Simon Goldschmidt wrote: > > Marek Vasut schrieb am Do., 3. Okt. 2019, 14:19: > > > >> On 10/3/19 1:40 PM, Marek Vasut wrote: > >>> On 10/3/19 9:55 AM, Jagan Teki wrote: > On Thu, Oct 3, 2019 at 4:26 AM Marek Vasut

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Marek Vasut schrieb am Do., 3. Okt. 2019, 09:22: > On 10/3/19 3:57 AM, Ley Foon Tan wrote: > > [...] > > >> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig > >> index 6fd9b0a177..ec34993664 100644 > >> --- a/drivers/watchdog/Kconfig > >> +++ b/drivers/watchdog/Kconfig > >> @@

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Marek Vasut
On 10/3/19 8:03 PM, Simon Goldschmidt wrote: > Marek Vasut schrieb am Do., 3. Okt. 2019, 14:19: > >> On 10/3/19 1:40 PM, Marek Vasut wrote: >>> On 10/3/19 9:55 AM, Jagan Teki wrote: On Thu, Oct 3, 2019 at 4:26 AM Marek Vasut wrote: > > Convert the designware watchdog timer driver to

Re: [U-Boot] [PATCH 2/2] watchdog: designware: Convert to DM and DT probing

2019-10-03 Thread Simon Goldschmidt
Marek Vasut schrieb am Do., 3. Okt. 2019, 14:19: > On 10/3/19 1:40 PM, Marek Vasut wrote: > > On 10/3/19 9:55 AM, Jagan Teki wrote: > >> On Thu, Oct 3, 2019 at 4:26 AM Marek Vasut wrote: > >>> > >>> Convert the designware watchdog timer driver to DM and add DT probing > >>> support. Perform

[U-Boot] [PATCH v5 26/26] mtd: Makefile: deep cleanup

2019-10-03 Thread Miquel Raynal
Move MTD-related lines out of the root Makefile. Put them in their respective directories. Enclose some of these new lines to skip them when building the SPL. MTD core files and some MTD device drivers are compiled in a mtd.o object and included in the final object only if MTD support is required

Re: [U-Boot] [PATCH 1/1] net: remove superfluous __packed attribute

2019-10-03 Thread Heinrich Schuchardt
On 10/3/19 7:09 PM, Tom Rini wrote: On Thu, Oct 03, 2019 at 07:01:22PM +0200, Heinrich Schuchardt wrote: struct ip_udp_hdr is naturally packed. There is no point in adding a __packed attribute. With the attribute the network stack does not compile using GCC 9.2.1: net/net.c: In function

Re: [U-Boot] [PATCH v5 00/26]MTD defconfigs/Kconfigs/Makefiles heavy cleanup

2019-10-03 Thread Miquel Raynal
Hi Miquel, Miquel Raynal wrote on Thu, 3 Oct 2019 19:50:02 +0200: > Hello, > > A year ago, while working on SPI-NAND support in U-Boot, I discovered > when modifying Makefiles a confusing organization where: > * Sub-directories/files are compiled from the root Makefile > * Commands are at the

[U-Boot] [PATCH v5 20/26] dfu: add dependency on the raw NAND core

2019-10-03 Thread Miquel Raynal
CONFIG_DFU_NAND needs the raw NAND core being compiled. Also fix the colibri_vf defconfig to reflect this dependency. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/colibri_vf_defconfig | 1 + drivers/dfu/Kconfig | 1 + 2 files changed, 2 insertions(+) diff

[U-Boot] [PATCH v5 18/26] configs: ls104x/ls108x/ls208x: Build the raw NAND core with TFABOOT

2019-10-03 Thread Miquel Raynal
Enabling TFABOOT configuration will compile-in a call to nand_read in the boot sequence. Handle the situation by also selecting officially the raw NAND core in this case. Signed-off-by: Miquel Raynal --- configs/ls1043aqds_tfa_SECURE_BOOT_defconfig | 1 + configs/ls1043aqds_tfa_defconfig

[U-Boot] [PATCH v5 16/26] configs: remove MTD support from bcm11130 and M54418TWR defconfigs

2019-10-03 Thread Miquel Raynal
While the right Kconfig entries were selected, because of the missing CMD_NAND symbol the raw NAND core was never compiled. Remove it from the defconfigs otherwise the build will fail. Signed-off-by: Miquel Raynal --- configs/M54418TWR_nand_mii_defconfig | 1 -

[U-Boot] [PATCH v5 13/26] mtd: ensure MTD is compiled when CMD_MTDPARTS is selected

2019-10-03 Thread Miquel Raynal
MTD support must be enabled when using mtdparts. Indeed, functions like get_mtd_info(), get_mtd_device() and put_mtd_device() are in drivers/mtd/mtd_uboot.c and are built only with CONFIG_MTD. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon ---

[U-Boot] [PATCH v5 22/26] mtd: spi: SPI_FLASH_MTD depends on MTD

2019-10-03 Thread Miquel Raynal
It is already the case that all defconfigs with SPI_FLASH_MTD also declare using MTD, but let's make this consistent and enforce it in Kconfig. Most of the time SPI_FLASH_MTD is used in conjunction with UBI, which already depends on MTD. Suggested-by: Vignesh R Signed-off-by: Miquel Raynal ---

[U-Boot] [PATCH v5 14/26] configs: move CONFIG_MTD in defconfigs when set in arch includes

2019-10-03 Thread Miquel Raynal
Let's be consistent and always declare CONFIG_MTD from the defconfig file when needed. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/socfpga_stratix10_defconfig | 1 + configs/turris_mox_defconfig | 1 + include/configs/mvebu_armada-37xx.h | 1 -

[U-Boot] [PATCH v5 24/26] cmd: nand/sf: isolate legacy code

2019-10-03 Thread Miquel Raynal
The 'sf' command is not supposed to rely on the MTD stack, but both 'sf' and 'nand' commands use helpers located in mtd_uboot.c. Despite their location, these functions do not depend at all on the MTD stack. This file (drivers/mtd/mtd_uboot.c) is only compiled if CONFIG_MTD is selected, which is

[U-Boot] [PATCH v5 19/26] mtd: nand: add includes in NAND core to avoid warnings

2019-10-03 Thread Miquel Raynal
Because of the include's game, when some files are compiled for a SPI NAND device, no warning appears. But when it is for a raw NAND device, GCC complains. Fix these warning by including . Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- drivers/mtd/nand/bbt.c | 1 +

[U-Boot] [PATCH v5 23/26] cmd: mtdparts: Kconfig: join mtdparts command entry with its options

2019-10-03 Thread Miquel Raynal
Move the Kconfig entry of the option right after the entry of the mtdparts command. Signed-off-by: Miquel Raynal --- cmd/Kconfig | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/cmd/Kconfig b/cmd/Kconfig index bcfbbb4fc6..33adf29a96 100644 ---

[U-Boot] [PATCH v5 25/26] cmd: make MTD commands depend on MTD

2019-10-03 Thread Miquel Raynal
Defconfigs have been fixed, now we can add proper dependencies in Kconfig. SPI FLASH is still not dependent on MTD (deeper rework needed). Signed-off-by: Miquel Raynal --- cmd/Kconfig | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/cmd/Kconfig b/cmd/Kconfig index

[U-Boot] [PATCH v5 17/26] configs: socfpga: mcvevk: Remove useless UBI infos

2019-10-03 Thread Miquel Raynal
There is no flash on this board, there is no reason to define MTD environment variables nor UBI. Drop them from the configuration file. Signed-off-by: Miquel Raynal --- configs/socfpga_mcvevk_defconfig | 3 --- 1 file changed, 3 deletions(-) diff --git a/configs/socfpga_mcvevk_defconfig

[U-Boot] [PATCH v5 15/26] configs: remove raw NAND core from k2g defconfigs

2019-10-03 Thread Miquel Raynal
Due to previous Makefile organization, the raw NAND subdirectory was not compiled in if CMD_NAND was not enabled. Because the Denali driver does not compile with these boards (undefined environment offset), remove the dependency within the defconfig over the controller driver (was ignored anyway

[U-Boot] [PATCH v5 21/26] mtd: nor: NOR flashes depend on MTD

2019-10-03 Thread Miquel Raynal
A NOR flash needs the MTD core, ensure this dependency is met by adding a "depends on" in Kconfig. This is fine since defconfigs have been fixed. Signed-off-by: Miquel Raynal --- drivers/mtd/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig

[U-Boot] [PATCH v5 12/26] mtd: ensure CMD_NAND is compiled when its options are selected

2019-10-03 Thread Miquel Raynal
In some files, options of CMD_NAND are selected but not the command itself. Fix this inconsistency. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/apf27_defconfig | 1 + configs/aristainetos2_defconfig | 1 +

[U-Boot] [PATCH v5 10/26] mtd: ensure UBI is compiled when ENV_IS_IN_UBI is selected

2019-10-03 Thread Miquel Raynal
UBI must be enabled when the environment is in UBI. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/CHIP_pro_defconfig | 2 ++ env/Kconfig| 2 ++ 2 files changed, 4 insertions(+) diff --git a/configs/CHIP_pro_defconfig b/configs/CHIP_pro_defconfig index

[U-Boot] [PATCH v5 11/26] mtd: ensure MTD_RAW_NAND is compiled when ENV_IS_IN_NAND is selected

2019-10-03 Thread Miquel Raynal
Raw NAND support must be enabled when the environment is in NAND. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/bk4r1_defconfig | 1 + configs/harmony_defconfig | 1 + 2 files changed, 2 insertions(+) diff --git a/configs/bk4r1_defconfig b/configs/bk4r1_defconfig

[U-Boot] [PATCH v5 09/26] mtd: ensure UBI is compiled when CMD_UBI is selected

2019-10-03 Thread Miquel Raynal
UBI must be enabled when CMD_UBI is used, this is mandatory and will later be reflected thanks to a "depends on" in Kconfig. But first, defconfigs needs to be fixed. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/am335x_baltos_defconfig| 1 +

[U-Boot] [PATCH v5 07/26] mtd: ensure UBI is compiled when using fastmap

2019-10-03 Thread Miquel Raynal
UBI must be enabled when using fastmap, reflect this is defconfigs. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/am335x_igep003x_defconfig | 1 + configs/aristainetos2_defconfig | 1 + configs/aristainetos2b_defconfig | 1 +

[U-Boot] [PATCH v5 08/26] mtd: ensure MTD is compiled when UBI is used

2019-10-03 Thread Miquel Raynal
MTD must be enabled when UBI is used, this is mandatory and will later be reflected thanks to a "depends on" in Kconfig. But first, defconfigs need to be fixed. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/gardena-smart-gateway-mt7688-ram_defconfig | 1 +

[U-Boot] [PATCH v5 06/26] mtd: ensure MTD is compiled when there is a SPI NOR flash using MTD

2019-10-03 Thread Miquel Raynal
MTD must be enabled when there is a SPI NOR flash using the SPI_FLASH_MTD config entry. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/ap121_defconfig | 1 + configs/ap143_defconfig | 1 + configs/bk4r1_defconfig | 1 +

[U-Boot] [PATCH v5 05/26] mtd: ensure MTD/the raw NAND core are compiled when there is a NAND flash

2019-10-03 Thread Miquel Raynal
Both symbols must be enabled when there is a raw NAND driver selected. Also enable them when CONFIG_CMD_NAND is selected to avoid breaking things when we'll further rework the MTD dependency description. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon ---

[U-Boot] [PATCH v5 03/26] mtd: rename CONFIG_MTD_DEVICE -> CONFIG_MTD

2019-10-03 Thread Miquel Raynal
Like in Linux, just use CONFIG_MTD to compile the MTD stack. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- cmd/Kconfig | 2 +- configs/10m50_defconfig | 2 +- configs/TQM834x_defconfig| 2

[U-Boot] [PATCH v5 02/26] mtd: rename CONFIG_MTD -> CONFIG_DM_MTD

2019-10-03 Thread Miquel Raynal
CONFIG_MTD must be reserved for the MTD core. Like any other subsystem, prefix the symbol by DM when it comes to DM support. Signed-off-by: Miquel Raynal Reviewed-by: Boris Brezillon --- configs/10m50_defconfig| 2 +- configs/3c120_defconfig

[U-Boot] [PATCH v5 00/26]MTD defconfigs/Kconfigs/Makefiles heavy cleanup

2019-10-03 Thread Miquel Raynal
Hello, A year ago, while working on SPI-NAND support in U-Boot, I discovered when modifying Makefiles a confusing organization where: * Sub-directories/files are compiled from the root Makefile * Commands are at the root of everything First I sent a series to move Makefile entries in their

Re: [U-Boot] [PATCH 1/1] net: remove superfluous __packed attribute

2019-10-03 Thread Tom Rini
On Thu, Oct 03, 2019 at 07:01:22PM +0200, Heinrich Schuchardt wrote: > struct ip_udp_hdr is naturally packed. There is no point in adding a > __packed attribute. With the attribute the network stack does not compile > using GCC 9.2.1: > > net/net.c: In function ‘net_process_received_packet’: >

[U-Boot] [PATCH 1/1] net: remove superfluous __packed attribute

2019-10-03 Thread Heinrich Schuchardt
struct ip_udp_hdr is naturally packed. There is no point in adding a __packed attribute. With the attribute the network stack does not compile using GCC 9.2.1: net/net.c: In function ‘net_process_received_packet’: net/net.c:1288:23: error: taking address of packed member of ‘struct ip_udp_hdr’

[U-Boot] [PATCH 1/1] Makefile: mrproper should remove *.pyc files

2019-10-03 Thread Heinrich Schuchardt
*.pyc files contain compiled Python bytecode. 'make mrproper' should remove them. Removing *.pyc files helps for instance sometimes when running into an error "binman: Unknown entry type 'blob' in node '/binman/blob'". Signed-off-by: Heinrich Schuchardt --- Makefile | 2 +- 1 file changed, 1

[U-Boot] [PATCH] MAINTAINERS: Update my email address

2019-10-03 Thread Maxime Ripard
I'm not at bootlin anymore, and my mail address doesn't work any longer. Signed-off-by: Maxime Ripard --- MAINTAINERS | 2 +- board/sunxi/MAINTAINERS | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index e752e4b3de0f..9193f7ccf212

[U-Boot] [BUG] arch/arm/cpu/armv7/sunxi/psci.c does not build with GCC 9.2.1

2019-10-03 Thread Heinrich Schuchardt
Building orangepi_pc_defconfig with GCC 9.2.1 (Debian Bullseye) fails: arch/arm/cpu/armv7/sunxi/psci.c: In function ‘sunxi_cpu_set_power’: arch/arm/cpu/armv7/sunxi/psci.c:163:21: error: taking address of packed member of ‘struct sunxi_prcm_reg’ may result in an unaligned pointer value

[U-Boot] Bootcount on raspberry pi 0 w

2019-10-03 Thread Thomas Mahringer
Hello We are using yocto + swupdate and u-boot do deliver software updates for our hardware which is based on a raspberry pi zero w. So far everything seems to be working, however I would like to use u-boot's bootcount feature to switch back to the previous version in case an upgrade fails

[U-Boot] [BUGS] fs/cbfs/cbfs.c and net/net.c do not compile with GCC 9.2.1

2019-10-03 Thread Heinrich Schuchardt
Compiling fs/cbfs/cbfs.c and net/net.c fails for sandbox_defconfig using GCC 9.2.1 (Debian Bullseye): CC fs/cbfs/cbfs.o fs/cbfs/cbfs.c: In function ‘file_cbfs_fill_cache’: fs/cbfs/cbfs.c:164:16: error: taking address of packed member of ‘struct cbfs_cachenode’ may result in an unaligned

[U-Boot] [PATCH v3 2/2] efi: device path for nvme

2019-10-03 Thread Patrick Wildt
This allows our EFI API to create a device path node for NVMe devices. It adds the necessary device path struct, uses the nvme namespace accessor to retrieve the id and eui64, and also provides support for the device path text protocol. Signed-off-by: Patrick Wildt --- include/efi_api.h

Re: [U-Boot] [PATCH] linux_compat: fix potential NULL pointer access

2019-10-03 Thread Ralph Siemsen
On Wed, Oct 02, 2019 at 02:37:20PM +0200, Marek Szyprowski wrote: malloc_cache_aligned() might return zero, so fix potential NULL pointer access if __GFP_ZERO flag is set. Signed-off-by: Marek Szyprowski Reviewed-by: Ralph Siemsen This looks reasonable to me. The memset() will happily

[U-Boot] [PATCH 3/3] imx: enable the reset controller on the i.MX8MQ EVK

2019-10-03 Thread Patrick Wildt
This patch makes sure that the reset controller driver is compiled for the i.MX8MQ EVK. Signed-off-by: Patrick Wildt --- configs/imx8mq_evk_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/imx8mq_evk_defconfig b/configs/imx8mq_evk_defconfig index e45731edda..c0e5860e85

[U-Boot] [PATCH 2/3] imx: add the i.MX8M reset controller node

2019-10-03 Thread Patrick Wildt
This patch adds the reset controller node to the i.MX8MQ SoC device tree. Signed-off-by: Patrick Wildt --- arch/arm/dts/fsl-imx8mq.dtsi | 7 +++ 1 file changed, 7 insertions(+) diff --git a/arch/arm/dts/fsl-imx8mq.dtsi b/arch/arm/dts/fsl-imx8mq.dtsi index c35c23e293..d843b401be 100644 ---

[U-Boot] [PATCH 1/3] imx: add support for i.MX7/i.MX8MQ reset controller

2019-10-03 Thread Patrick Wildt
Add support for the reset controller that's used on the i.MX7D and i.MX8MQ. This will be needed to be able to assert the PCIe reset pins. Bindings taken from Linux, driver implementation mostly taken from Linux and adjusted to U-Boot infrastructure. Signed-off-by: Patrick Wildt ---

Re: [U-Boot] [PATCH] imx: add support for i.MX7/i.MX8MQ reset controller

2019-10-03 Thread Fabio Estevam
Hi Patrick, On Thu, Oct 3, 2019 at 10:50 AM Patrick Wildt wrote: > > Add support for the reset controller that's used on the i.MX7D > and i.MX8MQ. This will be needed to be able to assert the PCIe > reset pins. Bindings taken from Linux, driver implementation > mostly taken from Linux and

Re: [U-Boot] [PATCH v2 2/2] efi_loader: device_path: show a host device in understandable form

2019-10-03 Thread Heinrich Schuchardt
On 10/3/19 8:56 AM, AKASHI Takahiro wrote: Heinrich, On Fri, Sep 13, 2019 at 09:20:53AM +0900, AKASHI Takahiro wrote: On Thu, Sep 12, 2019 at 11:50:04AM +0200, Heinrich Schuchardt wrote: On 9/12/19 11:07 AM, AKASHI Takahiro wrote: On Thu, Sep 12, 2019 at 09:59:01AM +0200, Heinrich Schuchardt

[U-Boot] [PATCH] imx: add support for i.MX8MQ power domain controller

2019-10-03 Thread Patrick Wildt
Add support for the power domain controller that's used on the i.MX8MQ. This will be needed to be able to power on the PCIe controller. Bindings taken from Linux, driver implementation taken from the i.MX8 power domain controller and adjusted for the i.MX8M SoC. Signed-off-by: Patrick Wildt

[U-Boot] [PATCH] imx: add support for i.MX7/i.MX8MQ reset controller

2019-10-03 Thread Patrick Wildt
Add support for the reset controller that's used on the i.MX7D and i.MX8MQ. This will be needed to be able to assert the PCIe reset pins. Bindings taken from Linux, driver implementation mostly taken from Linux and adjusted to U-Boot infrastructure. Signed-off-by: Patrick Wildt diff --git

[U-Boot] [PATCH] imx: update i.MX8MQ clocks

2019-10-03 Thread Patrick Wildt
I would like to add support for additional drivers, and for that it makes sense to update the clock headers first, before adding a node to the device tree. Since no drivers use them so far it's easy to just update the header and adjust the device tree. Signed-off-by: Patrick Wildt diff --git

Re: [U-Boot] [PATCH v2 2/3] efi_loader: disk: install FILE_SYSTEM_PROTOCOL only if available

2019-10-03 Thread Heinrich Schuchardt
On 10/3/19 9:09 AM, AKASHI Takahiro wrote: Heinrich, On Thu, Sep 12, 2019 at 06:51:35PM +0900, AKASHI Takahiro wrote: On Thu, Sep 12, 2019 at 11:43:07AM +0200, Heinrich Schuchardt wrote: On 9/12/19 11:17 AM, AKASHI Takahiro wrote: On Thu, Sep 12, 2019 at 10:57:20AM +0200, Heinrich Schuchardt

Re: [U-Boot] HAB synchronous error loop i.MX8M

2019-10-03 Thread Patrick Wildt
Since I'm not booting Linux I don't know if it will help you. :( Best regards, Patrick On Thu, Oct 03, 2019 at 03:39:34PM +0200, Bartlomiej wrote: > Hello Patrick, > > On a first glance it looks very similar to the Variscite's implementation > for i.MX8M HAB, which actually seems to work for

Re: [U-Boot] [PATCH] imx: add Boundary Devices Nitrogen8M board support

2019-10-03 Thread Patrick Wildt
On Thu, Oct 03, 2019 at 10:27:12AM -0300, Fabio Estevam wrote: > Hi Patrick, > > [Adding Troy, NXP U-Boot folks and Stefano] > > Thanks for your contribution. Thanks for looking at it! > On Tue, Oct 1, 2019 at 4:15 PM Patrick Wildt wrote: > > > > This adds basic support for the Nitrogen8M

Re: [U-Boot] HAB synchronous error loop i.MX8M

2019-10-03 Thread Bartlomiej
Hello Patrick, On a first glance it looks very similar to the Variscite's implementation for i.MX8M HAB, which actually seems to work for authenticating the bootloader image, but on the other hand fails on the kernel image on `hab_rvt_check_target` with the check target SMC returning -1

Re: [U-Boot] [RFC 2/3] lib: rsa: generate additional parameters for public key

2019-10-03 Thread Heinrich Schuchardt
On 10/3/19 10:58 AM, AKASHI Takahiro wrote: Ilias, On Thu, Oct 03, 2019 at 10:34:33AM +0300, Ilias Apalodimas wrote: On Fri, Sep 06, 2019 at 04:08:07PM +0900, AKASHI Takahiro wrote: In the current implementation of FIT_SIGNATURE, five parameters for a RSA public key are required while only

Re: [U-Boot] [PATCH 2/2] efi: device path for nvme

2019-10-03 Thread Patrick Wildt
On Thu, Oct 03, 2019 at 03:12:45PM +0200, Heinrich Schuchardt wrote: > On 10/3/19 1:02 PM, Patrick Wildt wrote: > > This allows our EFI API to create a device path node for NVMe > > devices. It adds the necessary device path struct, uses the > > nvme namespace accessor to retrieve the id and

Re: [U-Boot] HAB synchronous error loop i.MX8M

2019-10-03 Thread Patrick Wildt
On Thu, Oct 03, 2019 at 10:13:19AM -0300, Fabio Estevam wrote: > Hi Patrick, > > On Thu, Oct 3, 2019 at 10:01 AM Patrick Wildt wrote: > > > Boundary Devices U-Boot is about a year old, and I haven't checked how > > they implemented it. I have a diff for i.MX8M HAB support which works > > for

Re: [U-Boot] [PATCH] imx: add Boundary Devices Nitrogen8M board support

2019-10-03 Thread Fabio Estevam
Hi Patrick, [Adding Troy, NXP U-Boot folks and Stefano] Thanks for your contribution. On Tue, Oct 1, 2019 at 4:15 PM Patrick Wildt wrote: > > This adds basic support for the Nitrogen8M board. It's based on > the NXP i.MX8MQ and provides 2GB of memory. This code has been > based on the i.MX8M

Re: [U-Boot] [PATCH v4 1/3] env: correct the check of env_flags_validate presence

2019-10-03 Thread Tom Rini
On Thu, Oct 03, 2019 at 09:24:26AM +0200, Patrick Delaunay wrote: > This patch corrects the check of env_flags_validate presence because > "flags.c" is always compiled in U-Boot and CONFIG_ENV_SUPPORT > don't exist; so the macro CONFIG_IS_ENABLED(ENV_SUPPORT) only provides > the expected result

Re: [U-Boot] [PATCH 006/126] dm: core: Correct bad cast in ofnode_get_addr_size_index()

2019-10-03 Thread Bin Meng
On Thu, Oct 3, 2019 at 8:48 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:58 PM Simon Glass wrote: > > > > At present this code passes an fdt_addr_t pointer as a u64 pointer which > > is not save, since sizeof(fdt_addr_t) may be 4, e.g. with sandbox. Correct > > not safe Fixed this typo,

Re: [U-Boot] [PATCH 002/126] dm: core: Correct low cell in ofnode_read_pci_addr()

2019-10-03 Thread Bin Meng
On Thu, Oct 3, 2019 at 8:47 PM Bin Meng wrote: > > On Wed, Sep 25, 2019 at 10:58 PM Simon Glass wrote: > > > > This reads the low cell of the PCI address from the wrong cell. Fix it. > > Also fix the function that this code came from. > > > > Fixes: 9e51204527 (dm: core: Add operations on device

Re: [U-Boot] [PATCH 2/2] efi: device path for nvme

2019-10-03 Thread Heinrich Schuchardt
On 10/3/19 1:02 PM, Patrick Wildt wrote: This allows our EFI API to create a device path node for NVMe devices. It adds the necessary device path struct, uses the nvme namespace accessor to retrieve the id and eui64, and also provides support for the device path text protocol. Signed-off-by:

  1   2   >