oweals/u-boot.git
8 years agogpio: uniphier: use devm_get_addr() to get base address
Masahiro Yamada [Thu, 24 Mar 2016 13:32:41 +0000 (22:32 +0900)]
gpio: uniphier: use devm_get_addr() to get base address

Currently, fdtdec_get_addr_size() does not support the address
translation, so it cannot handle device trees with non-straight
"ranges" properties.  (This would be a problem with DTS for UniPhier
ARMv8 SoCs.)

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoi2c: uniphier: use devm_get_addr() to get base address
Masahiro Yamada [Thu, 24 Mar 2016 13:32:40 +0000 (22:32 +0900)]
i2c: uniphier: use devm_get_addr() to get base address

Currently, fdtdec_get_addr_size() does not support the address
translation, so it cannot handle device trees with non-straight
"ranges" properties.  (This would be a problem with DTS for UniPhier
ARMv8 SoCs.)

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoclk: uniphier: use devm_get_addr() to get base address
Masahiro Yamada [Thu, 24 Mar 2016 13:32:39 +0000 (22:32 +0900)]
clk: uniphier: use devm_get_addr() to get base address

Currently, fdtdec_get_addr_size() does not support the address
translation, so it cannot handle device trees with non-straight
"ranges" properties.  (This would be a problem with DTS for UniPhier
ARMv8 SoCs.)

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoserial: uniphier: use devm_get_addr() to get base address
Masahiro Yamada [Thu, 24 Mar 2016 13:32:38 +0000 (22:32 +0900)]
serial: uniphier: use devm_get_addr() to get base address

Currently, fdtdec_get_addr_size() does not support the address
translation, so it cannot handle device trees with non-straight
"ranges" properties.  (This would be a problem with DTS for UniPhier
ARMv8 SoCs.)

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoARM: uniphier: add sramupdate command
Masahiro Yamada [Thu, 24 Mar 2016 13:23:36 +0000 (22:23 +0900)]
ARM: uniphier: add sramupdate command

This command would be useful to update U-Boot images in SRAM.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoARM: uniphier: make u-boot-with-spl.bin really available
Masahiro Yamada [Thu, 24 Mar 2016 13:22:23 +0000 (22:22 +0900)]
ARM: uniphier: make u-boot-with-spl.bin really available

Commit d085ecd61b99 ("ARM: uniphier: switch to raw U-Boot image")
claimed that u-boot-with-spl.bin would be useful in its commit log,
but it was not available because the commit missed to define
CONFIG_SPL_MAX_SIZE.  Without it, CONFIG_SPL_PAD_TO is not defined
either (see include/config_fallbacks.h).  So, the SPL image is not
padded correctly.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agomtd: nand: denali: max_banks calculation changed in revision 5.1
Graham Moore [Thu, 24 Mar 2016 13:14:35 +0000 (22:14 +0900)]
mtd: nand: denali: max_banks calculation changed in revision 5.1

Read Denali hardware revision number and use it to
calculate max_banks,  The encoding of max_banks changed
in Denali revision 5.1.

[ Linux commit : 271707b1d817f5104e02b2bd1bab43f0c8759418 ]

Signed-off-by: Graham Moore <grmoore@opensource.altera.com>
[Brian: parentheses around macro arg]
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
[Masahiro: import from Linux and adjust ioread32() to readl() ]
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
8 years agoMerge branch 'master' of git://git.denx.de/u-boot-tegra
Tom Rini [Tue, 29 Mar 2016 17:33:13 +0000 (13:33 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-tegra

8 years agoMerge branch 'master' of git://git.denx.de/u-boot-fsl-qoriq
Tom Rini [Tue, 29 Mar 2016 16:58:45 +0000 (12:58 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-fsl-qoriq

8 years agoARM: tegra210: set PLLE_PTS bit when enabling PLLE
Stephen Warren [Tue, 22 Mar 2016 15:45:36 +0000 (09:45 -0600)]
ARM: tegra210: set PLLE_PTS bit when enabling PLLE

This bit needs to be set for system suspend/resume to work. This setting
will be documented in an updated TRM at some time in the future.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Tom Warren <twarren@nvidia.com>
8 years agoarmv8/ls2080ardb: Enable VID support
Rai Harninder [Wed, 23 Mar 2016 11:34:38 +0000 (17:04 +0530)]
armv8/ls2080ardb: Enable VID support

This patch enable VID support for ls2080ardb platform.
It uses the common VID driver.

Signed-off-by: Rai Harninder <harninder.rai@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8/ls1043aqds: dts: Set SPI mode for DSPI
Qianyu Gong [Wed, 23 Mar 2016 11:11:36 +0000 (19:11 +0800)]
armv8/ls1043aqds: dts: Set SPI mode for DSPI

Clock phase and polarity for DSPI flash need to be set.

Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-layerscape: Add LS1023A SVR
Mingkai Hu [Wed, 23 Mar 2016 11:10:43 +0000 (19:10 +0800)]
armv8: fsl-layerscape: Add LS1023A SVR

Signed-off-by: Mingkai Hu <mingkai.hu@nxp.com>
Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-layerscape: Fix LS1043A SVR register
Mingkai Hu [Wed, 23 Mar 2016 11:10:42 +0000 (19:10 +0800)]
armv8: fsl-layerscape: Fix LS1043A SVR register

Signed-off-by: Mingkai Hu <mingkai.hu@nxp.com>
Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoSECURE BOOT: Change fsl_secboot_validate func to pass image addr
Saksham Jain [Wed, 23 Mar 2016 10:54:45 +0000 (16:24 +0530)]
SECURE BOOT: Change fsl_secboot_validate func to pass image addr

Use a pointer to pass image address to fsl_secboot_validate(),
instead of using environmental variable "img_addr".

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoSECURE BOOT: Halt execution when secure boot fail
Saksham Jain [Wed, 23 Mar 2016 10:54:44 +0000 (16:24 +0530)]
SECURE BOOT: Halt execution when secure boot fail

In case of fatal failure during secure boot execution (e.g. header
not found), reset is asserted to stop execution. If the RESET_REQ
is not tied to HRESET, this allows the execution to continue.

Add esbh_halt() after the reset to make sure execution stops.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoSECURE_BOOT: Use default bootargs
Saksham Jain [Wed, 23 Mar 2016 10:54:43 +0000 (16:24 +0530)]
SECURE_BOOT: Use default bootargs

For secure boot, currently we were using fixed bootargs for all SoCs.
This is not needed and we can use the bootargs which are used in
non-secure boot.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agocrypto/fsl: Make CAAM transactions cacheable
Saksham Jain [Wed, 23 Mar 2016 10:54:42 +0000 (16:24 +0530)]
crypto/fsl: Make CAAM transactions cacheable

This commit solves CAAM coherency issue on ls2080. When caches are
enabled and CAAM's DMA's AXI transcations are not made cacheable,
Core reads/writes data from/to caches and CAAM does from main memory.
This forces data flushes to synchronize various data structures. But
even if any data in proximity of these structures is read by core,
these structures again are fetched in caches.

To avoid this problem, either all the data that CAAM accesses can be
made cache line aligned or CAAM transcations can be made cacheable.

So, this commit makes CAAM transcations as write back with write and
read allocate.

Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agocrypto/fsl: Correct 64-bit write when MMU disabled
Saksham Jain [Wed, 23 Mar 2016 10:54:41 +0000 (16:24 +0530)]
crypto/fsl: Correct 64-bit write when MMU disabled

When MMU is disabled, 64-bit write must be aligned at 64-bit
boundary. Becaue the memory location is not guaranteed to be 64-bit
aligned, the 64-bit write needs to be split into two 32-bit writes
to avoid the alignment exception.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-lsch3: Disable SMMU during secure boot
Saksham Jain [Wed, 23 Mar 2016 10:54:40 +0000 (16:24 +0530)]
armv8: fsl-lsch3: Disable SMMU during secure boot

During secure boot, SMMU is enabled on POR by SP bootrom. SMMU needs
to be put in bypass mode in uboot to enable CAAM transcations to pass
through.

For non-secure boot, SP BootROM doesn't enable SMMU, which is in
bypass mode out of reset.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080: Add config for endianess of CCSR GUR
Saksham Jain [Wed, 23 Mar 2016 10:54:39 +0000 (16:24 +0530)]
armv8: ls2080: Add config for endianess of CCSR GUR

The GUR (DCFG) registers in CCSR space are in little endian format.
Define a config CONFIG_SYS_FSL_CCSR_GUR_LE in
arch/arm/include/asm/arch-fsl-layerscape/config.h

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080: Change env variable "fdt_high"
Saksham Jain [Wed, 23 Mar 2016 10:54:38 +0000 (16:24 +0530)]
armv8: ls2080: Change env variable "fdt_high"

"fdt_high" env variable was set to 0xcfffffff for secure boot.
Change it to 0xa0000000 for LS2080 to be consistent with non-secure
boot targets.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-lsch3: Copy Bootscript and header from NOR to DDR
Saksham Jain [Wed, 23 Mar 2016 10:54:37 +0000 (16:24 +0530)]
armv8: fsl-lsch3: Copy Bootscript and header from NOR to DDR

To unify steps for secure boot for xip (eg. NOR) and non-xip memories
(eg. NAND, SD), bootscipts and its header are copied to main memory.
Validation and execution are performed from there.

For other ARM Platforms (ls1043 and ls1020), to avoid disruption of
existing users, this copy step is not used for NOR boot.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080: Add bootscript header addr for secure boot
Saksham Jain [Wed, 23 Mar 2016 10:54:36 +0000 (16:24 +0530)]
armv8: ls2080: Add bootscript header addr for secure boot

During secure boot, Linux image along with other images are validated
using bootscript. This bootscript also needs to be validated before
it executes. This requires a header for bootscript.

When secure boot is enabled, default bootcmd is changed to first
validate bootscript using the header and then execute the script.

For ls2080, NOR memory map is different from other ARM SoCs. So a new
address on NOR is used for this bootscript header (0x583920000). The
Bootscript address is mentioned in this header along with addresses of
other images.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080rdb: ls2080qds: Add secure boot support
Saksham Jain [Wed, 23 Mar 2016 10:54:35 +0000 (16:24 +0530)]
armv8: ls2080rdb: ls2080qds: Add secure boot support

Sec_init has been called at the beginning to initialize SEC Block
(CAAM) which is used by secure boot validation later for both ls2080a
qds and rdb. 64-bit address in ESBC Header has been enabled. Secure
boot defconfigs are created for boards (NOR boot).

Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-lsch3: Add new header for secure boot
Saksham Jain [Wed, 23 Mar 2016 10:54:34 +0000 (16:24 +0530)]
armv8: fsl-lsch3: Add new header for secure boot

For secure boot, a header is used to identify key table, signature
and image address. A new header structure is added for lsch3.

Currently key extension (IE) feature is not supported. Single key
feature is not supported. Keys must be in table format. Hence, SRK
(key table) must be present. Max key number has increase from 4 to
8. The 8th key is irrevocable. A new barker Code is used.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080: Add configs for SEC, SecMon, SRK and DCFG
Saksham Jain [Wed, 23 Mar 2016 10:54:33 +0000 (16:24 +0530)]
armv8: ls2080: Add configs for SEC, SecMon, SRK and DCFG

Add configs for various IPs used during secure boot. Add address
and endianness for SEC and Security Monitor. SRK are fuses in SFP
(fuses for public key's hash). These are stored in little endian
format.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080: Add SFP Configs for LS2080
Saksham Jain [Wed, 23 Mar 2016 10:54:32 +0000 (16:24 +0530)]
armv8: ls2080: Add SFP Configs for LS2080

In LS2080, SFP has version 3.4. It is in little endian. The base
address is 0x01e80200. SFP is used in Secure Boot to read fuses.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Signed-off-by: Saksham Jain <saksham.jain@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agodriver: net: fsl-mc: Check NULL before pointer dereference
Prabhakar Kushwaha [Fri, 18 Mar 2016 10:46:03 +0000 (16:16 +0530)]
driver: net: fsl-mc: Check NULL before pointer dereference

NULL pointer should be checked before any dereference.  This patch
move memest after the NULL pointer check.

Signed-off-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Reported-by: Jose Rivera <german.rivera@nxp.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agodriver: net: fsl-mc: Free dflt_dpio pointer after its usage
Prabhakar Kushwaha [Fri, 18 Mar 2016 10:45:29 +0000 (16:15 +0530)]
driver: net: fsl-mc: Free dflt_dpio pointer after its usage

Free dflt_dpio pointer after its usage during error handling

Signed-off-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Reported-by: Jose Rivera <german.rivera@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: fsl-layerscape: Skip reconfigure QSPI clock when booting from QSPI
Qianyu Gong [Wed, 16 Mar 2016 10:01:52 +0000 (18:01 +0800)]
armv8: fsl-layerscape: Skip reconfigure QSPI clock when booting from QSPI

The qspi_cfg register is set by PBI when booting from QSPI. No need
to changing it again.

Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoomap24xx_i2c: Implement CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW
Guy Thouret [Fri, 11 Mar 2016 16:23:41 +0000 (16:23 +0000)]
omap24xx_i2c: Implement CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW

Signed-off-by: Guy Thouret <guy.thouret@wems.co.uk>
Cc: Heiko Schocher <hs@denx.de>
8 years agodm: i2c: mxc_i2c: implement i2c_idle_bus
Peng Fan [Fri, 11 Mar 2016 08:47:50 +0000 (16:47 +0800)]
dm: i2c: mxc_i2c: implement i2c_idle_bus

Implement i2c_idle_bus in driver, then setup_i2c can
be dropped for boards which enable DM_I2C/DM_GPIO/PINCTRL.
The i2c_idle_bus force bus idle flow follows setup_i2c in
arch/arm/imx-common/i2c-mxv7.c

This patch is an implementation following linux kernel patch:
"
commit 1c4b6c3bcf30d0804db0d0647d8ebeb862c6f7e5
Author: Gao Pan <b54642@freescale.com>
Date:   Fri Oct 23 20:28:54 2015 +0800

    i2c: imx: implement bus recovery

    Implement bus recovery methods for i2c-imx so we can recover from
    situations where SCL/SDA are stuck low.

    Once i2c bus SCL/SDA are stuck low during transfer, config the i2c
    pinctrl to gpio mode by calling pinctrl sleep set function, and then
    use GPIO to emulate the i2c protocol to send nine dummy clock to recover
    i2c device. After recovery, set i2c pinctrl to default group setting.
"

See Documentation/devicetree/bindings/i2c/i2c-imx.txt for detailed
description.
1. Introuduce scl_gpio/sda_gpio/bus in mxc_i2c_bus.
2. Discard the __weak attribute for i2c_idle_bus and implement it,
   since we have pinctrl driver/driver model gpio driver. We can
   use device tree, but not let board code to do this.
3. gpio state for mxc_i2c is not a must, but it is recommended. If
   there is no gpio state, driver will give tips, but not fail.
4. The i2c controller was first probed, default pinctrl state will
   be used, so when need to use gpio function, need to do
   "pinctrl_select_state(dev, "gpio")" and after force bus idle,
   need to switch back "pinctrl_select_state(dev, "default")".

This is example about how to use the gpio force bus
idle function:
"
 &i2c1 {
  clock-frequency = <100000>;
pinctrl-names = "default", "gpio";
  pinctrl-0 = <&pinctrl_i2c1>;
pinctrl-1 = <&pinctrl_i2c1_gpio>;
scl-gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>;
sda-gpios = <&gpio1 29 GPIO_ACTIVE_HIGH>;
status = "okay";
[....]
 };

[.....]

pinctrl_i2c1_gpio: i2c1grp_gpio {
fsl,pins = <
MX6UL_PAD_UART4_TX_DATA__GPIO1_IO28 0x1b8b0
MX6UL_PAD_UART4_RX_DATA__GPIO1_IO29 0x1b8b0
>;
};
"

Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Heiko Schocher <hs@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: York Sun <york.sun@nxp.com>
8 years agoRevert "pxa_lcd: make driver cache-aware"
Tom Rini [Mon, 28 Mar 2016 00:58:08 +0000 (20:58 -0400)]
Revert "pxa_lcd: make driver cache-aware"

This reverts commit 59deb7fe8d23c8ec2b659d99323ec4a2ec19148a.

Signed-off-by: Tom Rini <trini@konsulko.com>
8 years agoRevert "pxa_lcd: invert colors for Zipit Z2 to get white on black palette"
Tom Rini [Mon, 28 Mar 2016 00:57:54 +0000 (20:57 -0400)]
Revert "pxa_lcd: invert colors for Zipit Z2 to get white on black palette"

This reverts commit 3bc8ffd9cb774feceefc7bdebe9353fcea071343.

Signed-off-by: Tom Rini <trini@konsulko.com>
8 years agotools: env: bug: config structs must be defined in tools library
Andreas Fenkart [Fri, 25 Mar 2016 13:52:19 +0000 (14:52 +0100)]
tools: env: bug: config structs must be defined in tools library

fw_senten/fw_printenv can be compiled as a tools library,
excluding the fw_env_main object.

Reported-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
8 years agoARM: asm: types: Introduce DMA_ADDR_T_64BIT
Lokesh Vutla [Thu, 24 Mar 2016 10:32:00 +0000 (16:02 +0530)]
ARM: asm: types: Introduce DMA_ADDR_T_64BIT

dma_addr_t holds any valid DMA address. If the DMA API only uses 32-bit
addresses, dma_addr_t need only be 32 bits wide.  Bus addresses, e.g., PCI BARs,
may be wider than 32 bits, but drivers do memory-mapped I/O to ioremapped
kernel virtual addresses, so they don't care about the size of the actual
bus addresses.
Also 32 bit ARM systems with LPAE enabled can use 64bit address space, but
DMA still use 32bit address like in case of DRA7 and Keystone platforms.

This is inspired from the Linux kernel types implementation[1]

[1] https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/include/linux/types.h#n142

Acked-by: Lukasz Majewski <l.majewski@samsung.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoefi_loader: Fix some entry/exit points
Alexander Graf [Thu, 24 Mar 2016 00:37:37 +0000 (01:37 +0100)]
efi_loader: Fix some entry/exit points

When switching between EFI context and U-Boot context we need to swap
the register that "gd" resides in.

Some functions slipped through here, with efi_allocate_pool / efi_free_pool
not doing the switch correctly and efi_return_handle switching too often.

Fix them all up to make sure we always have consistent register state.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agocfi_flash: return device into read array mode after reading status
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:10 +0000 (18:37 -0700)]
cfi_flash: return device into read array mode after reading status

Otherwise flash remains in read status mode and it's not possible
to access data on flash.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Stefan Roese <sr@denx.de>
8 years agozipitz2: enable caches
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:09 +0000 (18:37 -0700)]
zipitz2: enable caches

It speeds up loading kernel from SD or USB a lot.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Marek Vasut <marex@denx.de>
8 years agopxa_lcd: make driver cache-aware
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:08 +0000 (18:37 -0700)]
pxa_lcd: make driver cache-aware

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agopxa: add support for D- and I- caches
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:07 +0000 (18:37 -0700)]
pxa: add support for D- and I- caches

Tested with OHCI and pxafb drivers - no issues found

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agopxa: start.S: enable SRAM clock
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:06 +0000 (18:37 -0700)]
pxa: start.S: enable SRAM clock

SRAM is used for early stack, but kernel disables its clock on suspend.
Re-enable SRAM clock on startup, otherwise u-boot crashes on resume from suspend.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agozipitz2: enable USB host support
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:05 +0000 (18:37 -0700)]
zipitz2: enable USB host support

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agopxa-common: pxa27x has 3 OHCI ports
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:04 +0000 (18:37 -0700)]
pxa-common: pxa27x has 3 OHCI ports

3rd port can be used as a device or host.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Marek Vasut <marex@denx.de>
8 years agozipitz2: enable libfdt
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:03 +0000 (18:37 -0700)]
zipitz2: enable libfdt

zipitz2 supports DT boot since linux-4.4 (not mainlined yet)

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agopxa_lcd: invert colors for Zipit Z2 to get white on black palette
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:02 +0000 (18:37 -0700)]
pxa_lcd: invert colors for Zipit Z2 to get white on black palette

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agozipitz2: enable LCD rotation
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:01 +0000 (18:37 -0700)]
zipitz2: enable LCD rotation

z2's screen is rotated by 270 degrees

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Acked-by: Marek Vasut <marex@denx.de>
8 years agozipitz2: restore board support
Vasily Khoruzhick [Mon, 21 Mar 2016 01:37:00 +0000 (18:37 -0700)]
zipitz2: restore board support

zipitz2 was dropped in 49d8899ba9c26335e4a12e01c18028fc5e40c796

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
8 years agocmd: spi: check return value of strdup
Peng Fan [Sun, 20 Mar 2016 13:21:36 +0000 (21:21 +0800)]
cmd: spi: check return value of strdup

Check return value of strdup.

Signed-off-by: Peng Fan <van.freenix@gmail.com>
Cc: Przemyslaw Marczak <p.marczak@samsung.com>
Cc: Bin Meng <bmeng.cn@gmail.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Cc: Tom Rini <trini@konsulko.com>
8 years agoserial: add BCM283x mini UART driver
Stephen Warren [Sat, 19 Mar 2016 03:41:38 +0000 (21:41 -0600)]
serial: add BCM283x mini UART driver

The RPi3 typically uses the regular UART for high-speed communication with
the Bluetooth device, leaving us the mini UART to use for the serial
console. Add support for this UART so we can use it.

Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
8 years agoboard: ti: am57xx: Set ethernet MAC addresses from EEPROM to env
Roger Quadros [Fri, 18 Mar 2016 11:18:12 +0000 (13:18 +0200)]
board: ti: am57xx: Set ethernet MAC addresses from EEPROM to env

The MAC addresses for the PRU Ethernet ports will be available in the
board EEPROM as an address range. Populate those MAC addresses (if valid)
into the u-boot environment so that they can be passed on to the
device tree during fdt_fixup_ethernet().

Signed-off-by: Roger Quadros <rogerq@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agonet: export eth_setenv_enetaddr_by_index() to net.h
Roger Quadros [Fri, 18 Mar 2016 11:18:11 +0000 (13:18 +0200)]
net: export eth_setenv_enetaddr_by_index() to net.h

Some TI boards (e.g. IDK) have 4 to 6 ethernet ports and
this function is handy at board.c to configure the
MAC address of the ports.

Signed-off-by: Roger Quadros <rogerq@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agodebug_uart: Remove duplicated carriage return handling
Bin Meng [Fri, 18 Mar 2016 06:59:04 +0000 (23:59 -0700)]
debug_uart: Remove duplicated carriage return handling

Since commit b391d74 "debug_uart: output CR along with LF", the
handling in puts() is duplicated, not to mention that it should
output carriage return before line feed.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoefi_stub: Move carriage return before line feed in putc()
Bin Meng [Fri, 18 Mar 2016 06:59:03 +0000 (23:59 -0700)]
efi_stub: Move carriage return before line feed in putc()

A carriage return needs to execute before a line feed.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agonet: rtl8169: Fix build error when DEBUG is on
Bin Meng [Fri, 18 Mar 2016 06:27:44 +0000 (23:27 -0700)]
net: rtl8169: Fix build error when DEBUG is on

When DEBUG_RTL8169 is on, a build error occurs in function
'rtl_init': error: 'dev' undeclared. Fix this.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
8 years agommc: Print send_cmd response only when return value is zero
Bin Meng [Fri, 18 Mar 2016 04:53:14 +0000 (21:53 -0700)]
mmc: Print send_cmd response only when return value is zero

send_cmd response is valid only when no error happened. If an error
occured, let mmc_send_cmd() print the return value to aid debugging.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agommc: Fix switch..case indention
Bin Meng [Fri, 18 Mar 2016 04:53:13 +0000 (21:53 -0700)]
mmc: Fix switch..case indention

Correct the indention level of switch..case statements.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoFix typo choosen in comments and printf logs
Alexander Merkle [Thu, 17 Mar 2016 14:44:47 +0000 (15:44 +0100)]
Fix typo choosen in comments and printf logs

Minor change: chosen is written with one "o".
No code change here, only comment & printf.

Signed-off-by: Alexander Merkle <alexander.merkle@lauterbach.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
8 years agoFix typo in chosen parameter of pcm052.dts
Alexander Merkle [Thu, 17 Mar 2016 14:44:46 +0000 (15:44 +0100)]
Fix typo in chosen parameter of pcm052.dts

Fix typo "choosen" instead of "chosen" in pcm052.dts.
Not tested but should fix boot process and terminal output.

Signed-off-by: Alexander Merkle <alexander.merkle@lauterbach.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
8 years agoFix typo in chosen parameter in vf610-twr.dts
Alexander Merkle [Thu, 17 Mar 2016 14:44:45 +0000 (15:44 +0100)]
Fix typo in chosen parameter in vf610-twr.dts

Fix typo "choosen" instead of "chosen" in vf610-twr.dts.
Fixes boot process and terminal output for Vybrid series.

Signed-off-by: Alexander Merkle <alexander.merkle@lauterbach.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
8 years agobootp: Prevent u-boot from using others responses.
Anton Persson [Thu, 17 Mar 2016 08:38:21 +0000 (09:38 +0100)]
bootp: Prevent u-boot from using others responses.

In rare circumstances two dhcp clients may generate the same
bootp ID. If this happens it is vital that the client also checks
the hw address in the received response to prevent IP address conflicts.

Signed-off-by: Anton Persson <don.juanton@gmail.com>
8 years agommc: bcm2835: fix 64-bit build warning
Stephen Warren [Thu, 17 Mar 2016 03:42:24 +0000 (21:42 -0600)]
mmc: bcm2835: fix 64-bit build warning

Fixes:
drivers/mmc/bcm2835_sdhci.c: In function ‘bcm2835_sdhci_init’:
drivers/mmc/bcm2835_sdhci.c:181:17: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]

Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
8 years agoARM: bcm2835: fix 64-bit build warning in mbox
Stephen Warren [Thu, 17 Mar 2016 03:40:57 +0000 (21:40 -0600)]
ARM: bcm2835: fix 64-bit build warning in mbox

Fixes:
arch/arm/mach-bcm283x/mbox.c: In function ‘bcm2835_mbox_call_prop’:
arch/arm/mach-bcm283x/mbox.c:118:48: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
arch/arm/mach-bcm283x/mbox.c:126:29: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]

Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: bcm283x: don't always define CONFIG_BCM2835
Stephen Warren [Thu, 17 Mar 2016 03:40:56 +0000 (21:40 -0600)]
ARM: bcm283x: don't always define CONFIG_BCM2835

Currently, CONFIG_BCM2835 is defined for all BCM283x builds and _BCM2836
is defined when building for that SoC. That means there isn't a single
define that means "exactly BCM2835". This will complicate future patches
where BCM2835-vs-anything-else needs to be determined simply.

Modify the code to define one or the other of CONFIG_BCM2835/BCM2836 so
future patches are simpler.

Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agodoc/README.clang: Document sandbox instructions
Tom Rini [Thu, 17 Mar 2016 00:40:20 +0000 (20:40 -0400)]
doc/README.clang: Document sandbox instructions

It is possible to compile and run the sandbox target with clang
currently, so document that as well.

Cc: Jeroen Hofstee <jeroen@myspectrum.nl>
Signed-off-by: Tom Rini <trini@konsulko.com>
8 years agobcm2835 video: Map fb as cached
Alexander Graf [Thu, 24 Mar 2016 09:31:11 +0000 (10:31 +0100)]
bcm2835 video: Map fb as cached

The bcm2835 frame buffer is in RAM, so we can easily map it as cached and gain
all the glorious performance boost that brings with it.

Signed-off-by: Alexander Graf <agraf@suse.de>
Tested-by: Stephen Warren <swarren@wwwdotorg.org>
Acked-by: Stephen Warren <swarren@wwwdotorg.org>
8 years agoRPi: Enable caches for rpi2
Alexander Graf [Wed, 16 Mar 2016 14:41:23 +0000 (15:41 +0100)]
RPi: Enable caches for rpi2

Now that we have support for running with caches enabled in HYP mode,
opt in to that on the Raspberry Pi 2. This brings a significant performance
boost.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agolcd: Fix compile warning in 64bit mode
Alexander Graf [Wed, 16 Mar 2016 14:41:22 +0000 (15:41 +0100)]
lcd: Fix compile warning in 64bit mode

When compiling the code for 64bit, the lcd code emits warnings because it
tries to cast pointers to 32bit values. Fix it by casting them to longs
instead, actually properly aligning with the function prototype.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agoarm: Add support for HYP mode and LPAE page tables
Alexander Graf [Wed, 16 Mar 2016 14:41:21 +0000 (15:41 +0100)]
arm: Add support for HYP mode and LPAE page tables

We currently always modify the SVC versions of registers and only support
the short descriptor PTE format.

Some boards however (like the RPi2) run in HYP mode. There, we need to modify
the HYP version of system registers and HYP mode only supports the long
descriptor PTE format.

So this patch introduces support for both long descriptor PTEs and HYP mode
registers.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agoarm64: Add 32bit arm compatible dcache definitions
Alexander Graf [Wed, 16 Mar 2016 14:41:20 +0000 (15:41 +0100)]
arm64: Add 32bit arm compatible dcache definitions

We want to be able to reuse device drivers from 32bit code, so let's add
definitions for all the dcache options that 32bit code has.

While at it, fix up the DCACHE_OFF configuration. That was setting the bits
to declare a PTE a PTE and left the MAIR index bit at 0. Drop the useless
bits and make the index explicit.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agoboard: ti: DRA7: Add DRA72-rev C evm pinmux
Nishanth Menon [Tue, 15 Mar 2016 23:09:17 +0000 (18:09 -0500)]
board: ti: DRA7: Add DRA72-rev C evm pinmux

Add the pinmux data for rev C evm. This is different from previous
revisions of the platform thanks to the deltas introduced both from
silicon side and from SoC side.

Based on J6EcoES2_EVM_Base_Config-20160309b and PCT-DRA72x-v1.3.0.7 for
SR2.0 silicon.

Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: OMAP5/DRA7: Expose do_set_iodelay
Nishanth Menon [Tue, 15 Mar 2016 23:09:16 +0000 (18:09 -0500)]
ARM: OMAP5/DRA7: Expose do_set_iodelay

do_set_iodelay can now be used from board files based on needs of the
platforms variation they have.

Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: OMAP5/DRA7: Split iodelay functionality into sub steps
Nishanth Menon [Tue, 15 Mar 2016 23:09:15 +0000 (18:09 -0500)]
ARM: OMAP5/DRA7: Split iodelay functionality into sub steps

Since many platforms may need different pad configuration required
depending on variation of the platform with minor deltas, it is
easier to maintain a sub step based approach to allow for pin mux
and iodelay configuration which may depend on the platform variations
and need to be done in IO isolation.

While we retain the older __recalibrate_iodelay function which provides
a ready sequencing, __recalibrate_iodelay_start and
__recalibrate_iodelay_end may be alternatively used now and the callers
will be responsible for the correct sequencing of operations.

Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoboard: ti: DRA72: revC evm: Update sdram timing configuration for SR2.0
Ravi Babu [Tue, 15 Mar 2016 23:09:14 +0000 (18:09 -0500)]
board: ti: DRA72: revC evm: Update sdram timing configuration for SR2.0

DDR configuration has changes from SR1.1 based Rev-A/B version of evm
to the SR2.0 based Rev C of the EVM. Rev C evm now uses the higher
density MT41K512M8RH-125-AAT:E (IT) which is of size 2GB.

Update the DDR configuration based on data from EMIF configuration
tool 1.1.1. NOTE: we use eeprom information (ram_size) to update the
configuration.

Tested-by: Vishal Mahaveer <vishalm@ti.com>
Signed-off-by: Ravi Babu <ravibabu@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: DRA72: sdram: Update sdram ext phy configuration for SR2.0
Nishanth Menon [Tue, 15 Mar 2016 23:09:13 +0000 (18:09 -0500)]
ARM: DRA72: sdram: Update sdram ext phy configuration for SR2.0

Based on data from EMIF configuration tool 1.1.1.

Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: DRA7: hwdata: Update ioreg data for DRA72 SR2.0
Nishanth Menon [Tue, 15 Mar 2016 23:09:12 +0000 (18:09 -0500)]
ARM: DRA7: hwdata: Update ioreg data for DRA72 SR2.0

Based on data from EMIF configuration tool 1.1.1. Expected update for
CTRL_WKUP_EMIF1_SDRAM_CONFIG_EXT in the next revision of the tool has
been incorporated as well.

Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: DRA72x: Add support for detection of SR2.0
Ravi Babu [Tue, 15 Mar 2016 23:09:11 +0000 (18:09 -0500)]
ARM: DRA72x: Add support for detection of SR2.0

Add support for detection of SR2.0 version of DRA72x family of
processors.

Signed-off-by: Ravi Babu <ravibabu@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoefi_loader: Add GOP support
Alexander Graf [Tue, 15 Mar 2016 17:38:21 +0000 (18:38 +0100)]
efi_loader: Add GOP support

The EFI standard defines a simple boot protocol that an EFI payload can use
to access video output.

This patch adds support to expose exactly that one (and the mode already in
use) as possible graphical configuration to an EFI payload.

With this, I can successfully run grub2 with graphical output.

Signed-off-by: Alexander Graf <agraf@suse.de>
8 years agoARM: keystone2: Convert BOOT_SET_BITFIELD into static inline function
Nishanth Menon [Tue, 15 Mar 2016 15:25:53 +0000 (10:25 -0500)]
ARM: keystone2: Convert BOOT_SET_BITFIELD into static inline function

Fix up BOOT_SET_BITFIELD to be a static inline function to be readable
with the same functionality.

Reported-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: keystone2: Convert BOOT_READ_BITFIELD into static inline function
Nishanth Menon [Tue, 15 Mar 2016 15:25:52 +0000 (10:25 -0500)]
ARM: keystone2: Convert BOOT_READ_BITFIELD into static inline function

BOOT_READ_BITFIELD can easily be a static inline function and be a
little more readable with the same functionality.

Reported-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agoARM: keystone2: Convert BOOTBITMASK to static inline function
Nishanth Menon [Tue, 15 Mar 2016 15:25:51 +0000 (10:25 -0500)]
ARM: keystone2: Convert BOOTBITMASK to static inline function

BOOTBITMASK is almost impossible to decode, so convert it into a simpler
static line functions of equivalent solution.

Reported-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
8 years agotools: env: fw_parse_script: simplify removal of newline/carriage return
Andreas Fenkart [Fri, 11 Mar 2016 08:39:38 +0000 (09:39 +0100)]
tools: env: fw_parse_script: simplify removal of newline/carriage return

fgets returns when the first '\n' is found

Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
8 years agotools: env: split fw_string_blank into skip_chars / skip_blanks
Andreas Fenkart [Fri, 11 Mar 2016 08:39:37 +0000 (09:39 +0100)]
tools: env: split fw_string_blank into skip_chars / skip_blanks

Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
8 years agotools: env: fw_string_blank: return from loop when item found
Andreas Fenkart [Fri, 11 Mar 2016 08:39:36 +0000 (09:39 +0100)]
tools: env: fw_string_blank: return from loop when item found

Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
8 years agotools: env: replace WHITESPACE macro by isblank
Andreas Fenkart [Fri, 11 Mar 2016 08:39:35 +0000 (09:39 +0100)]
tools: env: replace WHITESPACE macro by isblank

Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
8 years agostm32f746-disco: enable flash support
Vikas Manocha [Wed, 9 Mar 2016 23:18:14 +0000 (15:18 -0800)]
stm32f746-disco: enable flash support

This patch enables embedded flash for stm32f746 discovery board.

Signed-off-by: Vikas Manocha <vikas.manocha@st.com>
8 years agostm32: stm32f4: move flash driver to mtd driver location
Vikas Manocha [Wed, 9 Mar 2016 23:18:13 +0000 (15:18 -0800)]
stm32: stm32f4: move flash driver to mtd driver location

Same flash driver can be used by other stm32 families like stm32f7.
Better place for this driver would be mtd driver location.

Signed-off-by: Vikas Manocha <vikas.manocha@st.com>
8 years agousb: gadget: Move CONFIG_USB_GADGET to Kconfig
Sam Protsenko [Fri, 25 Mar 2016 14:39:47 +0000 (16:39 +0200)]
usb: gadget: Move CONFIG_USB_GADGET to Kconfig

The description was borrowed from kernel. "tristate" type was changed
to "bool" (I believe we don't support modules for u-boot yet, right?).
CONFIG_USB_GADGET requires CONFIG_USB to be defined too, so add it along
as well.

Definitions were added to defconfig files in a way that
"make savedefconfig" generates exactly the same file as used defconfig.

Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
[trini: Add zynq_zc702 conversion]
Signed-off-by: Tom Rini <trini@konsulko.com>
8 years agoMerge git://www.denx.de/git/u-boot-marvell
Tom Rini [Fri, 25 Mar 2016 16:57:18 +0000 (12:57 -0400)]
Merge git://www.denx.de/git/u-boot-marvell

8 years agoarmv8/ls1043a: Update env settings for booting kernel
Qianyu Gong [Tue, 15 Mar 2016 08:35:57 +0000 (16:35 +0800)]
armv8/ls1043a: Update env settings for booting kernel

Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agoarmv8: ls2080a: Update fdt path for fsl-mc node
Stuart Yoder [Wed, 2 Mar 2016 22:37:13 +0000 (16:37 -0600)]
armv8: ls2080a: Update fdt path for fsl-mc node

The fsl-mc node has been moved under /soc, so update
the path references accordingly.  Backwards compatibility
is retained for /fsl-mc.

Delete backwards compatibility for the completely obsolete
/fsl,dprc@0.

Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
8 years agotools: kwboot: Add xmodem timeout option
Kevin Smith [Tue, 16 Feb 2016 21:28:19 +0000 (21:28 +0000)]
tools: kwboot: Add xmodem timeout option

Add command-line specification of xmodem timeout.  If the binary
header needs to take a while to do something (e.g. DDR ECC
scrubbing), the xmodem transfer can time out.  Add a configurable
xmodem block timeout to allow transfers with slow binary headers
to succeed.

Signed-off-by: Kevin Smith <kevin.smith@elecsyscorp.com>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agotools: kwboot: Clean up usage text
Kevin Smith [Tue, 16 Feb 2016 21:28:17 +0000 (21:28 +0000)]
tools: kwboot: Clean up usage text

Usage text was getting unwieldy and somewhat incorrect.  The
usage summary implied that some options were mutually exclusive
(e.g. -q or -s).  Clean up the summary to just include the
important ones, and include a generic "[OPTIONS]" instead.

Signed-off-by: Kevin Smith <kevin.smith@elecsyscorp.com>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agoarm: mvebu: db-88f6820: Drop obsolete binary.0 placeholder
Andreas Färber [Mon, 15 Feb 2016 18:13:30 +0000 (19:13 +0100)]
arm: mvebu: db-88f6820: Drop obsolete binary.0 placeholder

It has been superseded in kwbimage.cfg in favor of an SPL in commit
9e30b31d20f0b793465d07f056b3d9885f578c0d (arm: mvebu: db-88f6820: Add
SPL support with DDR init code). Found via code review.

Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Andreas Färber <afaerber@suse.de>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agoarm: mvebu: theadorable: Add StratixV FPGA programming support
Stefan Roese [Fri, 12 Feb 2016 13:24:07 +0000 (14:24 +0100)]
arm: mvebu: theadorable: Add StratixV FPGA programming support

This patch adds support for Altera StratixV bitstream programming. 2 FPGAs
are connected to the SPI busses. This patch uses board specific write
code to program the bitstream via SPI direct write mode.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Luka Perkov <luka.perkov@sartura.hr>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agoarm: mvebu: spi.h: Add registers for direct write access
Stefan Roese [Fri, 12 Feb 2016 12:52:17 +0000 (13:52 +0100)]
arm: mvebu: spi.h: Add registers for direct write access

The direct write config register is needed for SPI direct write mode
configuration.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Luka Perkov <luka.perkov@sartura.hr>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agoarm: mvebu: Add some SPI CS attributes
Stefan Roese [Fri, 12 Feb 2016 12:52:16 +0000 (13:52 +0100)]
arm: mvebu: Add some SPI CS attributes

These attribute defines may be used to map an area of memory for direct
access to the specific SPI devices. See SPI Direct Access Mode for
further information.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Luka Perkov <luka.perkov@sartura.hr>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agofpga: altera: Add StratixV support
Stefan Roese [Fri, 12 Feb 2016 12:48:02 +0000 (13:48 +0100)]
fpga: altera: Add StratixV support

This patch adds support for programming of the StratixV FPGAs. Programming
is done in this case (board theadorable) via SPI. The board may provide
board specific code for bitstream programming.

This StratixV support will be used by the theadorable board.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Stefan Roese <sr@denx.de>
8 years agogpio: Add DM GPIO driver for Marvell MVEBU
Stefan Roese [Fri, 12 Feb 2016 12:46:50 +0000 (13:46 +0100)]
gpio: Add DM GPIO driver for Marvell MVEBU

This patch adds a DM GPIO driver for the Marvell MVEBU SoCs. There are
other non-DM drivers that might be used on these platforms. But this
patch creates a new DM driver. Which will be used by all Armada XP/38x
boards. Other MVEBU SoC (Kirkwood / Orion) may follow once they
support DM as well.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Dirk Eibach <dirk.eibach@gdsys.cc>
Cc: Phil Sutter <phil@nwl.cc>
Cc: Kevin Smith <kevin.smith@elecsyscorp.com>
Cc: Luka Perkov <luka.perkov@sartura.hr>
Cc: Tom Rini <trini@konsulko.com>
Reviewed-by: Kevin Smith <kevin.smith@elecsyscorp.com>
Tested-by: Kevin Smith <kevin.smith@elecsyscorp.com>
Signed-off-by: Stefan Roese <sr@denx.de>