Re: [U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread Albert ARIBAUD
Hello Vladimir, On Sat, 18 Jul 2015 02:10:01 +0300, Vladimir Zapolskiy wrote: > Hi Sylvain, Albert, > > On 18.07.2015 01:24, LEMIEUX, SYLVAIN wrote: > > Hi Albert, > > > > Thanks for the feedback. > > > >> From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Albert > >> ARIBAUD > >

Re: [U-Boot] [PATCH 3/3] usb: lpc32xx: add host USB driver

2015-07-17 Thread Marek Vasut
On Saturday, July 18, 2015 at 12:52:58 AM, LEMIEUX, SYLVAIN wrote: > Hi Mark, Hi! > Thanks for the feedback; > > > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Marek > > Vasut Sent: 17-Jul-15 6:09 PM > > > > On Friday, July 17, 2015 at 10:48:54 PM, slemieux.t...@gmail.com wro

Re: [U-Boot] U-Boot porting on Android Emulator

2015-07-17 Thread Simon Glass
Hi Roger, On 17 July 2015 at 15:40, Albert ARIBAUD wrote: > > Hello Roger, > > On Fri, 17 Jul 2015 14:51:52 +0800, Roger wrote: > > > > Hi, > > I ported U-Boot to Android emulator (ARM). Do you think this should be > > supported in U-Boot mainline ? > > This is for you to decide if you want to

[U-Boot] [PATCH v4 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Vladimir Zapolskiy
The change adds support of LPC32xx SLC NAND controller. LPC32xx SoC has two different mutually exclusive NAND controllers to communicate with single and multiple layer chips. This simple driver allows to specify NAND chip timings and defines custom read_buf()/write_buf() operations, because acces

Re: [U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Vladimir Zapolskiy
On 18.07.2015 02:53, Scott Wood wrote: > On Sat, 2015-07-18 at 02:38 +0300, Vladimir Zapolskiy wrote: >> Hello Scott, >> >> On 18.07.2015 02:12, Scott Wood wrote: >>> On Sat, 2015-07-18 at 01:47 +0300, Vladimir Zapolskiy wrote: +/* + * LPC32xx has only one SLC NAND controller, don't utili

Re: [U-Boot] [PATCH v2 13/14] dm: remove redundant CONFIG_DM from driver/core/Makefile

2015-07-17 Thread Simon Glass
On 15 July 2015 at 18:59, Simon Glass wrote: > On 12 July 2015 at 22:17, Masahiro Yamada > wrote: >> >> As you see in driver/Makefile, Kbuild descends into the driver/core/ >> directory only when CONFIG_DM is enabled. >> >> Signed-off-by: Masahiro Yamada >> --- >> >> Changes in v2: >> - Newly

Re: [U-Boot] [PATCH] dm: change dm_warn() message into debug() in uclass_add()

2015-07-17 Thread Simon Glass
On 7 July 2015 at 07:48, Simon Glass wrote: > On 7 July 2015 at 03:51, Masahiro Yamada > wrote: >> The command "dm uclass" tries to display all the UClasses, but >> some of them might be disabled by Kconfig. >> >> The function do_dm_dump_uclass() iterates over all the UClass IDs >> and calls ucl

Re: [U-Boot] [PATCH] dm: do not set DM_FLAG_ACTIVATED twice

2015-07-17 Thread Simon Glass
On 9 July 2015 at 07:31, Simon Glass wrote: > On 9 July 2015 at 07:11, Masahiro Yamada > wrote: >> Currently, DM_FLAG_ACTIVATED is set twice; before calling >> uclass_pre_probe_device() and again before calling drv->probe(). >> >> It looks like Simon's intention is the first one. >> The DM_FLAG_

Re: [U-Boot] [PATCH 18/18] test: Add a test for regmap

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > We use syscon to test that the regmap functions work as expected. > > Signed-off-by: Simon Glass > --- > > test/dm/Makefile | 1 + > test/dm/regmap.c | 82 > > 2 files changed, 83 insertions(

Re: [U-Boot] [PATCH 12/18] led: Return -ENODEV if the LED device cannot be found

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > We normally use -ENODEV for a missing device, rather than -ENOENT. The > latter is reserved for when we have a device but cannot find something > within it. > > Also avoid looking at the root LED device since it is only a container. > > Signed-off-by:

Re: [U-Boot] [PATCH 13/18] dm: test: Add a test for the LED uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add a test to confirm that we can adjust LEDs using the led_gpio driver. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 14 + > configs/sandbox_defconfig | 2 ++ > drivers/led/led_gpio.c| 6 > test/dm/Makefile

Re: [U-Boot] [PATCH 16/18] test: Add a macro to check that a value is not an error pointer

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Some functions can return ERR_PTR(errval). Add a unit test macro to check > that no error is returned in a pointer. > > Signed-off-by: Simon Glass > --- > > include/test/ut.h | 15 +++ > 1 file changed, 15 insertions(+) Applied to u-boot

Re: [U-Boot] [PATCH 11/18] dm: test: Add a test for the mmc uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add a test to confirm that we can probe this device. Since there is no > MMC stack support in sandbox at present, this is as far as the test goes. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 4 > configs/sandbox_defconf

Re: [U-Boot] [PATCH 17/18] dm: core: Add device checking to syscon_get_regmap()

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > This function can only handle a syscon device. It is possible that someone > will make a mistake, so add a check for this. > > Also we should return -ENODEV when a device cannot be found, so update the > syscon_get_regmap_by_driver_data() to follow thi

Re: [U-Boot] [PATCH 15/18] dm: test: Add a size to each reg property

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Each sandbox peripheral should have a size as well as a base address. This > is required for regmaps to work, so make this change for all nodes that have > an address. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 27 ++

Re: [U-Boot] [PATCH 10/18] dm: test: Add a test for the ram uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add a test to confirm that we can probe this device and get information on > the available RAM. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 4 > configs/sandbox_defconfig | 1 + > drivers/ram/Makefile | 1 + > dr

Re: [U-Boot] [PATCH 09/18] dm: test: Add a test for the reset uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add tests that confirm that the drivers work as expected, and we can walk > through the available reset types trying to reset the board. > > Signed-off-by: Simon Glass > --- > > test/dm/Makefile | 1 + > test/dm/reset.c | 74 >

Re: [U-Boot] [PATCH 08/18] sandbox: Use the reset driver to handle reset

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Move sandbox over to use the reset uclass for reset, instead of a direct > call to do_reset(). This allows us to add tests. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/cpu/cpu.c| 9 + > arch/sandbox/dts/test.dts

Re: [U-Boot] [PATCH 05/18] sandbox: Support multiple reset types

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add settings for the last reset generated, and the types of resets which > are permitted. This will be used for testing. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/cpu/state.c | 4 > arch/sandbox/include/asm/state.h | 3 +++ >

Re: [U-Boot] [PATCH 07/18] sandbox: Add a warm and cold reset driver

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add drivers for sandbox. One can only perform a warm reset (which does > nothing). The other can perform a cold reset or a power reset (the > latter will quit U-Boot). These can be used for testing the reset uclass. > > Signed-off-by: Simon Glass > --

Re: [U-Boot] [PATCH 06/18] dm: reset: Allow reset_walk() to return

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add a new reset_walk_halt() function to cause a reset and then halt on > failure. The reset_walk() function returns an error code. > > This is needed for testing since otherwise U-Boot will halt in the middle > of a test. > > Signed-off-by: Simon Glass

Re: [U-Boot] [PATCH v3 39/54] dm: pmic: Add functions to adjust PMIC registers

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:39 PM, Simon Glass wrote: >> >> It is a common requirement to update some PMIC registers. Provide some >> simple convenience functions to do this. >> >> Signed-off-by: Simon Glass >> >> --- >> >> Changes in v3:

Re: [U-Boot] [PATCH 03/18] dm: test: Add tests for the clk uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add tests of each API call using a sandbox clock device. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 4 ++ > arch/sandbox/include/asm/test.h | 11 ++ > configs/sandbox_defconfig | 1 + > drivers/clk/Makefile

Re: [U-Boot] [PATCH 04/18] dm: test: Add tests for the pinctrl uclass

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > Add tests of each API call using a sandbox pinctrl device. > > Signed-off-by: Simon Glass > --- > > arch/sandbox/dts/test.dts | 11 - > configs/sandbox_defconfig | 1 + > drivers/pinctrl/Makefile| 1 +

Re: [U-Boot] [PATCH 02/18] dm: test: Allow test names to leave out the dm_test_ prefix

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > All driver model tests have a dm_test_ prefix. Ignore it when matching a > test name. This makes it easier to run individual tests, like this: > >./sandbox/u-boot -d ./sandbox/arch/sandbox/dts/test.dtb \ > -c "ut dm clk_periph" > > We can u

Re: [U-Boot] [PATCH 01/18] dm: Add platform data advice and admonishment

2015-07-17 Thread Simon Glass
On 6 July 2015 at 12:54, Simon Glass wrote: > > We should guide people more strongly towards device tree to avoid the > proliferation of platform data structures. Add documentation to the driver > model README, and also the platform data header file. > > Signed-off-by: Simon Glass > --- > > doc/

Re: [U-Boot] [PATCH v3 52/54] zynq: Rename struct clk_ops to zynq_clk_ops

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Since we want clk_ops to be used in U-Boot as a whole, rename the Zynq > version until it can be converted to driver model. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > arch/arm/mach-zynq/clk.c | 6 +++--- >

Re: [U-Boot] [PATCH v3 54/54] power: pmic: Use trailing_strtol() instead of a local function

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:39 PM, Simon Glass wrote: >> >> Use the common function to obtain the number from the end of the string, >> instead of a local function. Also tweak the position of a debug() >> statement. >> >> Signed-off-by: Si

Re: [U-Boot] [PATCH v3 53/54] dm: Add a clock uclass

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Clocks are an important feature of platforms and have become increasing > complex with time. Most modern SoCs have multiple PLLs and dozens of clock > dividers which distribute clocks to on-chip peripherals. > > Some SoC implementations have a clock A

Re: [U-Boot] [PATCH v3 51/54] dm: Add a system reset uclass

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > It is common for system reset to be available at multiple levels in modern > hardware. For example, an SoC may provide a reset option, and a board may > provide its own reset for reasons of security or thoroughness. It is useful > to be able to model

Re: [U-Boot] [PATCH v3 49/54] spl: Add a debug string before the jump to U-Boot

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > As a debug option, add positive confirmation that SPL has completed > execution. This can help with diagnosing the location of unexpected hangs. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > common/spl/spl.c

Re: [U-Boot] [PATCH v3 48/54] dm: spl: Allow device tree/driver model in board_init_f()

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Add an spl_init() function that does basic init such that board_init_f() can > use simple malloc(), device tree and driver model. Each one is set up only > if enabled for SPL. > > Note: We really should refactor SPL such that there is a single > board

Re: [U-Boot] [PATCH v3 50/54] mkimage: Set up a file size parameter and keep it updated

2015-07-17 Thread Simon Glass
On 25 June 2015 at 16:51, Joe Hershberger wrote: > Hi Simon, > > On Tue, Jun 23, 2015 at 4:39 PM, Simon Glass wrote: >> Some functions called by mkimage would like to know the output file size. >> Initially this is the same as the input file size, but it may be affected by >> adding headers, etc.

Re: [U-Boot] [PATCH v3 41/54] Drop CONFIG_ERRNO_STR from SPL

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > This bloats the code size quite a bit and is less useful in SPL where there > is no command line. > > Avoid including this code in SPL. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > lib/Makefile | 2 +- > 1 f

Re: [U-Boot] [PATCH v3 46/54] lib: Add function to extract a number from the end of a string

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Split out the code in fdtdec which finds a number at the end of a string. It > can be useful in other situations. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > include/vsprintf.h | 26

Re: [U-Boot] [PATCH v3 43/54] dm: spi: Make local functions static

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Several functions in this file should be marked as static. Update them. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/spi/spi-uclass.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-)

Re: [U-Boot] [PATCH v3 45/54] Add rivest cipher 4 (rc4) implementation

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Add an implementation of RC4. This will be used by Rockchip booting but may > be useful in other situations. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > include/rc4.h | 21 + > lib/Makef

Re: [U-Boot] [PATCH v3 47/54] fdt: Provide debug info when a device tree cannot be found

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > It can be quite confusing with a new platform to figure out why the device > tree cannot be located. Add some debug information for this case. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > lib/fdtdec.c | 7 ++

Re: [U-Boot] [PATCH v3 44/54] ns16550: Improve debug UART so it can work with 32-bit access

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Since Rockchip requires 32-bit serial access, add this to the driver. > Refactor a little to make this easier. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/serial/ns16550.c | 36 +

Re: [U-Boot] [PATCH v3 42/54] dm: Add support for RAM drivers

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > Add support for a driver which sets up DRAM and can return information about > the amount of RAM available. This is a first step towards moving RAM init > to driver model. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2:

Re: [U-Boot] [PATCH v3 36/54] dm: pmic: Split output from function

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:38 PM, Simon Glass wrote: >> >> The regulator_autoset() function mixes printf() output and PMIC adjustment >> code. It provides a boolean to control the output. It is better to avoid >> missing logic and output,

Re: [U-Boot] [PATCH v3 40/54] dm: power: Allow use of regulators in SPL

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:39, Simon Glass wrote: > his functionality may be useful for setting up regulators early during > boot. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > scripts/Makefile.spl | 1 + > 1 file changed, 1 insertion(+) Applied to u-boot-dm.

Re: [U-Boot] [PATCH v3 34/54] dm: power: Avoid case-insensitve match for child names

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello, > > On 06/23/2015 11:38 PM, Simon Glass wrote: >> >> This is not user input (i.e. from the command line). It should be possible >> to get the case correct and avoid the case-insensitive match. This will >> help avoid sloppy device tree se

Re: [U-Boot] [PATCH v3 38/54] dm: power: Use debug() for errors in regulator uclass

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:39 PM, Simon Glass wrote: >> >> To reduce unnecessary code size in an uncommon code path, use debug() >> where possible(). The driver returns an error which indicates failure. >> >> Signed-off-by: Simon Glass >

Re: [U-Boot] [PATCH v3 35/54] dm: power: Add regulator flags to centralise auto-set logic

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:38 PM, Simon Glass wrote: >> >> Decide when the regulator is set up whether we want to auto-set the >> voltage >> or current. This avoids the complex logic spilling into the processing >> code. >> >> Signed-off-

Re: [U-Boot] [PATCH v3 37/54] dm: power: Add a function to set up all regulators

2015-07-17 Thread Simon Glass
On 1 July 2015 at 03:44, Przemyslaw Marczak wrote: > Hello Simon, > > On 06/23/2015 11:38 PM, Simon Glass wrote: >> >> The device tree provides information about which regulators should be >> on at boot, or always on. Use this to set them up automatically. >> >> Signed-off-by: Simon Glass >> >> -

Re: [U-Boot] [PATCH v3 30/54] mmc: Add structure comments for dwmmc

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > It took a little while to figure this out, so this patch adds documentation > to help the next person who needs to do this. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > include/dwmmc.h | 18 +

Re: [U-Boot] [PATCH v3 29/54] dm: mmc: Allow driver model to be used for MMC in SPL

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Enable MMC using driver model in SPL for consistency with U-Boot proper. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > common/spl/spl_mmc.c | 17 +++-- > 1 file changed, 15 insertions(+), 2 deleti

Re: [U-Boot] [PATCH v3 28/54] mmc: Add debug() output on read errors

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Allow read errors to be diagnosed more easily. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/mmc/mmc.c | 8 ++-- > 1 file changed, 6 insertions(+), 2 deletions(-) Applied to u-boot-dm. __

Re: [U-Boot] [PATCH v3 26/54] dm: mmc: Add an MMC uclass

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Add basic support for MMC, providing a uclass which can set up an MMC > device. This allows MMC drivers to move to using driver model. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/mmc/Kconfig |

Re: [U-Boot] [PATCH v3 23/54] dm: Add support for LEDs

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Add a simple uclass for LEDs, so that these can be controlled by the device > tree and activated when needed. LEDs are referred to by their label. > > This implementation requires a driver for each type of LED (e.g GPIO, I2C). > > Signed-off-by: Simon

Re: [U-Boot] [PATCH v3 24/54] dm: led: Add a driver for GPIO-controlled LEDs

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Add a simple driver which allows use of LEDs attached to GPIOs. The linux > device tree binding is used. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > doc/device-tree-bindings/leds/leds-gpio.txt | 52 +++

Re: [U-Boot] [PATCH v3 25/54] spl: Add debugging info for spl_mmc boot

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Add a few messages to indicate progress and failure. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > common/spl/spl_mmc.c | 9 +++-- > 1 file changed, 7 insertions(+), 2 deletions(-) Applied to u-boot-dm.

Re: [U-Boot] [PATCH v3 21/54] dm: Add support for generic system controllers (syscon)

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Many SoCs have a number of system controllers which are dealt with as a > group by a single driver. It is a pain to have to add lots of compatible > strings and/or separate drivers for each. Instead we can identify the > controllers by a number and re

Re: [U-Boot] [PATCH v3 18/54] dm: gpio: Add dm_gpio_lookup_name() to look up a GPIO name

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Provide a driver-model function to look up a GPIO name. Make the standard > function use it. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/gpio/gpio-uclass.c | 34 ++ >

Re: [U-Boot] [PATCH v3 16/54] dm: core: Correct device_get_child_by_of_offset() parameter

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > This parameter is named 'seq' but should be named 'of_offset'. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/core/device.c | 4 ++-- > include/dm/device.h | 2 +- > 2 files changed, 3 insertions(+),

Re: [U-Boot] [PATCH v3 20/54] dm: Add support for register maps (regmap)

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Add a simple implementaton of register maps, supporting only direct I/O > for now. This can be enhanced later to support buses which have registers, > such as I2C, SPI and PCI. > > It allows drivers which can operate with multiple buses to avoid deali

Re: [U-Boot] [PATCH v3 19/54] dm: gpio: Add dm_gpio_request() to manually request a GPIO

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > This function can be used for testing to manually request a GPIO for use, > without resorting to the legacy GPIO API. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/gpio/gpio-uclass.c | 2 +- > includ

Re: [U-Boot] [PATCH v3 17/54] dm: gpio: Allow GPIO uclass to be used in SPL

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Now that we support driver model in SPL, allow GPIO drivers to be used there > also. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > drivers/gpio/Makefile | 4 > 1 file changed, 4 deletions(-) Applied to

Re: [U-Boot] [PATCH v3 14/54] dm: core: Use debug() instead of printf() for failures

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > To avoid bloating SPL code, use debug() where possible in the driver model > core code. The error code is already returned, and can be investigated as > needed. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > d

Re: [U-Boot] [PATCH v3 13/54] dm: Move the tree/uclass dump code into its own file

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > In SPL it is sometimes useful to be able to obtain a dump of the current > driver model state. Since commands are not available, provide a way to > directly call the functions to output this information. > > Adjust the existing commands to use these f

Re: [U-Boot] [PATCH v3 15/54] dm: core: Add a function to find any device from device tree

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > In some rare cases it is useful to be able to locate a device given a device > tree node offset. An example is when you have an alias that points to a node > and you want to find the associated device. The device may be SPI, MMC or > something else, b

Re: [U-Boot] [PATCH v3 09/54] Add a way of checking the position of a structure member

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > U-Boot uses structures for hardware access so it is important that these > structures are correct. Add a way of asserting that a structure member is > at a particular offset. This can be created using the datasheet for the > hardware. > > This impleme

Re: [U-Boot] [PATCH v3 07/54] dm: Reduce SPL device tree size

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > The SPL device tree size must be minimised to save memory. Only include > properties that are needed by SPL - this is determined by the presence > of the "u-boot,dm-pre-reloc" property. Also remove a predefined list of > unused properties from the nod

Re: [U-Boot] [PATCH v3 12/54] sandbox: Drop special-case sandbox console code

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > At present printf() skips output if it can see there is no console. This > is really just an optimisation, and is not necessary. Also it is currently > incorrect in some cases. Rather than update the logic, just remove it so > that we don't need to ke

Re: [U-Boot] [PATCH v3 11/54] dm: Allow debug UART to support an early console

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > When there is no console ready, allow the debug UART to be used for output. > This makes debugging of early code considerably easier. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > common/console.c | 19 ++

Re: [U-Boot] [PATCH v3 08/54] dm: arm: Put driver model I2C drivers before legacy ones

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Driver-model I2C drivers can be picked up by the linker script rule for > legacy drivers. Change the order to avoid this. > > We could make the legacy code depend on !CONFIG_DM_I2C but that is not > necessary and it is good to keep conditions to a min

Re: [U-Boot] [PATCH v3 10/54] debug_uart: Remove use of asmlinkage

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > This does not actually help any current arch. For x86 it makes it harder > to call (requires stack) and for ARM it has no effect. Drop it. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > include/debug_uart.h |

Re: [U-Boot] [PATCH v3 06/54] fdt: Add fdtgrep tool

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > This tool allows us to extract subsets of a device tree file. It is used by > the SPL vuild, which needs to cut down the device tree size for use in > limited memory. > > This tool was originally written for libfdt but it has not been accepted > upstr

Re: [U-Boot] [PATCH v3 05/54] fdt: Add fdt_first/next_region() functions

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > These have been sent upstream but not accepted to libfdt. For now, bring > these into U-Boot to enable fdtgrep to operate. We will use fdtgrep to > cut device tree files down for SPL. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Cha

Re: [U-Boot] [PATCH v3 04/54] fdt: Add a function to remove unused strings from a device tree

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Property names are stored in a string table. When a node property is > removed, the string table is not updated since other nodes may have a > property with the same name. > > Thus it is possible for the string table to build up a number of unused > s

Re: [U-Boot] [PATCH v3 03/54] mkimage: Display a better list of available image types

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Offer to display the available image types in help. Also, rather than > hacking the genimg_get_type_id() function to display a list of types, > do this in the tool. Also, sort the list. > > The list of image types is quite long, and hard to discover.

Re: [U-Boot] [PATCH v3 01/54] Add a dhrystone benchmark command

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > > Drystone provides a convenient sanity check that the CPU is running at full > speed. Add this as a command which can be enabled as needed. > > Note: I investigated using Coremark for this but there was a license > agreement and I could not work out

Re: [U-Boot] [PATCH v3 02/54] sandbox: Enable dhry command

2015-07-17 Thread Simon Glass
On 23 June 2015 at 15:38, Simon Glass wrote: > Provide access to the dhrystone benchmark command. > > Signed-off-by: Simon Glass > --- > > Changes in v3: None > Changes in v2: None > > configs/sandbox_defconfig | 1 + > 1 file changed, 1 insertion(+) Applied to u-boot-dm. __

Re: [U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Scott Wood
On Fri, 2015-07-17 at 18:53 -0500, Scott Wood wrote: > On Sat, 2015-07-18 at 02:38 +0300, Vladimir Zapolskiy wrote: > > Hello Scott, > > > > On 18.07.2015 02:12, Scott Wood wrote: > > > On Sat, 2015-07-18 at 01:47 +0300, Vladimir Zapolskiy wrote: > > > > +/* > > > > + * LPC32xx has only one SLC NA

Re: [U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Scott Wood
On Sat, 2015-07-18 at 02:38 +0300, Vladimir Zapolskiy wrote: > Hello Scott, > > On 18.07.2015 02:12, Scott Wood wrote: > > On Sat, 2015-07-18 at 01:47 +0300, Vladimir Zapolskiy wrote: > > > +/* > > > + * LPC32xx has only one SLC NAND controller, don't utilize > > > + * CONFIG_SYS_NAND_SELF_INIT to

[U-Boot] [PATCH v3 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Vladimir Zapolskiy
The change adds support of LPC32xx SLC NAND controller. LPC32xx SoC has two different mutually exclusive NAND controllers to communicate with single and multiple layer chips. This simple driver allows to specify NAND chip timings and defines custom read_buf()/write_buf() operations, because acces

Re: [U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread LEMIEUX, SYLVAIN
Hi Vladimir, > From: Vladimir Zapolskiy [mailto:v...@mleia.com] > Sent: 17-Jul-15 7:10 PM > > Hi Sylvain, Albert, > > On 18.07.2015 01:24, LEMIEUX, SYLVAIN wrote: > > Hi Albert, > > > > Thanks for the feedback. > > > >> From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Albert > >> A

Re: [U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Vladimir Zapolskiy
Hello Scott, On 18.07.2015 02:12, Scott Wood wrote: > On Sat, 2015-07-18 at 01:47 +0300, Vladimir Zapolskiy wrote: >> +/* TAC register bits, be aware of overflows */ >> +#define TAC_W_RDY(n) (max_t(uint32_t, (n), 0xF) << 28) >> +#define TAC_W_WIDTH(n) (max_t(uint32_t, (n), 0x

Re: [U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Scott Wood
On Sat, 2015-07-18 at 01:47 +0300, Vladimir Zapolskiy wrote: > +/* TAC register bits, be aware of overflows */ > +#define TAC_W_RDY(n) (max_t(uint32_t, (n), 0xF) << 28) > +#define TAC_W_WIDTH(n) (max_t(uint32_t, (n), 0xF) << 24) > +#define TAC_W_HOLD(n)(max_t(u

Re: [U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread Vladimir Zapolskiy
Hi Sylvain, Albert, On 18.07.2015 01:24, LEMIEUX, SYLVAIN wrote: > Hi Albert, > > Thanks for the feedback. > >> From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Albert >> ARIBAUD >> Sent: 17-Jul-15 5:20 PM >> >> Hello Sylvain, >> >> On Fri, 17 Jul 2015 16:48:52 -0400, slemieux.t.

Re: [U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread Scott Wood
On Fri, 2015-07-17 at 22:24 +, LEMIEUX, SYLVAIN wrote: > Hi Albert, > > Thanks for the feedback. > > > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Albert > > ARIBAUD > > Sent: 17-Jul-15 5:20 PM > > > > Hello Sylvain, > > > > On Fri, 17 Jul 2015 16:48:52 -0400, slemieux.

Re: [U-Boot] [PATCH 3/3] usb: lpc32xx: add host USB driver

2015-07-17 Thread LEMIEUX, SYLVAIN
Hi Mark, Thanks for the feedback; > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Marek Vasut > Sent: 17-Jul-15 6:09 PM > > On Friday, July 17, 2015 at 10:48:54 PM, slemieux.t...@gmail.com wrote: > > From: Sylvain Lemieux > > Hi! > > > Incorporate DMA driver from legacy LPCLinu

[U-Boot] [PATCH v2 2/4] nand: lpc32xx: add SLC NAND controller support

2015-07-17 Thread Vladimir Zapolskiy
The change adds support of LPC32xx SLC NAND controller. LPC32xx SoC has two different mutually exclusive NAND controllers to communicate with single and multiple layer chips. This simple driver allows to specify NAND chip timings and defines custom read_buf()/write_buf() operations, because acces

[U-Boot] [PATCH v2 4/4] lpc32xx: devkit3250: add spl build support

2015-07-17 Thread Vladimir Zapolskiy
The change adds SPL build support to Timll DevKit3250 board, the generated SPL image can be uploaded over UART5, JTAG or stored on NAND. SPL is designed to load U-boot image from NAND. All new NAND chip defines in board configuration are needed by SPL NAND "simple" framework, the framework is used

[U-Boot] [PATCH v2 1/4] spl: nand: simple: replace readb() with chip specific read_buf()

2015-07-17 Thread Vladimir Zapolskiy
Some NAND controllers define custom functions to read data out, respect this in order to correctly support bad block handling in simple SPL NAND framework. NAND controller specific read_buf() is used even to read 1 byte in case of connected 8-bit NAND device, it turns out that read_byte() may beco

[U-Boot] [PATCH v2 3/4] lpc32xx: devkit3250: update of board configuration

2015-07-17 Thread Vladimir Zapolskiy
This change adds more peripherals to Timll DevKit3250 board, namely MAC and SMSC phy, SLC NAND, GPIO, SPI and I2C. Also the default serial console is changed to UART5, added an option to pass device tree blob by means of bootm, predefined environment variables are slightly extended and reserved sp

[U-Boot] [PATCH v2 0/4] lpc32xx: devkit3250 board update

2015-07-17 Thread Vladimir Zapolskiy
This changeset improves support of Timll DevKit3250 board: * added LPC32xx MAC and SMSC RMII phy support, this dependends on - http://patchwork.ozlabs.org/patch/489100/ - http://patchwork.ozlabs.org/patch/489190/ - http://patchwork.ozlabs.org/patch/491419/ - http://patchwork.ozlabs.org/patc

Re: [U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread LEMIEUX, SYLVAIN
Hi Albert, Thanks for the feedback. > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of Albert ARIBAUD > Sent: 17-Jul-15 5:20 PM > > Hello Sylvain, > > On Fri, 17 Jul 2015 16:48:52 -0400, slemieux.t...@gmail.com > wrote: > > > 1) Fixed checkpatch script output in legacy code. > >

Re: [U-Boot] [PATCH 3/3] usb: lpc32xx: add host USB driver

2015-07-17 Thread Marek Vasut
On Friday, July 17, 2015 at 10:48:54 PM, slemieux.t...@gmail.com wrote: > From: Sylvain Lemieux Hi! > Incorporate DMA driver from legacy LPCLinux NXP BSP. > The files taken from the legacy patch are: > - lpc32xx USB driver > - lpc3250 header file USB registers definition. > > Updated driver to

Re: [U-Boot] [PATCH 0/3] lpc32xx: add legacy NXP BSP drivers

2015-07-17 Thread Marek Vasut
On Friday, July 17, 2015 at 10:48:51 PM, slemieux.t...@gmail.com wrote: > From: Sylvain Lemieux > > This series of patches bring the legacy NXP LPC32xx BSP > drivers (SLC NAND, DMA & USB) into the latest u-boot. > > Refer to each individual patches for details on the change done to > integrate t

Re: [U-Boot] U-Boot porting on Android Emulator

2015-07-17 Thread Albert ARIBAUD
Hello Roger, On Fri, 17 Jul 2015 14:51:52 +0800, Roger wrote: > > Hi, > I ported U-Boot to Android emulator (ARM). Do you think this should be > supported in U-Boot mainline ? This is for you to decide if you want to automatically benefit from future bugfixes and enhancements added to U-Boot,

Re: [U-Boot] [PATCHv4 0/3] drivers/ddr/altera: Add the DDR controller driver for SoCFPGA

2015-07-17 Thread Dinh Nguyen
On 07/12/2015 02:50 PM, Marek Vasut wrote: > On Friday, June 26, 2015 at 10:01:47 PM, Marek Vasut wrote: >> On Friday, June 26, 2015 at 06:43:13 PM, Marek Vasut wrote: >>> On Wednesday, June 03, 2015 at 05:52:47 AM, >>> dingu...@opensource.altera.com >>> >>> wrote: From: Dinh Nguyen

[U-Boot] [PATCH v5 0/5] Add support for Thumb-1 builds

2015-07-17 Thread Albert ARIBAUD
This series implements essential changes for thumb-1 support and activates thumb-1 build for openrd and tricorder as a proof of concept as well as a fix to bring the image sizes of openrd and tricorder targets back under an acceptable limit. For other targets, some additional files might need to b

[U-Boot] [PATCH v5 2/5] arm: support Thumb-1 with CONFIG_SYS_THUMB_BUILD

2015-07-17 Thread Albert ARIBAUD
When building a Thumb-1-only target with CONFIG_SYS_THUMB_BUILD, some files fail to build, most of the time because they include mcr instructions, which only exist for Thumb-2. This patch introduces a Kconfig option CONFIG_THUMB2 and uses it to select between Thumb-2 and ARM mode for the aforement

[U-Boot] [PATCH 0/3] lpc32xx: add legacy NXP BSP drivers

2015-07-17 Thread slemieux . tyco
From: Sylvain Lemieux This series of patches bring the legacy NXP LPC32xx BSP drivers (SLC NAND, DMA & USB) into the latest u-boot. Refer to each individual patches for details on the change done to integrate the driver into the latest u-boot. The legacy BSP patch (u-boot-2009.03_lpc32x0-v1.07.

[U-Boot] [PATCH 1/3] nand: lpc32xx: add SLC NAND driver

2015-07-17 Thread slemieux . tyco
From: Sylvain Lemieux Incorporate NAND SLC drivers from legacy LPCLinux NXP BSP. The files taken from the legacy patch are: - lpc32xx SLC NAND driver - lpc3250 header file SLC NAND registers definition. Updated the driver to integrate with the latest u-boot: 1) Fixed checkpatch script output in

[U-Boot] [PATCH 3/3] usb: lpc32xx: add host USB driver

2015-07-17 Thread slemieux . tyco
From: Sylvain Lemieux Incorporate DMA driver from legacy LPCLinux NXP BSP. The files taken from the legacy patch are: - lpc32xx USB driver - lpc3250 header file USB registers definition. Updated driver to integrate with the latest u-boot: 1) Fixed checkpatch script output in legacy code. 2) Use

[U-Boot] [PATCH 2/3] dma: lpc32xx: add DMA driver

2015-07-17 Thread slemieux . tyco
From: Sylvain Lemieux Incorporate DMA driver from legacy LPCLinux NXP BSP. The files taken from the legacy patch are: - lpc32xx DMA driver - lpc3250 header file DMA registers definition. Updated driver to integrate with the latest u-boot: 1) Fixed checkpatch script output in legacy code. 2) Use

Re: [U-Boot] [PATCH 3/4] sunxi: nand: Add a20_nandread command to load image from NAND in SPL

2015-07-17 Thread Piotr Zierhoffer
Hello 2015-07-16 23:20 GMT+02:00 Scott Wood : > On Thu, 2015-07-16 at 13:25 +0200, Piotr Zierhoffer wrote: >> Signed-off-by: Peter Gielda >> Signed-off-by: Tomasz Gorochowik >> Signed-off-by: Mateusz Holenko >> Signed-off-by: Piotr Zierhoffer > > Why does the same code now have a completely di

  1   2   >