Re: [U-Boot] [PATCH 18/25] tpm: Convert to use a device parameter

2018-11-06 Thread Miquel Raynal
Hi Simon, Simon Glass wrote on Tue, 6 Nov 2018 15:21:35 -0700: > At present many TPM calls assume there is only one TPM in the system and > look up this TPM themselves. This is inconsistent with driver model, which > expects all driver methods to have a device parameter. Update the code to >

Re: [U-Boot] [PATCH 17/25] tpm: Export the open/close functions

2018-11-06 Thread Miquel Raynal
Hi Simon, Simon Glass wrote on Tue, 6 Nov 2018 15:21:34 -0700: > At present these functions are not accessible outside the TPM library, but > in some cases we need to call them. I was not aware, what is the use case? I don't get it. > Export them in the header file and add > a define for the

Re: [U-Boot] [PATCH v1] fs: ubifs: Fix UBIFS decompression on 64 bit

2018-11-06 Thread Heiko Schocher
Hello Paul, Am 05.11.2018 um 06:09 schrieb Paul Davey: Add local size_t variable to crypto_comp_decompress as intermediate storage for destination length to avoid memory corruption and incorrect results on 64 bit targets. This is what linux does for the various lz compression implementations.

[U-Boot] [PATCH v2 2/2] arm64: mvebu: a8k: autodetect RAM size

2018-11-06 Thread Baruch Siach
Some Armada 8K boards like Macchiatobin and Clearfog GT-8K use RAM from external DIMM. Hard coding the RAM size in the device-tree is not convenient. Fortunately, the ATF that initializes the RAM knows the size of RAM, and U-Boot can query the ATF using a SMC call. The ATF maps the lower 3G of

[U-Boot] [PATCH v2 1/2] linux/sizes.h: sync from kernel

2018-11-06 Thread Baruch Siach
The kernel added SZ_4G macro in commit f2b9ba871b (arm64/kernel: kaslr: reduce module randomization range to 4 GB). Include common.h for _AC() instead of the kernel linux/const.h header. Drop a local SZ_4G definition in tegra code. Cc: Tom Warren Signed-off-by: Baruch Siach --- v2: No change

Re: [U-Boot] [PATCH 2/2] efi_loader: enumerate disk devices every time

2018-11-06 Thread Heinrich Schuchardt
On 11/7/18 1:44 AM, AKASHI Takahiro wrote: > Currently, efi_init_obj_list() scan disk devices only once, and never > change a list of efi disk devices. This will possibly result in failing > to find a removable storage which may be added later on. See [1]. > > In this patch, called is

Re: [U-Boot] [PATCH 25/25] mmc: Add hardware partition support

2018-11-06 Thread Faiz Abbas
Hi Simon, On Wednesday 07 November 2018 03:51 AM, Simon Glass wrote: > MMC devices support multiple partitions, defined by the hardware. At > present U-Boot can only access partition zero. Add support for selecting > other partitions. > There is already support to switch to another hardware

Re: [U-Boot] [PATCH v6 34/34] imx: add i.MX8QXP MEK board support

2018-11-06 Thread Jon Nettleton
I have been spending some time on this, at least from the lpddr4 side. There is a good amount of this that can be abstracted out and made into general initialization routines. This is all well and good and you can see that Boundary Devices has already codified some of these values here.

Re: [U-Boot] [PATCH 12/25] spl: Correct malloc debugging in board_init_r()

2018-11-06 Thread Simon Goldschmidt
On Tue, Nov 6, 2018 at 11:22 PM Simon Glass wrote: > > SPL does not support %#x in printf() strings so we must write out the 0x > explicitly. Update the code for this. > > Signed-off-by: Simon Glass This has already been covered by my patch here: https://patchwork.ozlabs.org/patch/992555/

Re: [U-Boot] [PATCH] serial: ns16550: add setconfig support

2018-11-06 Thread Hannes Schmelzer
> Betreff: [PATCH] serial: ns16550: add setconfig support > > Add possibility to update the serial parity used. > > Signed-off-by: Simon Goldschmidt > --- > > drivers/serial/ns16550.c | 43 ++-- > 1 file changed, 41 insertions(+), 2 deletions(-)

Re: [U-Boot] [PATCH u-boot] spi: Add Amlogic Meson SPI Flash Controller driver

2018-11-06 Thread jbrunet
On Tue, 2018-11-06 at 10:25 +0100, Neil Armstrong wrote: > The Amlogic Meson SoCs embeds a Flash oriented SPI Controller name SPIFC. > This driver, ported from the Linux meson-spi-spifc driver, add support > for this controller on the Amlogic Meson GX SoCs in U-Boot. > > Signed-off-by: Neil

[U-Boot] [PATCH 00/25] sandbox: Changes and improvements to support verified boot

2018-11-06 Thread Simon Glass
This series compiles a number of fixes and improvement to sandbox, cros_ec, tpm and a few other pieces. This allows U-Boot to support Chromium OS verified boot and assist with debugging of this. Simon Glass (25): cros_ec: Use uint instead of u8 for parameters cros_ec: Add error logging on a

Re: [U-Boot] [PATCH 1/3] sunxi-mmc: introduce new MMC_SUNXI_HAS_NEW_MODE_SWITCH option

2018-11-06 Thread Chen-Yu Tsai
On Wed, Nov 7, 2018 at 12:21 PM Vasily Khoruzhick wrote: > > On Tue, Nov 6, 2018 at 8:13 PM Chen-Yu Tsai wrote: > > > > On Wed, Nov 7, 2018 at 11:59 AM Vasily Khoruzhick > > wrote: > > > > > > A64 doesn't have a mode switch in CCM, so introduce new > > > MMC_SUNXI_HAS_NEW_MODE_SWITCH option to

Re: [U-Boot] [PATCH 1/3] sunxi-mmc: introduce new MMC_SUNXI_HAS_NEW_MODE_SWITCH option

2018-11-06 Thread Vasily Khoruzhick
On Tue, Nov 6, 2018 at 8:13 PM Chen-Yu Tsai wrote: > > On Wed, Nov 7, 2018 at 11:59 AM Vasily Khoruzhick wrote: > > > > A64 doesn't have a mode switch in CCM, so introduce new > > MMC_SUNXI_HAS_NEW_MODE_SWITCH option to support new clock mode on A64 > > > > Signed-off-by: Vasily Khoruzhick > >

Re: [U-Boot] [PATCH 3/3] sunxi-mmc: use new mode on both controllers on A64

2018-11-06 Thread Chen-Yu Tsai
On Wed, Nov 7, 2018 at 11:59 AM Vasily Khoruzhick wrote: > > Using new mode improves stability of eMMC and SD cards. Without > it SPl fails to load u-boot from SD on Pinebook. > > Signed-off-by: Vasily Khoruzhick > Tested-by: Zhaofeng Li Reviewed-by: Chen-Yu Tsai

Re: [U-Boot] [PATCH 2/3] sunxi-mmc: don't double clock for new mode unconditionally

2018-11-06 Thread Chen-Yu Tsai
On Wed, Nov 7, 2018 at 11:59 AM Vasily Khoruzhick wrote: > > Comment in Linux driver says that clock needs to be doubled only > if we use DDR modes, moreover divider has to be set accordingly. > > U-boot driver doesn't declare support for any DDR modes and doesn't > set divider, so it doubles

Re: [U-Boot] [PATCH 1/3] sunxi-mmc: introduce new MMC_SUNXI_HAS_NEW_MODE_SWITCH option

2018-11-06 Thread Chen-Yu Tsai
On Wed, Nov 7, 2018 at 11:59 AM Vasily Khoruzhick wrote: > > A64 doesn't have a mode switch in CCM, so introduce new > MMC_SUNXI_HAS_NEW_MODE_SWITCH option to support new clock mode on A64 > > Signed-off-by: Vasily Khoruzhick > Tested-by: Zhaofeng Li This patch isn't strictly necessary. See

[U-Boot] [PATCH 3/3] sunxi-mmc: use new mode on both controllers on A64

2018-11-06 Thread Vasily Khoruzhick
Using new mode improves stability of eMMC and SD cards. Without it SPl fails to load u-boot from SD on Pinebook. Signed-off-by: Vasily Khoruzhick Tested-by: Zhaofeng Li --- arch/arm/mach-sunxi/Kconfig | 1 + drivers/mmc/sunxi_mmc.c | 10 +++--- 2 files changed, 8 insertions(+), 3

[U-Boot] [PATCH 1/3] sunxi-mmc: introduce new MMC_SUNXI_HAS_NEW_MODE_SWITCH option

2018-11-06 Thread Vasily Khoruzhick
A64 doesn't have a mode switch in CCM, so introduce new MMC_SUNXI_HAS_NEW_MODE_SWITCH option to support new clock mode on A64 Signed-off-by: Vasily Khoruzhick Tested-by: Zhaofeng Li --- arch/arm/mach-sunxi/Kconfig | 1 + drivers/mmc/Kconfig | 4 drivers/mmc/sunxi_mmc.c | 2 ++

[U-Boot] [PATCH 2/3] sunxi-mmc: don't double clock for new mode unconditionally

2018-11-06 Thread Vasily Khoruzhick
Comment in Linux driver says that clock needs to be doubled only if we use DDR modes, moreover divider has to be set accordingly. U-boot driver doesn't declare support for any DDR modes and doesn't set divider, so it doubles clock unconditionally when new mode is used. Some cards can't handle

[U-Boot] [PATCH 0/3] sunxi-mmc: enable new clock mode on A64

2018-11-06 Thread Vasily Khoruzhick
A64 requires new clock mode on SD and eMMC controllers. Not using new clock mode causes stability issues of the driver - SPL may occasionally fail to load u-boot from SD for some particular SD card on some particular devices. This series depends on "sunxi: add support for automatic delay

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Tom Rini
On Tue, Nov 06, 2018 at 07:42:39PM -0700, Simon Glass wrote: > Hi Bin, > > On 6 November 2018 at 19:29, Bin Meng wrote: > > Hi Simon, > > > > On Wed, Nov 7, 2018 at 10:25 AM Simon Glass wrote: > >> > >> Hi Bin, > >> > >> On 6 November 2018 at 19:22, Bin Meng wrote: > >> > > >> > Hi Simon, > >>

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Simon Glass
Hi Bin, On 6 November 2018 at 19:29, Bin Meng wrote: > Hi Simon, > > On Wed, Nov 7, 2018 at 10:25 AM Simon Glass wrote: >> >> Hi Bin, >> >> On 6 November 2018 at 19:22, Bin Meng wrote: >> > >> > Hi Simon, >> > >> > On Wed, Nov 7, 2018 at 10:07 AM Simon Glass wrote: >> > > >> > > Hi Bin, >> >

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Bin Meng
Hi Simon, On Wed, Nov 7, 2018 at 10:25 AM Simon Glass wrote: > > Hi Bin, > > On 6 November 2018 at 19:22, Bin Meng wrote: > > > > Hi Simon, > > > > On Wed, Nov 7, 2018 at 10:07 AM Simon Glass wrote: > > > > > > Hi Bin, > > > > > > On 6 November 2018 at 18:04, Bin Meng wrote: > > > > > > > >

Re: [U-Boot] [PATCH 09/25] sandbox: cros_ec: exynos: Drop use of cros_ec_get_error()

2018-11-06 Thread Minkyu Kang
On 07/11/18 07:21, Simon Glass wrote: > This function is really just a call to uclass_get_device() and there is no > reason why the caller cannot do it. Update sandbox and snow accordingly. > > Signed-off-by: Simon Glass > --- > > board/samsung/common/board.c | 10 ++ >

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Simon Glass
Hi Bin, On 6 November 2018 at 19:22, Bin Meng wrote: > > Hi Simon, > > On Wed, Nov 7, 2018 at 10:07 AM Simon Glass wrote: > > > > Hi Bin, > > > > On 6 November 2018 at 18:04, Bin Meng wrote: > > > > > > Hi Simon, > > > > > > On Wed, Nov 7, 2018 at 5:51 AM Simon Glass wrote: > > > > > > > > Hi

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Bin Meng
Hi Simon, On Wed, Nov 7, 2018 at 10:07 AM Simon Glass wrote: > > Hi Bin, > > On 6 November 2018 at 18:04, Bin Meng wrote: > > > > Hi Simon, > > > > On Wed, Nov 7, 2018 at 5:51 AM Simon Glass wrote: > > > > > > Hi Tom, > > > > > > The following changes since commit > > >

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Simon Glass
Hi Bin, On 6 November 2018 at 18:04, Bin Meng wrote: > > Hi Simon, > > On Wed, Nov 7, 2018 at 5:51 AM Simon Glass wrote: > > > > Hi Tom, > > > > The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: > > > > Merge branch 'master' of git://git.denx.de/u-boot-sh

[U-Boot] [PATCH v3] riscv: cache: Implement i/dcache [status, enable, disable]

2018-11-06 Thread Andes
From: Rick Chen AndeStar RISC-V(V5) provide mcache_ctl register which can configure I/D cache as enabled or disabled. This CSR will be encapsulated by CONFIG_RISCV_NDS. If you want to configure cache on AndeStar V5 AE350 platform. YOu can enable [*] AndeStar V5 ISA support by make menuconfig.

Re: [U-Boot] Please pull u-boot-dm

2018-11-06 Thread Bin Meng
Hi Simon, On Wed, Nov 7, 2018 at 5:51 AM Simon Glass wrote: > > Hi Tom, > > The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: > > Merge branch 'master' of git://git.denx.de/u-boot-sh (2018-11-04 08:12:21 > -0500) > > are available in the Git repository at: > >

[U-Boot] [PATCH 2/2] efi_loader: enumerate disk devices every time

2018-11-06 Thread AKASHI Takahiro
Currently, efi_init_obj_list() scan disk devices only once, and never change a list of efi disk devices. This will possibly result in failing to find a removable storage which may be added later on. See [1]. In this patch, called is efi_disk_update() which is responsible for re-scanning

[U-Boot] [PATCH 1/2] efi_loader: export efi_locate_handle() function

2018-11-06 Thread AKASHI Takahiro
This function will be used later to implement efi_disk_update(). Signed-off-by: AKASHI Takahiro --- include/efi_loader.h | 4 lib/efi_loader/efi_boottime.c | 7 +++ 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/include/efi_loader.h b/include/efi_loader.h index

[U-Boot] [PATCH 1/4] buildman: Only print toolchain probing with -v

2018-11-06 Thread Simon Glass
At present --list-tool-chains prints a lot of information about the toolchain-probing process. This is generally not very interesting. Update buildman to print this only if --list-tool-chains is given with -v. Signed-off-by: Simon Glass --- tools/buildman/cmdline.py | 2 +-

[U-Boot] [PATCH 4/4] buildman: Show boards with warning with w+

2018-11-06 Thread Simon Glass
At present we should boards with warnings in the same way as those with errors. This is not ideal. Add a new 'warn' state and show these listed in yellow to match the actual warning lines printing with -e. Signed-off-by: Simon Glass --- tools/buildman/builder.py | 17 +---

[U-Boot] [PATCH 3/4] buildman: Rename the good, better, worse variables

2018-11-06 Thread Simon Glass
At present we don't distinguish between errors and warnings when printing the architecture summary. Rename the variables to better describe their purpose. 'Worse' at present means we got an error, so use that as the name. Signed-off-by: Simon Glass --- tools/buildman/builder.py | 28

[U-Boot] [PATCH 2/4] buildman: Detect dtc warnings

2018-11-06 Thread Simon Glass
At present messages from the device-tree compiler like this: arch/arm/dts/socfpga_arria10_socdk_sdmmc.dtb: Warning (avoid_unnecessary_addr_size): /clocks: unnecessary #address-cells/#size-cells without "ranges" or child "reg" property are detected as errors since they don't match the

[U-Boot] [PATCH v12 5/6] efi: Create a function to set up for running EFI code

2018-11-06 Thread Simon Glass
There is still duplicated code in efi_loader for tests and normal operation. Add a new bootefi_run_prepare() function which holds common code used to set up U-Boot to run EFI code. Make use of this from the existing bootefi_test_prepare() function, as well as do_bootefi_exec(). Also shorten a

[U-Boot] [PATCH v12 4/6] efi: Split out test init/uninit into functions

2018-11-06 Thread Simon Glass
The functions in bootefi are very long because they mix high-level code and control with the low-level implementation. To help with this, create functions which handle preparing for running the test and cleaning up afterwards. Also shorten the awfully long variable names here. Signed-off-by:

[U-Boot] [PATCH v12 6/6] efi: Rename bootefi_test_finish() to bootefi_run_finish()

2018-11-06 Thread Simon Glass
This function can be used from do_bootefi_exec() so that we use mostly the same code for a normal EFI application and an EFI test. Rename the function and use it in both places. Signed-off-by: Simon Glass --- Changes in v12: None Changes in v11: - Drop patches previously applied Changes in

[U-Boot] [PATCH v12 2/6] efi_loader: Drop setup_ok

2018-11-06 Thread Simon Glass
This value is stored in data which appears to be read-only with sandbox on my Ubuntu 18.04 machine. In any case it is not good practice to store run-time data in a build-time linker list. The value does not seem to be that useful, since tests that fail to setup are likely to fail to run also.

[U-Boot] [PATCH v12 3/6] sandbox: smbios: Update to support sandbox

2018-11-06 Thread Simon Glass
At present this code casts addresses to pointers so cannot be used with sandbox. Update it to use mapmem instead. Signed-off-by: Simon Glass --- Changes in v12: None Changes in v11: - Fix the EFI code that has since been added and relies on broken behaviour Changes in v9: None Changes in v7:

[U-Boot] [PATCH v12 1/6] sandbox: Put CPUs under a cpu-bus node

2018-11-06 Thread Simon Glass
The CPU uclass expects that all CPUs have a parent device which is a cpu-bus. Fix up the sandbox test DT to follow this convention. This allow the code in smbios_write_type4_dm() to work, since it calls dev_get_parent_platdata() on each CPU. Signed-off-by: Simon Glass --- Changes in v12: -

[U-Boot] [PATCH v12 0/6] efi_loader: Code refactoring and improvement

2018-11-06 Thread Simon Glass
This collects the patches previously sent to break up the very large functions in efi_loader into smaller pieces. Now that the other sandbox stuff is applied, perhaps it is time to apply these patches. This also adds a few new patches to fix more recent breakages. Unfortunately we still cannot

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

2018-11-06 Thread Tom Rini
On Tue, Nov 06, 2018 at 01:38:07PM +0800, Bin Meng wrote: > Hi Tom, > > This contains a fix to a warning by newer version IASL compiler. > > The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: > > Merge branch 'master' of git://git.denx.de/u-boot-sh (2018-11-04 >

Re: [U-Boot] [PULL] Please pull u-boot-imx: u-boot-imx-20181106

2018-11-06 Thread Tom Rini
2018-11-04 > 08:12:21 -0500) > > are available in the Git repository at: > > git://www.denx.de/git/u-boot-imx.git tags/u-boot-imx-20181106 > > for you to fetch changes up to 0ea82ba2b082475090e11872ec11409a9fc8d486: > > MAINTAINERS: add NXP linux team mailli

Re: [U-Boot] [PATCH v2 2/2] cpu: sandbox: Add "u-boot, dm-pre-reloc" for all cpu nodes

2018-11-06 Thread sjg
On 14.10.2018 10:07, Bin Meng wrote: > To support CONFIG_DISPLAY_CPUINFO, add "u-boot,dm-pre-reloc" for > all cpu nodes in Sandbox test.dts. > > Signed-off-by: Bin Meng Reviewed-by: Stefan Roese Thanks, Stefan Applied to u-boot-dm/master, thanks!

Re: [U-Boot] Please pull u-boot/master

2018-11-06 Thread Tom Rini
On Tue, Nov 06, 2018 at 04:12:39PM +0100, Stefan Roese wrote: > Hi Tom, > > could you please pull these MVEBU fixes for the upcoming release? > > Thanks, > Stefan > > > The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: > > Merge branch 'master' of

Re: [U-Boot] [PATCH 03/13] gpio: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
> From: U-Boot On Behalf Of Bin Meng > Sent: mercredi 24 octobre 2018 15:37 > Subject: [U-Boot] [PATCH 03/13] gpio: Remove DM_FLAG_PRE_RELOC flag in > various drivers > > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be bound before > relocation. However due to a bug in the DM

Re: [U-Boot] [PATCH 04/13] i2c: omap24xx: Surround DM_FLAG_PRE_RELOC flag with OF_CONTROL check

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 02/13] clk: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH v2 1/2] cpu: Add DM_FLAG_PRE_RELOC flag to various cpu drivers

2018-11-06 Thread sjg
On 14.10.2018 10:07, Bin Meng wrote: > It turns out commit c0434407b595 broke some boards which have DM CPU > driver with CONFIG_DISPLAY_CPUINFO option on. These boards just fail > to boot when print_cpuinfo() is called during boot. > > Fixes: c0434407b595 ("board_f: Use static print_cpuinfo if

Re: [U-Boot] [PATCH 08/13] timer: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 06/13] pinctrl: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 05/13] mmc: omap: Surround DM_FLAG_PRE_RELOC flag with OF_CONTROL check

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 09/13] serial: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 01/13] arm: stm32mp: Remove DM_FLAG_PRE_RELOC flag

2018-11-06 Thread sjg
> From: U-Boot On Behalf Of Bin Meng > Sent: mercredi 24 octobre 2018 15:36 > > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be bound before > relocation. However due to a bug in the DM core, the flag only takes effect > when devices are statically declared via U_BOOT_DEVICE().

Re: [U-Boot] [PATCH 13/13] dm: doc: Update description of pre-relocation support

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > Add some description about pre-relocation driver binding, including > usage of DM_FLAG_PRE_RELOC flag and caveats. > > Signed-off-by: Bin Meng > > --- > > doc/driver-model/README.txt | 16 > 1 file changed, 12 insertions(+), 4

Re: [U-Boot] [PATCH 10/13] sysreset: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 07/13] ram: bmips: Remove DM_FLAG_PRE_RELOC flag

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 12/13] watchdog: Remove DM_FLAG_PRE_RELOC flag in various drivers

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

Re: [U-Boot] [PATCH 11/13] video: simplefb: Remove DM_FLAG_PRE_RELOC flag

2018-11-06 Thread sjg
On 24 October 2018 at 07:36, Bin Meng wrote: > When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be > bound before relocation. However due to a bug in the DM core, > the flag only takes effect when devices are statically declared > via U_BOOT_DEVICE(). This bug has been fixed recently

[U-Boot] [PATCH] mmc: dw_mmc: Add RCRC handling

2018-11-06 Thread Marek Vasut
This patch adds check for command response CRC failure. The driver is currently ignoring CRC check failure on command resposes which have CRC atteched to it, which can be potentially dangerous. Even more grueling problem happens when the command response is followed by data transfer though, as in

[U-Boot] [PATCH 25/25] mmc: Add hardware partition support

2018-11-06 Thread Simon Glass
MMC devices support multiple partitions, defined by the hardware. At present U-Boot can only access partition zero. Add support for selecting other partitions. Also add a way to check if a partition is write-protected. Signed-off-by: Simon Glass --- drivers/mmc/mmc.c | 46

[U-Boot] [PATCH 22/25] misc: Update read() and write() methods to return bytes xfered

2018-11-06 Thread Simon Glass
At present these functions return 0 on success. For some devices we want to know how many bytes were transferred. It seems useful to adjust the API to be more like the POSIX read() and write() functions. Update these two methods, a test and all users. Signed-off-by: Simon Glass ---

[U-Boot] [PATCH 18/25] tpm: Convert to use a device parameter

2018-11-06 Thread Simon Glass
At present many TPM calls assume there is only one TPM in the system and look up this TPM themselves. This is inconsistent with driver model, which expects all driver methods to have a device parameter. Update the code to correct this. Also move to u8/32 instead of uint8_t/uint32_t to keep

[U-Boot] [PATCH 23/25] test: sf: Add a simple SPI flash test

2018-11-06 Thread Simon Glass
The current test is a functional test, covering all the way from the command line to the sandbox SPI driver. This is useful, but it is easier to diagnose failures with a smaller test. Add a simple test which reads and writes data and checks that it is stored and retrieved correctly.

[U-Boot] [PATCH 11/25] spl: Support bootstage, log, hash and early malloc in TPL

2018-11-06 Thread Simon Glass
At present these features are supported in SPL but not TPL. Update the Kconfig and Makefile to allow this. Also add a few Makefile comments to make earier to track what is going on. Signed-off-by: Simon Glass --- common/Kconfig | 35 +++ common/Makefile | 10

[U-Boot] [PATCH 12/25] spl: Correct malloc debugging in board_init_r()

2018-11-06 Thread Simon Glass
SPL does not support %#x in printf() strings so we must write out the 0x explicitly. Update the code for this. Signed-off-by: Simon Glass --- common/spl/spl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/spl/spl.c b/common/spl/spl.c index 292e659c9ac..c855bb7ca4a

[U-Boot] [PATCH 24/25] sf: Add a method to obtain the block-protect setting

2018-11-06 Thread Simon Glass
It is useful to obtain the block-protect setting of the SPI flash, so we know whether it is fully open or (perhaps partially) write-protected. Add a method for this. Update the sandbox driver to process this operation and add a test. Signed-off-by: Simon Glass ---

[U-Boot] [PATCH 17/25] tpm: Export the open/close functions

2018-11-06 Thread Simon Glass
At present these functions are not accessible outside the TPM library, but in some cases we need to call them. Export them in the header file and add a define for the SHA1 digest size. Also adjust tpm_open() to call tpm_close() first so that the TPM is in a known state before opening (e.g. by a

[U-Boot] [PATCH 19/25] video: Update video_set_default_colors() to support invert

2018-11-06 Thread Simon Glass
It is useful to be able to invert the colours in some cases so that the text matches the background colour. Add a parameter to the function to support this. It is strange that function takes a private data structure from another driver as an argument. It seems better to pass the device and have

[U-Boot] [PATCH 20/25] efi_loader: Don't enable in SPL/TPL by default

2018-11-06 Thread Simon Glass
Generally this functionality is not useful in SPL or TPL. Update the Makefile so that it is not built. Signed-off-by: Simon Glass --- lib/Makefile | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/Makefile b/lib/Makefile index 4d2e22027d0..4dba3628e78 100644 ---

[U-Boot] [PATCH 13/25] spl: lz4: Allow use of lz4 compression in SPL

2018-11-06 Thread Simon Glass
In some cases U-Boot is compressed and it is useful to be able to decompress it in SPL. Add a Kconfig and Makefile change to allow this. Note that this does not actually implement decompression. Signed-off-by: Simon Glass --- lib/Kconfig | 8 lib/Makefile | 2 +- 2 files changed, 9

[U-Boot] [PATCH 16/25] binman: Set the pathname correctly for ELF files

2018-11-06 Thread Simon Glass
At present, stripped files don't have the right pathname which means that blob compression cannot be used. Fix this. Signed-off-by: Simon Glass --- tools/binman/etype/u_boot_elf.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/binman/etype/u_boot_elf.py

[U-Boot] [PATCH 09/25] sandbox: cros_ec: exynos: Drop use of cros_ec_get_error()

2018-11-06 Thread Simon Glass
This function is really just a call to uclass_get_device() and there is no reason why the caller cannot do it. Update sandbox and snow accordingly. Signed-off-by: Simon Glass --- board/samsung/common/board.c | 10 ++ board/sandbox/sandbox.c | 9 ++--- common/cros_ec.c

[U-Boot] [PATCH 21/25] string: Include the config header

2018-11-06 Thread Simon Glass
At present the config header is not included in this file, but it does use a CONFIG option. Fix it. Signed-off-by: Simon Glass --- lib/string.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/string.c b/lib/string.c index c4ca944bb42..af17c16f616 100644 --- a/lib/string.c +++

[U-Boot] [PATCH 15/25] binman: Drop an unnecessary comma in blob handling

2018-11-06 Thread Simon Glass
This comma is not needed. Drop it. Signed-off-by: Simon Glass --- tools/binman/etype/blob.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/binman/etype/blob.py b/tools/binman/etype/blob.py index 642a0e482a7..ae80bbee530 100644 --- a/tools/binman/etype/blob.py +++

[U-Boot] [PATCH 10/25] sandbox: Update some drivers to work in SPL/TPL

2018-11-06 Thread Simon Glass
At present sandbox drivers are mostly not used before relocation. Some of these are needed by Chromium OS verified boot, since it uses sandbox TPL, so update them accordingly. Signed-off-by: Simon Glass --- arch/sandbox/dts/sandbox.dts | 15 +++ 1 file changed, 15 insertions(+)

[U-Boot] [PATCH 08/25] sandbox: Add a function to read a host file

2018-11-06 Thread Simon Glass
Add a way to read a file from the host filesystem. This can be useful for reading test data, for example. Also fix up the writing function which was not the right version, and drop the debugging lines. Signed-off-by: Simon Glass --- arch/sandbox/cpu/os.c | 44

[U-Boot] [PATCH 07/25] sandbox: log: Add a category for sandbox

2018-11-06 Thread Simon Glass
It seems useful to make sandbox its own log category since it is used for so much testing. Add this as a new category. Signed-off-by: Simon Glass --- include/log.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/log.h b/include/log.h index a872fc6ef5f..deab82966bd 100644 ---

[U-Boot] [PATCH 06/25] sandbox: tpm: Allow debugging of data packages

2018-11-06 Thread Simon Glass
This is not normally useful, so change the code to avoid writing out every data package. This can be enabled with #define DEBUG. Signed-off-by: Simon Glass --- drivers/tpm/tpm_tis_sandbox.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/tpm/tpm_tis_sandbox.c

[U-Boot] [PATCH 03/25] cros_ec: Fail if we cannot determine the flash burst size

2018-11-06 Thread Simon Glass
This value is required for flashing to work correctly. Add a check for it. Signed-off-by: Simon Glass --- drivers/misc/cros_ec.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/misc/cros_ec.c b/drivers/misc/cros_ec.c index e0f3dfc98e0..7daf16499aa 100644 ---

[U-Boot] [PATCH 05/25] cros_ec: Add new features for events and power

2018-11-06 Thread Simon Glass
This adds new commands to the EC related to setting and clearing events as well as controlling power-related settings. Signed-off-by: Simon Glass --- drivers/misc/cros_ec.c | 345 - drivers/misc/cros_ec_sandbox.c | 2 +- include/cros_ec.h

[U-Boot] [PATCH 14/25] binman: Add a way to enable debugging from the build

2018-11-06 Thread Simon Glass
When the build fails due to something wrong in binman it is sometimes useful to get a full backtrace showing the location of the failure. Add a BINMAN_DEBUG environment variable to support this along with some documentation. Signed-off-by: Simon Glass --- Makefile| 6 --

[U-Boot] [PATCH 04/25] cros_ec: Align uclass data to a cache boundary

2018-11-06 Thread Simon Glass
The LPC driver expects its buffer to be word-aligned. Add the required flag to the uclass driver to ensure this. Signed-off-by: Simon Glass --- drivers/misc/cros_ec.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/misc/cros_ec.c b/drivers/misc/cros_ec.c index

[U-Boot] [PATCH 01/25] cros_ec: Use uint instead of u8 for parameters

2018-11-06 Thread Simon Glass
There is no advantage to using a u8 for function parameters. It forces the compiler to mask values and can increase code size. Also the command enum has been extended to 16 bits. Update the functions to use uint instead. Signed-off-by: Simon Glass --- drivers/misc/cros_ec.c | 10 -- 1

[U-Boot] [PATCH 02/25] cros_ec: Add error logging on a few commands

2018-11-06 Thread Simon Glass
Add some more logging to provide more information on failures. Signed-off-by: Simon Glass --- drivers/misc/cros_ec.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/misc/cros_ec.c b/drivers/misc/cros_ec.c index 4013f50d592..e0f3dfc98e0 100644 ---

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

2018-11-06 Thread Simon Glass
Hi Tom, The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: Merge branch 'master' of git://git.denx.de/u-boot-sh (2018-11-04 08:12:21 -0500) are available in the Git repository at: git://git.denx.de/u-boot-dm.git tags/pull-6-nov-18 for you to fetch changes up to

Re: [U-Boot] Pull request: u-boot-net.git master

2018-11-06 Thread Joe Hershberger
On Mon, Nov 5, 2018 at 10:06 PM Tom Rini wrote: > > On Mon, Nov 05, 2018 at 11:51:41AM -0600, Joe Hershberger wrote: > > > Hi Tom, > > > > Built successfully on Travis: > > https://travis-ci.org/jhershbe/u-boot/builds/450020193 > > > > The following changes since commit

Re: [U-Boot] [PATCH v3] Ability to modify distro boot filename

2018-11-06 Thread Heinrich Schuchardt
On 11/6/18 1:23 PM, Martyn Welch wrote: > Add in the ability to modify the distro boot filename. Whilst not > immediately useful in normal usage, it allows an alternative > configuration to be provided when other u-boot functionality is used, such > as bootcount limit, to fallback to an

[U-Boot] [PATCH] imx: hab: extend hab_auth_img to calculate ivt_offset

2018-11-06 Thread Parthiban Nallathambi
Current implementation of hab_auth_img command needs ivt_offset to authenticate the image. But ivt header is placed at the end of image date after padding. This leaves the usage of hab_auth_img command to fixed size or static offset for ivt header. New function "get_image_ivt_offset" is

Re: [U-Boot] [PATCH v4 17/18] doc: README.mediatek: Add a simple README for MediaTek

2018-11-06 Thread Frank Wunderlich
Apply: doc: README.mediatek: Add a simple README for MediaTek .git/rebase-apply/patch:194: trailing whitespace. warning: 1 Line adds Whitespace-Error. Apply: MAINTAINERS: add an entry for MediaTek but works so far ;) https://github.com/frank-w/u-boot/tree/bpi-r2_v4 Tested-by: Frank Wunderlich

[U-Boot] [PULL] Please pull u-boot-imx: u-boot-imx-20181106

2018-11-06 Thread Stefano Babic
-imx.git tags/u-boot-imx-20181106 for you to fetch changes up to 0ea82ba2b082475090e11872ec11409a9fc8d486: MAINTAINERS: add NXP linux team maillist as i.MX reviewer (2018-11-06 11:26:21 +0100) Fix coverity issues for i.MX8

Re: [U-Boot] [PATCH v2] riscv: cache: Implement i/dcache [status, enable, disable]

2018-11-06 Thread Auer, Lukas
Hi Rick, On Tue, 2018-11-06 at 10:28 +0800, Rick Chen wrote: > Auer, Lukas 於 2018年11月4日 週日 > 下午10:21寫道: > > > > Hi Rick, > > > > On Thu, 2018-11-01 at 12:08 +0800, Andes wrote: > > > From: Rick Chen > > > > > > AndeStar RISC-V(V5) provide mcache_ctl register which > > > can configure I/D

[U-Boot] Please pull u-boot/master

2018-11-06 Thread Stefan Roese
Hi Tom, could you please pull these MVEBU fixes for the upcoming release? Thanks, Stefan The following changes since commit 5ef76e59c12c79d106ebda70b710468aa6bd8b75: Merge branch 'master' of git://git.denx.de/u-boot-sh (2018-11-04 08:12:21 -0500) are available in the Git repository at:

[U-Boot] SPI in U-Boot on Raspberry Pi for TPM 2.0

2018-11-06 Thread Torben
Hi, does anyone know, if it is possible to use SPI in U-Boot on a Raspberry Pi 3 Model B? What I'm trying to achieve: - Connect a TPM 2.0 via SPI to the Raspberry Pi and communicate with it What I already have: - Compiled U-Boot with support for Raspberry Pi 3 Model B; I can access the

[U-Boot] CVE-2018-18439, CVE-2018-18440 - U-Boot verified boot bypass vulnerabilities

2018-11-06 Thread Andrea Barisani
Hello everyone, the following advisory has been posted last week to oss-security, per discussion with Tom Rini, whom helped us in the pre-notification phase, I also post it here for discussion. Cheers --- Security

Re: [U-Boot] [PATCH] spi: Zap mpc8xx_spi driver

2018-11-06 Thread Christophe LEROY
Le 05/11/2018 à 11:11, Jagan Teki a écrit : On Fri, Mar 2, 2018 at 3:17 PM Christophe LEROY wrote: Le 26/02/2018 à 15:43, Jagan Teki a écrit : - Driver not used by any boards This driver should be used by MCR3000 board. For the time being SPI is not activated on that board because we are

[U-Boot] [PATCH v3] Ability to modify distro boot filename

2018-11-06 Thread Martyn Welch
Add in the ability to modify the distro boot filename. Whilst not immediately useful in normal usage, it allows an alternative configuration to be provided when other u-boot functionality is used, such as bootcount limit, to fallback to an alternative boot configuration. In this case we can follow

Re: [U-Boot] [PATCH v2] Ability to modify distro boot filename

2018-11-06 Thread Martyn Welch
On Mon, 2018-11-05 at 20:43 +0100, Heinrich Schuchardt wrote: > On 11/05/2018 07:13 PM, Martyn Welch wrote: > > Add in the ability to modify the distro boot filename. Whilst not > > immediately useful in normal usage, it allows an alternative > > configuration to be provided when other u-boot

  1   2   >