Re: [U-Boot] [PATCH v1] arch/x86: Select USB before selecting host driver

2017-07-04 Thread Bin Meng
Hi Andy, On Wed, Jul 5, 2017 at 12:32 AM, Andy Shevchenko wrote: > Kbuild complains if USB is not selected before any of host driver. > > warning: (X86) selects USB_EHCI_HCD which has unmet direct dependencies (USB) > warning: (X86) selects USB_EHCI_HCD which

Re: [U-Boot] [PATCH v1] avr32: Retire AVR32 for good

2017-07-04 Thread Tom Rini
On Wed, Jul 05, 2017 at 05:08:26AM +0200, Heiko Schocher wrote: > Hello Andy, > > Am 04.07.2017 um 18:25 schrieb Andy Shevchenko: > >AVR32 is gone. It's already more than two years for no support in Buildroot, > >even longer there is no support in GCC (last version is heavily patched > >4.2.4).

Re: [U-Boot] [PATCH v1] avr32: Retire AVR32 for good

2017-07-04 Thread Heiko Schocher
Hello Andy, Am 04.07.2017 um 18:25 schrieb Andy Shevchenko: AVR32 is gone. It's already more than two years for no support in Buildroot, even longer there is no support in GCC (last version is heavily patched 4.2.4). Linux kernel v4.12 got rid of it (and v4.11 didn't build successfully).

Re: [U-Boot] [PATCH 2/2] arm: config: enforce -fno-pic for SPL and normal U-Boot

2017-07-04 Thread Tom Rini
On Wed, Jul 05, 2017 at 01:02:42AM +, Peng Fan wrote: > > > > -Original Message- > > From: Tom Rini [mailto:tr...@konsulko.com] > > Sent: Tuesday, July 04, 2017 9:35 PM > > To: Peng Fan > > Cc: Simon Glass ; Philipp Tomsich > >

Re: [U-Boot] [PATCH 0/5] fix the boot issue of Rockchip RK3036

2017-07-04 Thread Tom Rini
On Wed, Jul 05, 2017 at 09:08:47AM +0800, Andy Yan wrote: > Hi Tom: > > > On 2017年07月04日 21:32, Tom Rini wrote: > >On Mon, Jul 03, 2017 at 04:02:59PM +0800, Andy Yan wrote: > >>Hi Philipp: > >> > >> > >>On 2017年06月30日 16:14, Dr. Philipp Tomsich wrote: > >>>Andy, > >>> > On 30 Jun 2017, at

Re: [U-Boot] [PATCH 1/2] armv8: apply -mgeneral-regs-only

2017-07-04 Thread Peng Fan
> -Original Message- > From: Tom Rini [mailto:tr...@konsulko.com] > Sent: Wednesday, July 05, 2017 3:38 AM > To: Dr. Philipp Tomsich > Cc: Peng Fan ; u-boot@lists.denx.de > Subject: Re: [U-Boot] [PATCH 1/2] armv8: apply

Re: [U-Boot] [PATCH 0/5] fix the boot issue of Rockchip RK3036

2017-07-04 Thread Andy Yan
Hi Tom: On 2017年07月04日 21:32, Tom Rini wrote: On Mon, Jul 03, 2017 at 04:02:59PM +0800, Andy Yan wrote: Hi Philipp: On 2017年06月30日 16:14, Dr. Philipp Tomsich wrote: Andy, On 30 Jun 2017, at 09:47, Andy Yan wrote: As Kever mentioned in [0], the RK3036 based

Re: [U-Boot] [PATCH 1/2] armv8: apply -mgeneral-regs-only

2017-07-04 Thread Peng Fan
> -Original Message- > From: Tom Rini [mailto:tr...@konsulko.com] > Sent: Wednesday, July 05, 2017 3:38 AM > To: Dr. Philipp Tomsich > Cc: Peng Fan ; u-boot@lists.denx.de > Subject: Re: [U-Boot] [PATCH 1/2] armv8: apply

Re: [U-Boot] [PATCH 2/2] arm: config: enforce -fno-pic for SPL and normal U-Boot

2017-07-04 Thread Peng Fan
> -Original Message- > From: Tom Rini [mailto:tr...@konsulko.com] > Sent: Tuesday, July 04, 2017 9:35 PM > To: Peng Fan > Cc: Simon Glass ; Philipp Tomsich > ; albert.u.b...@aribaud.net; u- > b...@lists.denx.de

Re: [U-Boot] [PATCH 0/5] fix the boot issue of Rockchip RK3036

2017-07-04 Thread Andy Yan
Hi Heiko: On 2017年07月05日 03:54, Heiko Stübner wrote: Hi Andy, Am Montag, 3. Juli 2017, 16:02:59 CEST schrieb Andy Yan: On 2017年06月30日 16:14, Dr. Philipp Tomsich wrote: On 30 Jun 2017, at 09:47, Andy Yan wrote: As Kever mentioned in [0], the RK3036 based boards

Re: [U-Boot] [PULL] efi patch queue 2017-07-04 (v2)

2017-07-04 Thread Tom Rini
On Tue, Jul 04, 2017 at 09:06:13AM +0200, Alexander Graf wrote: > Hi Tom, > > This is my current patch queue for efi. Please pull. > > Alex > > > The following changes since commit 8d6040c725bfa40fba1bd6b5f356ee713c1ac7d1: > > pico-imx7d: Remove bouncing email (2017-06-29 21:30:16 -0400)

Re: [U-Boot] [PATCH v1] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread Andy Shevchenko
On Wed, Jul 5, 2017 at 12:23 AM, lukma wrote: >> On Tue, 2017-07-04 at 16:31 -0400, Tom Rini wrote: >>> On Tue, Jul 04, 2017 at 10:48:36PM +0300, Andy Shevchenko wrote: On Tue, 2017-04-18 at 16:49 +0200, Lukasz Majewski wrote: I started looking into this direction and

[U-Boot] [PATCH 00/39] dm: sata: Complete driver-model support for SATA

2017-07-04 Thread Simon Glass
This series completes the conversion of SATA to driver model. Previous work converted SCSI including the SCSI-based SATA driver. This series converts the AHCI uclass itself, adding operations and adjusting the 'sata' command to work correctly. An existing board (Compulab Utilite) is used for

Re: [U-Boot] [PATCH 5/5] fit: Introduce methods for applying overlays on fit-load

2017-07-04 Thread stefan.bruens
On Dienstag, 4. Juli 2017 19:05:25 CEST Pantelis Antoniou wrote: > Hi Marek, > > On Sat, 2017-07-01 at 16:11 +0200, Marek Vasut wrote: > > On 06/30/2017 06:23 PM, Pantelis Antoniou wrote: > > > Introduce an overlay based method for constructing a base DT blob > > > to pass to the kernel. > > > >

[U-Boot] [PATCH] sandbox: Enable more drivers for more build coverage

2017-07-04 Thread Tom Rini
Enable more drivers that build currently. This will extend our build time test coverage Cc: Simon Glass Signed-off-by: Tom Rini --- configs/sandbox_defconfig | 23 +++ 1 file changed, 23 insertions(+) diff --git

Re: [U-Boot] [PATCH v1] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread lukma
Hi Andy, On Tue, 2017-07-04 at 16:31 -0400, Tom Rini wrote: On Tue, Jul 04, 2017 at 10:48:36PM +0300, Andy Shevchenko wrote: On Tue, 2017-04-18 at 16:49 +0200, Lukasz Majewski wrote: The code seems OK, but recently patches to add wdt-uclass has been posted:

Re: [U-Boot] [linux-sunxi] Re: [PATCH 3/4] sunxi: add stub EMAC device node in A83T device tree

2017-07-04 Thread Maxime Ripard
On Tue, Jul 04, 2017 at 08:07:42AM +0800, Icenowy Zheng wrote: > > > 于 2017年7月4日 GMT+08:00 上午4:46:17, Maxime Ripard > 写到: > >On Mon, Jul 03, 2017 at 02:54:17PM +0800, Icenowy Zheng wrote: > >> > >> > >> 于 2017年7月3日 GMT+08:00 下午2:52:00, Maxime Ripard >

[U-Boot] [PATCH v3 1/3] bootefi: allow return without EFI_BOOT_SERVICES.Exit

2017-07-04 Thread Heinrich Schuchardt
The Unified Extensible Firmware Interface Specification, version 2.7, defines in chapter 2.1.2 - UEFI Application that an EFI application may either directly return or call EFI_BOOT_SERVICES.Exit(). Unfortunately U-Boot makes the incorrect assumption that EFI_BOOT_SERVICES.Exit() is always

[U-Boot] [PATCH v3 3/3] efi_loader: provide meaningful status code

2017-07-04 Thread Heinrich Schuchardt
Currenty any EFI status other than EFI_SUCCESS is reported as Application terminated, r = -22 With the patch the status code returned by the EFI application is printed. Cc: Alexander Graf Signed-off-by: Heinrich Schuchardt --- v3: Use constant

[U-Boot] [PATCH v3 2/3] efi_loader: define all known status codes

2017-07-04 Thread Heinrich Schuchardt
efi.h held only a few EFI status codes. The patch adds the missing definitions for later usage. Signed-off-by: Heinrich Schuchardt --- v3 Create a define of the error bit mask. v2 This patch was split of version 1 of efi_loader: provide meaningful

[U-Boot] [PATCH v3 0/3] Handling of EFI application exit

2017-07-04 Thread Heinrich Schuchardt
EFI applications may proceed to loading and starting an operating system. In this case they do not return to OpenWrt. On the other hand they may return to OpenWrt. In this case they may either call EFI_BOOT_SERVICES.Exit of return directly with a status code. The first patch ensures correct

[U-Boot] [PATCH] sandbox: Update defconfig for more build coverage

2017-07-04 Thread Tom Rini
Enable all of the currently Kconfig'd cmd's that will build in sandbox right now. This will extend our build time test coverage. Cc: Simon Glass Signed-off-by: Tom Rini --- configs/sandbox_defconfig | 17 + 1 file changed, 17

Re: [U-Boot] [BUG] checkpatch: false positive storage class location

2017-07-04 Thread Heinrich Schuchardt
On 07/04/2017 10:44 PM, Joe Perches wrote: > On Tue, 2017-07-04 at 21:29 +0200, Heinrich Schuchardt wrote: >> The U-Boot project uses the same scripts/checkpatch.pl as the Linux >> kernel. I ran upon the problem below when working on U-Boot. But I >> guess it should be fixed in the Linux upstream.

Re: [U-Boot] [BUG] checkpatch: false positive storage class location

2017-07-04 Thread Joe Perches
On Tue, 2017-07-04 at 21:29 +0200, Heinrich Schuchardt wrote: > The U-Boot project uses the same scripts/checkpatch.pl as the Linux > kernel. I ran upon the problem below when working on U-Boot. But I > guess it should be fixed in the Linux upstream. > > Running checkpatch for this email produces

Re: [U-Boot] [PATCH v1] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread Andy Shevchenko
On Tue, 2017-07-04 at 16:31 -0400, Tom Rini wrote: > On Tue, Jul 04, 2017 at 10:48:36PM +0300, Andy Shevchenko wrote: > > On Tue, 2017-04-18 at 16:49 +0200, Lukasz Majewski wrote: > > > > > > The code seems OK, but recently patches to add wdt-uclass has been > > > posted: > > > > > >

[U-Boot] [PATCH v2] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread Andy Shevchenko
From: Felipe Balbi Add watchdog driver for Intel Tangier based platforms. Signed-off-by: Vincent Tinelli Signed-off-by: Felipe Balbi Signed-off-by: Andy Shevchenko --- In

Re: [U-Boot] [PATCH v1] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread Tom Rini
On Tue, Jul 04, 2017 at 10:48:36PM +0300, Andy Shevchenko wrote: > On Tue, 2017-04-18 at 16:49 +0200, Lukasz Majewski wrote: > > > > The code seems OK, but recently patches to add wdt-uclass has been > > posted: > > > > http://patchwork.ozlabs.org/patch/751448/ > >

[U-Boot] [PATCH 38/39] dm: mmc: Correct Kconfig condition for SPL_DM_MMC_OPS

2017-07-04 Thread Simon Glass
This should depend on SPL_DM_MMC, not SPL_DM. For it and update the only affected board's defconfig. Signed-off-by: Simon Glass --- configs/Linksprite_pcDuino3_defconfig | 3 --- drivers/mmc/Kconfig | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-)

[U-Boot] [PATCH 33/39] dm: imx: cm_fx6: Support driver model for SATA

2017-07-04 Thread Simon Glass
Add support for using driver model for SATA with the cm_fx6 board. The old code remains for now to permit testing. Signed-off-by: Simon Glass --- board/compulab/cm_fx6/cm_fx6.c | 69 ++ 1 file changed, 69 insertions(+) diff --git

[U-Boot] [PATCH 36/39] dm: imx: cm_fx6: Enable more driver model support

2017-07-04 Thread Simon Glass
Enable driver model for MMC (including BLK), SATA and USB. Note that USB does not yet work correctly since the nodes are disabled. Hopefully this can be resolved by the maintainer. Signed-off-by: Simon Glass --- configs/cm_fx6_defconfig | 8 +++- drivers/mmc/fsl_esdhc.c

[U-Boot] [PATCH 25/39] dm: mmc: fsl_esdhc: Pass private data to internal functions

2017-07-04 Thread Simon Glass
With driver model we will not use mmc->priv to access driver-private data. To accomodate this, update internal functions so that we can pass the private data directly. This will allow the caller to obtain it as it prefers. Signed-off-by: Simon Glass ---

[U-Boot] [PATCH 31/39] dm: mmc: fsl_esdhc: Update to support livetree

2017-07-04 Thread Simon Glass
Update this driver to support a live device tree. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/drivers/mmc/fsl_esdhc.c b/drivers/mmc/fsl_esdhc.c index 1ca39a5026..357db64085 100644

Re: [U-Boot] [PATCH 0/5] fix the boot issue of Rockchip RK3036

2017-07-04 Thread Heiko Stübner
Hi Andy, Am Montag, 3. Juli 2017, 16:02:59 CEST schrieb Andy Yan: > On 2017年06月30日 16:14, Dr. Philipp Tomsich wrote: > >> On 30 Jun 2017, at 09:47, Andy Yan wrote: > >> As Kever mentioned in [0], the RK3036 based boards could't > >> bootup for a long time. > >> After a

[U-Boot] [PATCH 39/39] dm: mmc: Drop CONFIG_DM_MMC_OPS

2017-07-04 Thread Simon Glass
All boards which use DM_MMC have now been converted to use DM_MMC_OPS. Drop the option and good riddance. Signed-off-by: Simon Glass --- arch/arm/Kconfig | 2 -- drivers/mmc/Kconfig | 39 +-- drivers/mmc/dw_mmc.c

[U-Boot] [PATCH 29/39] dm: mmc: fsl_esdhc: Set up platform data

2017-07-04 Thread Simon Glass
With driver model we want to store the mmc and configuration structure in platform data. Set up structure up and use it for non-DM as well. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 61 +++-- 1 file changed, 39

[U-Boot] [PATCH 22/39] dm: sata: imx: Allow driver model to be used for sata

2017-07-04 Thread Simon Glass
Update the sata call to work with driver model. Signed-off-by: Simon Glass --- arch/arm/imx-common/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/imx-common/cpu.c b/arch/arm/imx-common/cpu.c index 9e83b4221e..1017eb84f9 100644 ---

[U-Boot] [PATCH 34/39] dm: imx: cm_fx6: Add device tree for cm_fx6

2017-07-04 Thread Simon Glass
Add this file so we can use device-tree control for cm_fx6. It comes from linux 4.12. Signed-off-by: Simon Glass --- arch/arm/dts/Makefile | 1 + arch/arm/dts/imx6q-cm-fx6.dts | 115 ++ 2 files changed, 116 insertions(+)

[U-Boot] [PATCH 37/39] dm: imx: Move i.MX devices to use CONFIG_DM_MMC_OPS

2017-07-04 Thread Simon Glass
Now that the driver supports it, move these boards over to use driver model fully for MMC. Signed-off-by: Simon Glass --- configs/imx6q_logic_defconfig | 1 - configs/imx6qdl_icore_mmc_defconfig | 1 - configs/imx6qdl_icore_rqs_mmc_defconfig | 1 -

[U-Boot] [PATCH 30/39] dm: mmc: fsl_esdhc: Drop mmc_init() call from fsl_esdhc_init()

2017-07-04 Thread Simon Glass
We want to use fsl_esdhc_init() with driver model. Move the mmc_init() out of this function so that we can use it for our common init. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git

[U-Boot] [PATCH 08/39] dm: core: Add a comment about the device_remove() flags

2017-07-04 Thread Simon Glass
We should explain which flags are used for this function. Update the comment to indicate this. Signed-off-by: Simon Glass --- include/dm/device-internal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/dm/device-internal.h

[U-Boot] [PATCH 20/39] dm: sata: dw_sata: Set up common versions of operations

2017-07-04 Thread Simon Glass
Driver model wants to use the core functions in this file but accesses the uclass-private data in a different way. Move the code into new 'common' functions and set up stubs to call these. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 236

[U-Boot] [PATCH 23/39] dm: sata: Update the AHCI uclass to support operations

2017-07-04 Thread Simon Glass
At present the AHCI uclass is just a shell and we still use the global functions to access SATA. Fix this by adding operations to the uclass. Signed-off-by: Simon Glass --- drivers/ata/sata.c | 37 + include/ahci.h | 54

[U-Boot] [PATCH 09/39] dm: sata: dwc_ahsata: Make functions static

2017-07-04 Thread Simon Glass
Some functions are not called from outside this file. Make these static to make that obvious. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/ata/dwc_ahsata.c

[U-Boot] [PATCH 11/39] dm: sata: dw_sata: Move exported functions to the end

2017-07-04 Thread Simon Glass
With the driver model conversion we will not have any exported functions. Move all exported functions to be together at the end of the file so that we can deal with them in one #ifdef block. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 124

[U-Boot] [PATCH 26/39] dm: mmc: fsl_esdhc: Set up common versions of operations

2017-07-04 Thread Simon Glass
Driver model wants to use the core functions in this file but accesses the driver-private data in a different way. Move the code into new 'common' functions and set up stubs to call these. Also sort the operations into alphabetical order for consistency. Signed-off-by: Simon Glass

[U-Boot] [PATCH 21/39] dm: sata: Support driver model with the 'sata' command

2017-07-04 Thread Simon Glass
Update this command to support driver model. This has a different way of starting and stopping SATA. Signed-off-by: Simon Glass --- cmd/sata.c | 95 -- common/splash_source.c | 2 +- include/sata.h | 5 ++-

[U-Boot] [PATCH 05/39] dm: ide: Adjust the 'ide' command to use blk_common_cmd()

2017-07-04 Thread Simon Glass
Instead of having separate code in the 'ide' command, adjust it to use the common function. Signed-off-by: Simon Glass --- cmd/ide.c | 107 ++ 1 file changed, 3 insertions(+), 104 deletions(-) diff --git

[U-Boot] [PATCH 18/39] dm: sata: dw_sata: Drop is_ready

2017-07-04 Thread Simon Glass
This variable is set but never used. Drop it. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/ata/dwc_ahsata.c b/drivers/ata/dwc_ahsata.c index 8056bc94a3..4b89a8b788 100644 --- a/drivers/ata/dwc_ahsata.c

[U-Boot] [PATCH 06/39] dm: usb: Adjust the 'usb' command to use blk_common_cmd()

2017-07-04 Thread Simon Glass
Instead of having separate code in the 'usb' command, adjust it to use the common function. Signed-off-by: Simon Glass --- cmd/usb.c | 111 ++ 1 file changed, 3 insertions(+), 108 deletions(-) diff --git

[U-Boot] [PATCH 13/39] dm: sata: dw_sata: Drop unnecessary casts

2017-07-04 Thread Simon Glass
Most of the casts in this driver are not necessary. With driver model we do not cast from void *. Update the driver to follow this rule. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 60 ++-- 1 file changed, 22

[U-Boot] [PATCH 35/39] dm: imx: cm_fx6: Add MMC support for CONFIG_BLK

2017-07-04 Thread Simon Glass
When CONFIG_BLK is enabled our weak board_mmc_init() will not be called. Since there is no clock driver for MX6 yet, we must manually enable the clocks. Signed-off-by: Simon Glass --- board/compulab/cm_fx6/cm_fx6.c | 11 +++ 1 file changed, 11 insertions(+) diff

[U-Boot] [PATCH 15/39] dm: sata: dw_sata: Drop unnecessary brackets

2017-07-04 Thread Simon Glass
There is a strange &(var) coding style in this driver. Adjust it to use instead, which is more usual. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 98 1 file changed, 48 insertions(+), 50 deletions(-) diff --git

[U-Boot] [PATCH 27/39] dm: mmc: fsl_esdhc: Detect reset failure

2017-07-04 Thread Simon Glass
Since esdhc_reset() can fail it should return an error code. Update this and also adjust the timeout mechanism to use get_timer(), which is a more common approach. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 22 +++--- 1 file changed, 15

[U-Boot] [PATCH 32/39] dm: mmc: fsl_esdhc: Update to support MMC operations

2017-07-04 Thread Simon Glass
This driver does not currently support CONFIG_DM_MMC_OPS. Update it to fully convert it to driver model. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 69 + 1 file changed, 64 insertions(+), 5 deletions(-) diff

[U-Boot] [PATCH 16/39] dm: sata: dw_sata: Sort #include directives

2017-07-04 Thread Simon Glass
Sort the header file inclusions into the correct order. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/ata/dwc_ahsata.c b/drivers/ata/dwc_ahsata.c index 63e7b7d7a1..b6915d217b

[U-Boot] [PATCH 24/39] dm: sata: dwc_ahsata: Add support for driver model

2017-07-04 Thread Simon Glass
Update this driver to support driver model. This involves implementing the AHCI operations and reusing existing common code. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 113 +++ include/dwc_ahsata.h | 16 +++

[U-Boot] [PATCH 10/39] dm: sata: dw_sata: Drop dwc_ahsata_rw_ncq_cmd()

2017-07-04 Thread Simon Glass
This function is not called from anywhere. Drop it. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 43 --- 1 file changed, 43 deletions(-) diff --git a/drivers/ata/dwc_ahsata.c b/drivers/ata/dwc_ahsata.c index

[U-Boot] [PATCH 12/39] dm: sata: dw_sata: Rename 'probe_ent' to uc_priv

2017-07-04 Thread Simon Glass
With driver model this becomes uclass-private data. Rename the parameter varable to reflect this. With the driver model conversion we will not have any exported functions. Move all exported functions to be together at the end of the file so that we can deal with them in one #ifdef block.

[U-Boot] [PATCH 28/39] dm: mmc: fsl_esdhc: Detect init failure

2017-07-04 Thread Simon Glass
Since esdhc_init_common() can fail it should return an error code. Update this and also adjust the timeout mechanism to use get_timer(), which is a more common approach. Signed-off-by: Simon Glass --- drivers/mmc/fsl_esdhc.c | 9 ++--- 1 file changed, 6 insertions(+), 3

[U-Boot] [PATCH 14/39] dm: sata: dw_sata: Pass uc_priv to internal functions

2017-07-04 Thread Simon Glass
With driver model sata_dev_desc[] does not exist. We still want to use the common code of this driver so update it to pass struct ahci_uc_priv * to each of these functions, instead of an integer which must be looked up in sata_dev_desc[]. Signed-off-by: Simon Glass ---

[U-Boot] [PATCH 07/39] dm: blk: Update return value in blk_create_devicef()

2017-07-04 Thread Simon Glass
This returns 'ret' but the value is always zero. Update it to simply return 0, for clarity. Signed-off-by: Simon Glass --- drivers/block/blk-uclass.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/block/blk-uclass.c b/drivers/block/blk-uclass.c

[U-Boot] [PATCH 19/39] dm: sata: dw_sata: More ahci_init_one() futher down

2017-07-04 Thread Simon Glass
This function will not be used with driver model and it relates to the other exported functions. Move it down next to them. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c | 66 1 file changed, 33 insertions(+), 33

[U-Boot] [PATCH 17/39] dm: sata: dw_sata: Rename the dwc_ahsata private header

2017-07-04 Thread Simon Glass
Rename dwc_ahsata.h to indicate that it is a private header file. We plan to create another header with some public functions. Signed-off-by: Simon Glass --- drivers/ata/dwc_ahsata.c| 2 +- drivers/ata/{dwc_ahsata.h => dwc_ahsata_priv.h} | 6 +++--- 2

[U-Boot] [PATCH 04/39] dm: scsi: Adjust the 'scsi' command to use blk_common_cmd()

2017-07-04 Thread Simon Glass
Instead of having separate code in the 'scsi' command, adjust it to use the common function. Signed-off-by: Simon Glass --- cmd/scsi.c | 79 +++--- 1 file changed, 3 insertions(+), 76 deletions(-) diff --git

[U-Boot] [PATCH 02/39] dm: blk: Add a generic function for block device commands

2017-07-04 Thread Simon Glass
Most block devices provide a command (e.g. 'sata', 'scsi', 'ide') and these commands generally do the same thing. This makes it harder to maintain this code and keep it consistent. We now have a block device interface which is either implemented by driver model (when CONFIG_BLK is enabled) or

[U-Boot] [PATCH 01/39] dm: blk: Add a function to find an interface-type name

2017-07-04 Thread Simon Glass
Add a function to find the name of an interface type (e.g. "sata", "scsi") from the interface type enum. This is useful for generic code (not specific to SATA or SCSI, for example) that wants to display the type of interface it is dealing with. Signed-off-by: Simon Glass ---

Re: [U-Boot] [PATCH v1] avr32: Retire AVR32 for good

2017-07-04 Thread Simon Glass
On 4 July 2017 at 13:37, Tom Rini wrote: > On Tue, Jul 04, 2017 at 07:25:43PM +0300, Andy Shevchenko wrote: > >> AVR32 is gone. It's already more than two years for no support in Buildroot, >> even longer there is no support in GCC (last version is heavily patched >> 4.2.4).

[U-Boot] [PATCH 03/39] dm: sata: Adjust the 'sata' command to use blk_common_cmd()

2017-07-04 Thread Simon Glass
Instead of having separate code in the 'sata' command, adjust it to use the common function. Signed-off-by: Simon Glass --- cmd/sata.c | 83 +- 1 file changed, 1 insertion(+), 82 deletions(-) diff --git

Re: [U-Boot] [PATCH v1] watchdog: Introduce watchdog driver for Intel Tangier

2017-07-04 Thread Andy Shevchenko
On Tue, 2017-04-18 at 16:49 +0200, Lukasz Majewski wrote: > > The code seems OK, but recently patches to add wdt-uclass has been > posted: > > http://patchwork.ozlabs.org/patch/751448/ > http://patchwork.ozlabs.org/patch/751451/ > > Maybe it would be better to port this driver to the uclass

Re: [U-Boot] [PATCH v1] avr32: Retire AVR32 for good

2017-07-04 Thread Tom Rini
On Tue, Jul 04, 2017 at 07:25:43PM +0300, Andy Shevchenko wrote: > AVR32 is gone. It's already more than two years for no support in Buildroot, > even longer there is no support in GCC (last version is heavily patched > 4.2.4). > > Linux kernel v4.12 got rid of it (and v4.11 didn't build

Re: [U-Boot] [ANN] U-Boot v2017.07-rc2 released

2017-07-04 Thread Simon Glass
Hi Peter, On 21 June 2017 at 01:07, Peter Robinson wrote: > Simon, do you have some suggestions on what to do here? Thanks! > > -- > Tom My guess is that there is already a libfdt.py in the system. Someone else reported this too. We

Re: [U-Boot] [PATCH v6] mmc: gen_atmel_mci: add driver model support for mci

2017-07-04 Thread Simon Glass
Hi Wenyou, On 12 April 2017 at 20:29, Wenyou Yang wrote: > Add the driver model support for Atmel mci while retaining the > existing legacy code. This allows the driver to support boards > that have converted to driver model as well as those that have not. > >

Re: [U-Boot] [ANN] U-Boot v2017.07-rc2 released

2017-07-04 Thread Simon Glass
Hi Andreas, On 23 June 2017 at 10:19, Andreas Färber wrote: > Hi, > > On mvebu_db-88f3720 I am seeing endless resets when doing "scsi scan" or > "scan reset" (SATA). I am chain-loading U-Boot from the vendor U-Boot. > > It seems the latest version working was v2017.01, v2017.03

Re: [U-Boot] [PATCH 1/2] armv8: apply -mgeneral-regs-only

2017-07-04 Thread Tom Rini
On Tue, Jul 04, 2017 at 06:38:10PM +0200, Dr. Philipp Tomsich wrote: > Tom, > > Please note that some GCC versions had a code-generation bug > when -mgeneral-regs-only was used (we hit this for a customer in > a vendor GCC we maintain): > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64304 >

Re: [U-Boot] [PATCH 10/14] dm: mmc: sunxi: Add support for driver model

2017-07-04 Thread Simon Glass
Hi Maxime, On 21 June 2017 at 01:31, Maxime Ripard wrote: > Hi Simon, > > On Mon, Jun 19, 2017 at 11:11:27AM -0600, Simon Glass wrote: >> Add a driver-model version of this driver which mostly uses the existing >> code. The old code can be removed once all

[U-Boot] [PATCH v2 11/15] dm: sunxi: Linksprite_pcDuino3: Correct polarity of MMC card detect

2017-07-04 Thread Simon Glass
This is shown as active high in the schematics[1], so fix it. [1] https://patchwork.ozlabs.org/patch/777890/ Signed-off-by: Simon Glass Reported-by: Maxime Ripard --- Changes in v2: - Add new patch to correct polarity of MMC card detect on

[U-Boot] [PATCH v2 13/15] dm: sunxi: sata: Don't build sata support into SPL

2017-07-04 Thread Simon Glass
This is not used in SPL so we do not need to compile it. Make this change before adding driver-model support to the driver, to avoid build errors. With driver model we define a U_BOOT_DRIVER() which would otherwise be present in SPL and not be garbage-collected when building. Signed-off-by: Simon

[U-Boot] [PATCH v2 08/15] dm: mmc: sunxi: Pass private data around explicitly

2017-07-04 Thread Simon Glass
At present the driver-private data is obtained in various functions by various means. With driver model this is provided automatically. Without driver model it comes from a C array declared at the top of the file. Adjust internal functions so that they are passed the private data as a parameter,

[U-Boot] [PATCH v2 14/15] dm: sata: sunxi: Add support for driver model

2017-07-04 Thread Simon Glass
Adjust SATA setup to support driver model. Signed-off-by: Simon Glass --- Changes in v2: None board/sunxi/ahci.c | 61 +++--- 1 file changed, 58 insertions(+), 3 deletions(-) diff --git a/board/sunxi/ahci.c

[U-Boot] [PATCH v2 15/15] dm: sunxi: Move Linksprite_pcDuino3 to use DM for MMC, SATA

2017-07-04 Thread Simon Glass
Move this board over to driver model for MMC and SATA. This means that it uses CONFIG_BLK as well. In SPL these options remain turned off since it increases the code size. One option would be to use CONFIG_SPL_OF_PLATDATA to avoid device-tree overhead. Signed-off-by: Simon Glass

[U-Boot] [PATCH v2 09/15] dm: mmc: sunxi: Drop mmc_clk_io_on()

2017-07-04 Thread Simon Glass
This function has #ifdefs in it which we want to avoid for driver model. Instead we should use different compatible strings and the .data field. It also uses the MMC device number which is not available in driver model except through aliases. Move the function's into its caller so that the

[U-Boot] [PATCH v2 05/15] dm: ahci: Correct uclass private data

2017-07-04 Thread Simon Glass
This is expected to be attached to the uclass and the code operates that way, but the uclass has not been updated. Fix it to avoid using memory at address 0. Signed-off-by: Simon Glass Fixes: 47fc61a (dm: ahci: Drop use of probe_ent) --- Changes in v2: None

[U-Boot] [PATCH v2 10/15] dm: mmc: sunxi: Add support for driver model

2017-07-04 Thread Simon Glass
Add a driver-model version of this driver which mostly uses the existing code. The old code can be removed once all boards are switched over. Signed-off-by: Simon Glass --- Changes in v2: - Drop debugging printf() now that the card detect is working drivers/mmc/sunxi_mmc.c

[U-Boot] [PATCH v2 07/15] dm: mmc: sunxi: Rename mmchost to priv

2017-07-04 Thread Simon Glass
Use the driver-model naming convention for this structure. It is data private to the driver so the local variable should be called 'priv'. Signed-off-by: Simon Glass --- Changes in v2: None drivers/mmc/sunxi_mmc.c | 125 1

[U-Boot] [PATCH v2 03/15] fdt: Correct fdt_get_base_address()

2017-07-04 Thread Simon Glass
This function appears to obtain the value of the 'ranges' property rather than 'reg'. As such it does not behave as documented or expected. In addition it picks up the second field of the property which is the size (with prop += naddr) rather than the first which is the address. Fix it.

[U-Boot] [PATCH v2 02/15] dm: mmc: Allow disabling driver model in SPL

2017-07-04 Thread Simon Glass
At present if U-Boot proper uses driver model for MMC, then SPL has to also. While this is desirable, it places a significant barrier to moving to driver model in some cases. For example, with a space-constrained SPL it may be necessary to enable CONFIG_SPL_OF_PLATDATA which involves adjusting

[U-Boot] [PATCH v2 04/15] dm: scsi: Drop duplicate SCSI and DM_SCSI options

2017-07-04 Thread Simon Glass
When the SATA code was moved into drivers/ata these Kconfig options were added to that directory. They already exist in drivers/scsi. Remove them from drivers/ata to fix the duplication. Signed-off-by: Simon Glass Fixes: 7f2b5f4 (sata: Move drivers into new drivers/ata

[U-Boot] [PATCH v2 06/15] dm: mmc: sunxi: Rename struct sunxi_mmc_host to sunxi_mmc_priv

2017-07-04 Thread Simon Glass
Use the driver-model naming convention for this structure. It is data private to the driver. Signed-off-by: Simon Glass --- Changes in v2: None drivers/mmc/sunxi_mmc.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git

[U-Boot] [PATCH v2 01/15] ahci: Support non-PCI controllers

2017-07-04 Thread Simon Glass
At present the AHCI SCSI driver only supports PCI with driver model. Rename the existing function to indicate this and add support for adding a non-PCI controller . Signed-off-by: Simon Glass --- Changes in v2: None arch/x86/cpu/ivybridge/sata.c | 2 +- drivers/ata/ahci.c

[U-Boot] [PATCH v2 00/15] dm: sata: mmc: Convert a sunxi board to driver model for MMC, SATA

2017-07-04 Thread Simon Glass
At present SCSI support for driver model works only with PCI controllers. This series makes the following changes: - Adjusts SATA/AHCI support to work with non-PCI controllers - Allows driver model to be used for MMC in U-Boot proper without requiring it to be used in SPL - Adjusts sunxi MMC and

[U-Boot] [BUG] checkpatch: false positive storage class location

2017-07-04 Thread Heinrich Schuchardt
The U-Boot project uses the same scripts/checkpatch.pl as the Linux kernel. I ran upon the problem below when working on U-Boot. But I guess it should be fixed in the Linux upstream. Running checkpatch for this email produces WARNING: storage class should be at the beginning of the declaration

[U-Boot] Board file for Raspberry Pi, rpi.c and Setting MAC address

2017-07-04 Thread Duncan Hare
The code is: if(!getenv("ethaddr")) setenv("ethaddr",getenv("usbethaddr")); which if I read it correctly says, if the MAC address variable is not set, set from the board's mac address. If an environment is copies from one device to a second, this code prevents populating u-boot in the new

[U-Boot] [PATCH v2 10/10] gpt: harden set_gpt_info() against non NULL-terminated strings

2017-07-04 Thread alison
From: Alison Chaiken Strings read from devices may sometimes fail to be NULL-terminated. The functions in lib/string.c are subject to failure in this case. Protect against observed failures in set_gpt_info() by switching to length-checking variants with a length

[U-Boot] [PATCH v8 09/10] GPT: provide commands to selectively rename partitions

2017-07-04 Thread alison
From: Alison Chaiken This patch provides support in u-boot for renaming GPT partitions. The renaming is accomplished via new 'gpt swap' and 'gpt rename' commands. The 'swap' mode returns an error if no matching partition names are found, or if the number of partitions

[U-Boot] [PATCH v8 08/10] GPT: read partition table from device into a data structure

2017-07-04 Thread alison
From: Alison Chaiken Make the partition table available for modification by reading it from the user-specified device into a linked list. Provide an accessor function for command-line testing. Signed-off-by: Alison Chaiken --- cmd/gpt.c

Re: [U-Boot] [U-Boot, 07/13] rockchip: rk3066: add mk808 board files

2017-07-04 Thread Philipp Tomsich
> mk808 is a tv stick with two usb ports, micro sd card slot, hdmi and > nand onboard. > > Signed-off-by: Paweł Jarosz > Acked-by: Simon Glass > Acked-by: Philipp Tomsich > --- > arch/arm/dts/Makefile

Re: [U-Boot] [U-Boot, 05/13] rockchip: rk3066: add rk3066 platform devicetree file

2017-07-04 Thread Philipp Tomsich
> rk3066 peripherials include usb, i2c, pwm, gpio, sdio, sdmmc, emmc, spi, > watchdog and uart > > Signed-off-by: Paweł Jarosz > Reviewed-by: Simon Glass > Acked-by: Philipp Tomsich > --- >

Re: [U-Boot] [U-Boot,03/13] rockchip: rk3066: add sysreset driver

2017-07-04 Thread Philipp Tomsich
Looks like we're ending up with a lot of sysreset_rk3***.o drivers here that all have more or less the same logic in them. This one looks like a verbatim copy of the RK3188 one... Can we start deduplicating this and have rk3188/rk3066_sysreset_request as a common function that is

Re: [U-Boot] [U-Boot,06/13] rockchip: rk3066: add core support

2017-07-04 Thread Philipp Tomsich
On Tue, 6 Jun 2017, Paweł Jarosz wrote: Add core skeleton for rk3066 Signed-off-by: Paweł Jarosz Acked-by: Philipp Tomsich --- arch/arm/mach-rockchip/Kconfig| 16 +++ arch/arm/mach-rockchip/Makefile

[U-Boot] [PATCH 4/4] arm: mvebu: clearfog: fix chip name comment

2017-07-04 Thread Baruch Siach
The clearfog uses Armada 388. Cc: Stefan Roese Signed-off-by: Baruch Siach --- board/solidrun/clearfog/kwbimage.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/board/solidrun/clearfog/kwbimage.cfg b/board/solidrun/clearfog/kwbimage.cfg

  1   2   >