[U-Boot] tps65910x I2C RTC driver

2014-10-19 Thread Dvorkin Dmitry
Hello! We are developing new board based on TI am33xx. (I'll send patch for this new board later.) It have not internal RTC and we're using the one from TPS65910 connected by I2C bus. May I add this patch to U-Boot source? Thank you. diff -urN ./drivers/rtc/Makefile ./drivers/rtc/Makefile ---

Re: [U-Boot] compile issue with U-boot-2014.10-rc2 & Cubieboard

2014-10-19 Thread Jeroen Hofstee
Hello Tom, On 01-10-14 17:31, Jeroen Hofstee wrote: On 30-09-14 03:29, Tom Everett wrote: I am getting this compile error: scripts/Makefile.build:55: /tank/home/tom/freebsd/uboot/u-boot-2014.10-rc2/board/amd/sunxi/Makefile: No such file or directory gmake[1]: *** No rule to make target `/

[U-Boot] [PATCH] generic-board: make compile-time noise for non-generic boards

2014-10-19 Thread Masahiro Yamada
Commit 0f605c1501f6 (Start the deprecation process for generic board) added a run-time warning message. Let's be noisier for non-generic boards to inform the dead line of the conversion. Signed-off-by: Masahiro Yamada Cc: Tom Rini Cc: Simon Glass --- Makefile | 6 ++ 1 file changed, 6 in

[U-Boot] [PATCH] arm: socfpga: Move code from misc_init_r() to arch_early_init_r()

2014-10-19 Thread Marek Vasut
Move this initialization code to proper place. The misc_init_r() function is called way too late and the platform initialization code should be executed much earlier. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Vince Bridgers Cc: Albert Aribaud Cc: Pavel Machek --- arc

[U-Boot] [PATCH 2/7] spi: altera: Clean up bit definitions

2014-10-19 Thread Marek Vasut
Clean up the definitions of bits in the Altera SPI driver, there is no need to put braces around numbers afterall. No functional change. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Albert Aribaud Cc: Tom Rini Cc: Wolfgang Denk Cc: Pavel Machek Cc: Jagannadha Sutradharu

[U-Boot] [PATCH] usb: dwc2: Add driver for Synopsis DWC2 USB IP block

2014-10-19 Thread Marek Vasut
From: Oleksandr Tymoshenko This is the USB host controller used on the Altera SoCFPGA and Raspbery Pi. This code has three checkpatch warnings, but to make sure it stays at least readable and clear, these are not fixed. These bugs are in the USB request handling combinatorial logic, so any abstr

[U-Boot] [PATCH 6/7] spi: altera: Add short note about EPCS/EPCQx1

2014-10-19 Thread Marek Vasut
Add short documentation-alike note on how to use the Altera SPI driver with the EPCS/EPCQx1 FPGA IP block on SoCFPGA Cyclone V. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Albert Aribaud Cc: Tom Rini Cc: Wolfgang Denk Cc: Pavel Machek Cc: Jagannadha Sutradharudu Teki

[U-Boot] [PATCH 3/7] spi: altera: Clean up most checkpatch issues

2014-10-19 Thread Marek Vasut
This patch just zaps most of the checkpatch cries present in the driver. There is one more left, which will be addressed separately. There is no functional change. This patch also adds a bunch of newlines all around the place, this is to make the code much more readable. Signed-off-by: Marek Vasu

[U-Boot] [PATCH 5/7] spi: altera: Clean up the use of variable d

2014-10-19 Thread Marek Vasut
The variable d is used in rather questionable way. Rework the code a bit so it's clearer what it does. Also, rename the variable from d to data to make it's name less mysterious. Finally, change it's data type to uint32_t , since it's accessed as a 32bit number. Signed-off-by: Marek Vasut Cc: Chi

[U-Boot] [PATCH 1/7] spi: altera: Use struct-based register access

2014-10-19 Thread Marek Vasut
Zap the offset-based register access and use the struct-based one as this is the preferred method. No functional change, but there are some line-over-80 problems in the driver, which will be addressed later. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Albert Aribaud Cc:

[U-Boot] [PATCH 7/7] spi: altera: Move the config options to the top

2014-10-19 Thread Marek Vasut
Just move the configuration options scattered all over the driver to the top of the source file. No functional change. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Albert Aribaud Cc: Tom Rini Cc: Wolfgang Denk Cc: Pavel Machek Cc: Jagannadha Sutradharudu Teki --- driv

[U-Boot] [PATCH 4/7] spi: altera: Zap endless loop

2014-10-19 Thread Marek Vasut
The driver contained an endless loop when waiting for TX completion, this is a bad idea since if the hardware fails, the loop might spin forever. Add timeout and handle it. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Albert Aribaud Cc: Tom Rini Cc: Wolfgang Denk Cc: Pav

Re: [U-Boot] [PATCH] generic-board: make compile-time noise for non-generic boards

2014-10-19 Thread Marek Vasut
On Sunday, October 19, 2014 at 07:46:30 PM, Masahiro Yamada wrote: > Commit 0f605c1501f6 (Start the deprecation process for generic board) > added a run-time warning message. Let's be noisier for non-generic > boards to inform the dead line of the conversion. > > Signed-off-by: Masahiro Yamada >

[U-Boot] [PATCH] arm: socfpga: Zap spl.h and ad-hoc related syms

2014-10-19 Thread Marek Vasut
Switch to the common spl.h file and zap the arch/spl.h . Since the arch/spl.h contained various ad-hoc symbols, zap those symbols as well and rework the board configuration a little so it doesn't depend on them. Signed-off-by: Marek Vasut Cc: Chin Liang See Cc: Dinh Nguyen Cc: Vince Bridgers C

Re: [U-Boot] [SoCFPGA] next steps

2014-10-19 Thread Marek Vasut
On Saturday, October 11, 2014 at 08:22:29 PM, Masahiro YAMADA wrote: > Hi Marek, Hello! > 2014-10-07 21:45 GMT+09:00 Marek Vasut : > > Hey, > > > > given that we now have most of the u-boot socfpga stuff in mainline, I > > decided it would be a good idea to list what we're still missing and we >

[U-Boot] [PATCH 3/4] i2c: mxs: Pass the i2c_adapter around

2014-10-19 Thread Marek Vasut
This patch permeates the struct i2c_adapter throughout the driver, so that it can be used to determine which adapter should be used. Note that the driver still supports only one adapter. Note that the patch does shuffle mxs_i2c_set_bus_speed() to the top of the driver, but the function remains unch

[U-Boot] [PATCH 2/4] i2c: mxs: Add basic support for i2c framework

2014-10-19 Thread Marek Vasut
This patch just converts the function prototypes used throughout this driver to match those of the i2c framework. There is so far no functional change. This patch does not do the deeper integration of the framework bits. Signed-off-by: Marek Vasut Cc: Stefano Babic Cc: Heiko Schocher --- drive

[U-Boot] [PATCH 1/4] i2c: mxs: Consolidate hard-coded bus address

2014-10-19 Thread Marek Vasut
This macro is no longer used, so just reap it. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- README | 5 - common/cmd_eeprom.c | 8 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a

[U-Boot] [PATCH 4/4] i2c: mxs: Add support for I2C 1 on i.MX28

2014-10-19 Thread Marek Vasut
Add support for I2C bus 1 on the i.MX28. Signed-off-by: Marek Vasut Cc: Stefano Babic Cc: Heiko Schocher --- drivers/i2c/mxs_i2c.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/i2c/mxs_i2c.c b/drivers/i2c/mxs_i2c.c index d3cb727..87e05c7 100644 --- a/drive

Re: [U-Boot] generic-board: make compile-time noise for non-generic boards

2014-10-19 Thread Vagrant Cascadian
On 2014-10-19, Masahiro Yamada wrote: > Commit 0f605c1501f6 (Start the deprecation process for generic board) > added a run-time warning message. Let's be noisier for non-generic > boards to inform the dead line of the conversion. ... > diff --git a/Makefile b/Makefile > index 99097e1..f439d82 100

[U-Boot] [PATCH 01/25] ppc: Zap ICU862 board

2014-10-19 Thread Marek Vasut
This board is the only user of CONFIG_SYS_EEPROM_X40430 , remove it so the EEPROM command code can be cleansed of the related code as well. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- arch/powerpc/cpu/mpc8xx/Kconfig

[U-Boot] [PATCH 04/25] ppc: Zap HWW1U1A board

2014-10-19 Thread Marek Vasut
This is the only used of CONFIG_SPI_X macro, just zap this. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- arch/powerpc/cpu/mpc85xx/Kconfig| 4 - board/exmeritus/hww1u1a/Kconfig | 12 - board/exmeritus/hww1u1a/

[U-Boot] [PATCH 07/25] ppc: Zap TQM8272 board

2014-10-19 Thread Marek Vasut
This board is old and is using CONFIG_I2C_X, which is wrong. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- arch/powerpc/cpu/mpc8260/Kconfig | 4 - arch/powerpc/cpu/mpc8260/pci.c | 2 - board/tqc/tqm8272/Kconfig

[U-Boot] [RFC][PATCH 00/25] eeprom: Cleanup and support for multiple i2c busses

2014-10-19 Thread Marek Vasut
This patch series first zaps a couple of ancient boards and ugly code which was in the way of proper cleanup for the eeprom command. Once that is done, the eeprom command undergoes proper cleaning. Finally, there is one patch which adds support for selecting on which bus the I2C EEPROM is. This fun

[U-Boot] [PATCH 18/25] eeprom: Suck the ifdef into eeprom_init()

2014-10-19 Thread Marek Vasut
Just suck the ugly ifdef around eeprom_init() call into eeprom_init() function itself. This puts all of the ifdef mess into one place. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(

[U-Boot] [PATCH 08/25] arm: Zap tricorder-eeprom

2014-10-19 Thread Marek Vasut
This is a reimplementation of the cmd_eeprom with the added bit where it can select I2C bus. Just remove this ugly duplication. If someone needs this code, there should be proper implementation submitted. Signed-off-by: Marek Vasut Cc: Andreas Bießmann Cc: Simon Glass Cc: Tom Rini Cc: Heiko Sc

[U-Boot] [PATCH 10/25] eeprom: Zap CONFIG_SYS_I2C_MULTI_EEPROMS

2014-10-19 Thread Marek Vasut
This option only complicates the code unnecessarily, just use CONFIG_SYS_DEF_EEPROM_ADDR as the default address if there are only five arguments to eeprom {read/write} if this is defined. If CONFIG_SYS_DEF_EEPROM_ADDR is not defined, we mandate all six arguments. Signed-off-by: Marek Vasut Cc: Si

[U-Boot] [PATCH 06/25] ppc: Zap TQM8260 board

2014-10-19 Thread Marek Vasut
This board is old and is using CONFIG_I2C_X, which is wrong. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- arch/powerpc/cpu/mpc8260/Kconfig | 4 - board/tqc/tqm8260/Kconfig| 12 - board/tqc/tqm8260/MAINTAINERS

[U-Boot] [PATCH 02/25] ppc: Zap MHPC board

2014-10-19 Thread Marek Vasut
This board uses eeprom accessors in an incorrect way. The board is old and unsupported, just zap it. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- arch/powerpc/cpu/mpc8xx/Kconfig| 4 - arch/powerpc/cpu/mpc8xx/cpu_i

[U-Boot] [PATCH 16/25] eeprom: Make eeprom_write_enable() weak

2014-10-19 Thread Marek Vasut
Make this function weak and implement it's weak implementation so that the boards can just reimplement it. This zaps the horrid CONFIG_SYS_EEPROM_WREN macro. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 18 +- 1 file chan

[U-Boot] [PATCH 20/25] eeprom: Pull out transfer length computation

2014-10-19 Thread Marek Vasut
Pull out the code which computes the length of the transfer into separate code and clean it up a little. This again trims down the code duplication. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 66

[U-Boot] [PATCH 25/25] eeprom: Clean up checkpatch issues

2014-10-19 Thread Marek Vasut
Cosmetic fixes to the file, make it checkpatch clean. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/common/cmd_eeprom.c b/common/cmd_eeprom.c index 3b1

[U-Boot] [PATCH 23/25] eeprom: Add bus argument to eeprom_init()

2014-10-19 Thread Marek Vasut
Add bus argument to eeprom_init(), so that it can select the I2C bus number on which the eeprom resides. Any negative value of the $bus argument will preserve the old behavior. This is in place so that old code does not randomly break. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc:

[U-Boot] [PATCH 22/25] eeprom: Cultivate the ifdef mess

2014-10-19 Thread Marek Vasut
Just squash the ad-hoc ifdef chaos into single #else statement. It's not worth having so many checks in place, since this only leads to complicated code and if the first test for SPI && not env in I2C EEPROM fails, then we're dealing with I2C EEPROM. Signed-off-by: Marek Vasut Cc: Simon Glass Cc

[U-Boot] [PATCH 24/25] eeprom: Add support for selecting i2c bus

2014-10-19 Thread Marek Vasut
Add additional parameter into the eeprom command to select the I2C bus on which the eeprom resides. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/common/cm

[U-Boot] [PATCH 09/25] eeprom: Shuffle code around

2014-10-19 Thread Marek Vasut
Just move the code around so that the forward declarations are not necessary. Also zap a few checkpatch issues where applicable and zap the use of #ifdef CONFIG_CMD_EEPROM in the code, since this is always true. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- co

[U-Boot] [PATCH 17/25] eeprom: Pull out CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS

2014-10-19 Thread Marek Vasut
Pull this macro to the beginning of the cmd_eeprom.c and remove another nasty ifdef from the code. Note that this is legal, since udelay(0) changes the behavior only such that it pings the WDT if WDT is enabled and otherwise does not wait. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini

[U-Boot] [PATCH 12/25] eeprom: Zap eeprom_probe()

2014-10-19 Thread Marek Vasut
Remove this function as it's no longer used. Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- common/cmd_eeprom.c | 19 --- include/common.h| 3 --- 2 files changed, 22 deletions(-) diff --git a/common

[U-Boot] [PATCH 19/25] eeprom: Pull out CONFIG_SYS_EEPROM_PAGE_WRITE_BITS

2014-10-19 Thread Marek Vasut
Implement default value of 8 for this macro and pull out all of this macro out of the code. The default value of 8 actually does implement exactly the same behavior as the previous code which was in the #else clause of the ifdef. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko

[U-Boot] [PATCH 15/25] eeprom: Pull out address computation

2014-10-19 Thread Marek Vasut
Pull out the code computing the EEPROM address into separate function so that it's not duplicated. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 64 ++--- 1 file changed, 26 insertions(+), 3

[U-Boot] [PATCH 11/25] eeprom: Zap CONFIG_SYS_EEPROM_X40430

2014-10-19 Thread Marek Vasut
Now that the only user of CONFIG_SYS_EEPROM_X40430 was removed, remove this unused code from cmd_eeprom.c Signed-off-by: Marek Vasut Cc: Masahiro Yamada Cc: Tom Rini Cc: Wolfgang Denk Cc: Simon Glass Cc: Heiko Schocher --- common/cmd_eeprom.c | 95 ---

[U-Boot] [PATCH 21/25] eeprom: Pull out the RW loop

2014-10-19 Thread Marek Vasut
Unify the code for doing read/write into single function, since the code for both the read and write is almost identical. This again trims down the code duplication. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 51 +--

[U-Boot] [PATCH 14/25] eeprom: Pull out the I/O code

2014-10-19 Thread Marek Vasut
Pull out the code which does the I2C or SPI read/write, so that the beefy ifdef around it is contained in a single function. Signed-off-by: Marek Vasut Cc: Simon Glass Cc: Tom Rini Cc: Heiko Schocher --- common/cmd_eeprom.c | 38 ++ 1 file changed, 26 inser

[U-Boot] [PATCH v3 0/6] x86: Enable FIT images on x86

2014-10-19 Thread Simon Glass
This little series adds support for booting FITs on x86. A FIT is a single file that can contain a kernel, device tree and ramdisk. x86 kernels require a setup.bin file to boot. Rather than try to pack this into the image in a clever way, this series just adds it as another image in the FIT. At pr

[U-Boot] [PATCH v3 5/6] doc: Tidy up and update part of the FIT documentation

2014-10-19 Thread Simon Glass
This uses cfg instead of conf, and img instead of image. Fix these and update in a few other places. Signed-off-by: Simon Glass --- Changes in v3: - Split out FIT documentation fixes into a separate patch Changes in v2: None doc/uImage.FIT/source_file_format.txt | 17 + 1 file

[U-Boot] [PATCH v3 6/6] x86: Support loading kernel setup from a FIT

2014-10-19 Thread Simon Glass
Add a new setup@ section to the FIT which can be used to provide a setup binary for booting Linux on x86. This makes it possible to boot x86 from a FIT. Signed-off-by: Simon Glass --- Changes in v3: - Rebase to master - Word-wrap the new documentation file Changes in v2: - Add a README to expla

[U-Boot] [PATCH v3 2/6] x86: Rewrite bootm.c to make it similar to ARM

2014-10-19 Thread Simon Glass
The x86 bootm code is quite special, and geared to zimage. Adjust it to support device tree and make it more like the ARM code, with separate bootm stages and functions for each stage. Create a function announce_and_cleanup() to handle printing the "Starting kernel ..." message and put it in bootm

[U-Boot] [PATCH v3 1/6] x86: Enable LMB and RAMDISK_HIGH by default

2014-10-19 Thread Simon Glass
These options are used by the image code. To allow us to use the generic code more easily, define these for x86. Signed-off-by: Simon Glass --- Changes in v3: None Changes in v2: None arch/x86/include/asm/config.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/x86/include/asm/conf

[U-Boot] [PATCH v3 4/6] sandbox: bootm: Don't fail the architecture check

2014-10-19 Thread Simon Glass
Since sandbox is used for testing, it should be able to 'boot' an image from any archhitecture. This allows us to test an image by loading it in sandbox. Signed-off-by: Simon Glass --- Changes in v3: - Move sandbox bootm change into a separate patch Changes in v2: None common/image-fit.c | 2

[U-Boot] [PATCH v3 3/6] x86: Allow cmdline setup in setup_zimage() to be optional

2014-10-19 Thread Simon Glass
If we are passing this using the device tree then we may not want to set this up here. Signed-off-by: Simon Glass --- Changes in v3: None Changes in v2: None arch/x86/lib/zimage.c | 21 - 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/arch/x86/lib/zimage.c b

Re: [U-Boot] [PATCH 0/4] dm: rpi: Move Raspberry Pi to use driver model

2014-10-19 Thread Simon Glass
Hi Stephen, On 17 October 2014 20:51, Stephen Warren wrote: > On 09/30/2014 07:41 PM, Stephen Warren wrote: >> On 09/22/2014 05:30 PM, Simon Glass wrote: >>> This series adds driver model support to the GPIO and serial drivers used >>> by Raspberry Pi, and moves Raspberry Pi over to driver model.

Re: [U-Boot] [PATCH 01/25] ppc: Zap ICU862 board

2014-10-19 Thread Masahiro Yamada
Hi Marek, On Mon, 20 Oct 2014 03:48:02 +0200 Marek Vasut wrote: > This board is the only user of CONFIG_SYS_EEPROM_X40430 , remove > it so the EEPROM command code can be cleansed of the related code > as well. > > Signed-off-by: Marek Vasut > Cc: Masahiro Yamada > Cc: Tom Rini > Cc: Wolfga

[U-Boot] [PATCH] arm: socfpga: Add I2C support to SoCFPGA

2014-10-19 Thread Stefan Roese
This patch adds I2C support for the SoCFPGA. Using the designware I2C controller driver. It supports all 4 I2C busses on the SoCFPGA. Signed-off-by: Stefan Roese Cc: Marek Vasut Cc: Vince Briders Cc: Chin Liang See Cc: Dinh Nguyen --- include/configs/socfpga_common.h | 22 +++