oweals/u-boot.git
10 years agousb: ci_udc: implement dfu_usb_get_reset
Stephen Warren [Mon, 25 Aug 2014 20:02:15 +0000 (14:02 -0600)]
usb: ci_udc: implement dfu_usb_get_reset

This allows the USB code to determine whether a USB bus reset was issued,
which in turn allows the code to differentiate between a detach (return
to shell prompt) and a board reset/reboot request.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
10 years agoudc: dfu: s3c_udc: Provide function to check if USB reset was asserted
Lukasz Majewski [Mon, 25 Aug 2014 09:07:29 +0000 (11:07 +0200)]
udc: dfu: s3c_udc: Provide function to check if USB reset was asserted

New dfu_usb_get_reset() method is necessary to distinct two different
use cases of dfu-util program.
This method checks if the USB bus reset has been really performed after
DFU DETACH.

Without this function the previous DFU behavior is preserved.

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
10 years agodfu: Provide means to find difference between dfu-util -e and -R
Lukasz Majewski [Mon, 25 Aug 2014 09:07:28 +0000 (11:07 +0200)]
dfu: Provide means to find difference between dfu-util -e and -R

This commit provides distinction between DFU device detach and reset.
The -R behavior is preserved with proper handling of the dfu-util's -e
switch, which detach the DFU device.

By running dfu-util -e; one can force device to finish the execution of
dfu command on target and execute some other scripted commands.

Moreover, some naming has been changed - the dfu_reset() method now is known
as dfu_detach(). New name better reflects the purpose of the code.

It was also necessary to increase the number of usb_gadget_handle_interrupts()
calls since we also must wait for detection of the USB reset event.

Example usage:
1. -e (detach) switch
 dfu-util -a0 -D file1.bin;dfu-util -a3 -D uImage;dfu-util -e

 access to u-boot prompt.

2. -R (reset) switch
 dfu-util -a0 -D file1.bin;dfu-util -R -a3 -D uImage

 target board reset

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
10 years agomx6: tqma6: get board support back to Kconfig build system
Masahiro Yamada [Sun, 31 Aug 2014 15:47:55 +0000 (00:47 +0900)]
mx6: tqma6: get board support back to Kconfig build system

The QS Systems TQMa6 board support was added by commit cb07d74e
and lost by commit e82abaeb.

Commit e82abaeb merged the IMX branch based on pre-Kconfig
and the mainline based on post-Kconfig, simply deleting
the boards.cfg file.  As a result, some boards added just before
the merge were lost.

This commit adds Kconfig, defconfig, MAINTAINERS for TQMa6 board
to work on the Kconfig infrastructure.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Markus Niebel <Markus.Niebel@tq-group.com>
Cc: Stefano Babic <sbabic@denx.de>
10 years agoMerge branch 'master' of git://git.denx.de/u-boot-nios
Tom Rini [Sun, 31 Aug 2014 11:45:55 +0000 (07:45 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-nios

10 years agonomadik: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:08 +0000 (07:11 +0900)]
nomadik: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Nomadik board select menu to nomadik/Kconfig.

Move also common settings (CONFIG_SYS_CPU="arm926ejs" and
CONFIG_SYS_SOC="nomadik").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agohighbank: kconfig: move common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:07 +0000 (07:11 +0900)]
highbank: kconfig: move common settings

Move Highbank-specific settings to highbank/Kconfig.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Rob Herring <robh@kernel.org>
10 years agoorion5x: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:06 +0000 (07:11 +0900)]
orion5x: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Orion5x board select menu to orion5x/Kconfig.

Move also common settings (CONFIG_SYS_CPU="arm926ejs" and
CONFIG_SYS_SOC="orion5x").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
10 years agokeystone: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:05 +0000 (07:11 +0900)]
keystone: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Keystone board select menu to keystone/Kconfig.

Move also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="keystone").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Tom Rini <trini@ti.com>
Cc: Vitaly Andrianov <vitalya@ti.com>
10 years agoomap5: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:04 +0000 (07:11 +0900)]
omap5: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the OMAP5 board select menu to omap5/Kconfig.

Move also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="omap5").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Tom Rini <trini@ti.com>
Cc: Lokesh Vutla <lokeshvutla@ti.com>
10 years agoomap4: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:03 +0000 (07:11 +0900)]
omap4: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the OMAP4 board select menu to omap4/Kconfig.

Move also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="omap4").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Tom Rini <trini@ti.com>
Cc: Lokesh Vutla <lokeshvutla@ti.com>
10 years agoomap3: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:02 +0000 (07:11 +0900)]
omap3: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the OMAP3 board select menu to omap3/Kconfig.

Move also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="omap3

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Tom Rini <trini@ti.com>
10 years agodavinci: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:01 +0000 (07:11 +0900)]
davinci: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Davinci board select menu to davinci/Kconfig.

Move also common settings (CONFIG_SYS_CPU="arm926ejs" and
CONFIG_SYS_SOC="davinci").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Tom Rini <trini@ti.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Sandeep Paulraj <s-paulraj@ti.com>
10 years agoexynos: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:11:00 +0000 (07:11 +0900)]
exynos: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Exynos board select menu to exynos/Kconfig.

Consolidate also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="exynos").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Minkyu Kang <mk7.kang@samsung.com>
10 years agokirkwood: kconfig: refactor Kconfig and defconfig
Masahiro Yamada [Sat, 30 Aug 2014 22:10:59 +0000 (07:10 +0900)]
kirkwood: kconfig: refactor Kconfig and defconfig

Becuase the board select menu in arch/arm/Kconfig is too big,
move the KirkWood board select menu to kirkwood/Kconfig.

Consolidate also common settings (CONFIG_SYS_CPU="arm926ejs" and
CONFIG_SYS_SOC="kirkwood").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Prafulla Wadasdkar <prafulla@marvell.com>
Cc: Luka Perkov <luka@openwrt.org>
10 years agoversatile: kconfig: move common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:10:58 +0000 (07:10 +0900)]
versatile: kconfig: move common settings

Move Versatile-specific settings to versatile/Kconfig.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agormobile: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:10:57 +0000 (07:10 +0900)]
rmobile: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Rmobile board select menu to rmobile/Kconfig.

Consolidate also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="rmobile").

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
10 years agotegra: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:10:56 +0000 (07:10 +0900)]
tegra: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Tegra board select menu to tegra/Kconfig.

Insert the Tegra SoC select menu between the arch select and the
board select.

 Architecture select
 |-- Tegra Platform (Tegra)
     |- Tegra SoC select (Tegra20 / 30 / 114 / 124)
        |- Board select

Consolidate also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="tegra*") and always "select" CONFIG_SPL as follows:

  config TEGRA
          bool
          select SPL

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Cc: Tom Warren <twarren@nvidia.com>
10 years agozynq: kconfig: move board select menu and common settings
Masahiro Yamada [Sat, 30 Aug 2014 22:10:55 +0000 (07:10 +0900)]
zynq: kconfig: move board select menu and common settings

Becuase the board select menu in arch/arm/Kconfig is too big,
move the Zynq board select menu to zynq/Kconfig.

Consolidate also common settings (CONFIG_SYS_CPU="armv7" and
CONFIG_SYS_SOC="zynq").

Refactor board/xilinx/zynq/MAINTAINERS too.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Tested-by: Michal Simek <michal.simek@xilinx.com>
10 years agoarm: Add missing .vectors section to linker scripts
Benoît Thébaudeau [Thu, 21 Aug 2014 13:43:11 +0000 (15:43 +0200)]
arm: Add missing .vectors section to linker scripts

Commit 41623c9 'arm: move exception handling out of start.S files' missed some
linker scripts. Hence, some boards no longer had exception handling linked since
this commit. Restore the original behavior by adding the .vectors section to
these linker scripts.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau.dev@gmail.com>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
10 years agoarm/km: disable subpage write for km_kirkwood_pci and kmsuv31 target
Holger Brunck [Fri, 15 Aug 2014 08:51:48 +0000 (10:51 +0200)]
arm/km: disable subpage write for km_kirkwood_pci and kmsuv31 target

Newer FLASH types used on these boards don't allow writing of subpages.
So disable subpage write in the NAND driver. Additionally we need to
tell the UBI layer in the kernel that he also should only write 2048
bytes. This is done with an additional command line parameter for the
kernel commandline.

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>

10 years agoarm/kirkwood/nand: allow forced disabling for subpage writes
Holger Brunck [Fri, 15 Aug 2014 08:51:47 +0000 (10:51 +0200)]
arm/kirkwood/nand: allow forced disabling for subpage writes

Make it configurable to disable subpage writes like the DaVinci NAND
driver already does.

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
cc: Scott Wood <scottwood@freescale.com>

10 years agovexpress_aemv8a.h: Enable CONFIG_CMD_BOOTI and CONFIG_CMD_UNZIP
Tom Rini [Thu, 14 Aug 2014 10:42:38 +0000 (06:42 -0400)]
vexpress_aemv8a.h: Enable CONFIG_CMD_BOOTI and CONFIG_CMD_UNZIP

Add support for booting Images and for unzipping Image.gz files.

Signed-off-by: Tom Rini <trini@ti.com>
10 years agovexpress_aemv8a.h: Clean up the config
Tom Rini [Thu, 14 Aug 2014 10:42:37 +0000 (06:42 -0400)]
vexpress_aemv8a.h: Clean up the config

- Drop DEBUG
- Drop defines we can use the default of.
- Provide a larger malloc pool.
- Correct default locations for kernel / initrd / device tree

Signed-off-by: Tom Rini <trini@ti.com>
10 years agocmd_bootm.c: Add 'booti' for ARM64 Linux kernel Images
Tom Rini [Thu, 14 Aug 2014 10:42:36 +0000 (06:42 -0400)]
cmd_bootm.c: Add 'booti' for ARM64 Linux kernel Images

The default format for arm64 Linux kernels is the "Image" format,
described in Documentation/arm64/booting.txt.  This, along with an
optional gzip compression on top is all that is generated by default.
The Image format has a magic number within the header for verification,
a text_offset where the Image must be run from, an image_size that
includes the BSS and reserved fields.

This does not support automatic detection of a gzip compressed image.

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoarm64: Correct passing of Linux kernel args
Tom Rini [Thu, 14 Aug 2014 10:42:35 +0000 (06:42 -0400)]
arm64: Correct passing of Linux kernel args

The Documentation/arm64/booting.txt document says that pass in x1/x2/x3
as 0 as they are reserved for future use.

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoarm: convert Cygnus and NSP boards to Kconfig
Steve Rae [Mon, 11 Aug 2014 20:58:26 +0000 (13:58 -0700)]
arm: convert Cygnus and NSP boards to Kconfig

Convert the bcm958300k and the bcm958622hr boards from "boards.cfg" to Kconfig.

Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: add Cygnus and NSP boards
Scott Branden [Mon, 11 Aug 2014 20:58:25 +0000 (13:58 -0700)]
arm: add Cygnus and NSP boards

The bcm_ep board configuration is used by a number of boards
including Cygnus and NSP.
Add builds for the bcm958300k and the bcm958622hr boards.

Signed-off-by: Scott Branden <sbranden@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: bcmnsp: Add bcmnsp u-architecture
Scott Branden [Mon, 11 Aug 2014 20:58:24 +0000 (13:58 -0700)]
arm: bcmnsp: Add bcmnsp u-architecture

Base support for the Broadcom NSP SoC.
Based on iproc-common and the SoC specific reset function.

Signed-off-by: Scott Branden <sbranden@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: bcmcygnus: Add bcmcygnus u-architecture
Scott Branden [Mon, 11 Aug 2014 20:58:23 +0000 (13:58 -0700)]
arm: bcmcygnus: Add bcmcygnus u-architecture

Base support for the Broadcom Cygnus SoC.
Based on iproc-common and the SoC specific reset function.

Signed-off-by: Scott Branden <sbranden@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: iproc: Initial commit of iproc architecture code
Scott Branden [Mon, 11 Aug 2014 20:58:22 +0000 (13:58 -0700)]
arm: iproc: Initial commit of iproc architecture code

The iproc architecture code is present in several Broadcom
chip architectures, including Cygnus and NSP.

Signed-off-by: Scott Branden <sbranden@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: vf610: add NFC clock support
Stefan Agner [Wed, 6 Aug 2014 08:59:36 +0000 (10:59 +0200)]
arm: vf610: add NFC clock support

Add NFC (NAND Flash Controller) clock support and enable them
at board initialization time.

Signed-off-by: Stefan Agner <stefan@agner.ch>
10 years agoarm: vf610: add NFC pin mux
Stefan Agner [Wed, 6 Aug 2014 08:59:35 +0000 (10:59 +0200)]
arm: vf610: add NFC pin mux

Add pin mux for NAND Flash Controller (NFC). NAND can be connected
using 8 or 16 data lines, this patch adds pin mux entries for all
16 data lines.

Signed-off-by: Stefan Agner <stefan@agner.ch>
10 years agoMAINTAINERS: change the status of vexpress board to Orphan
Masahiro Yamada [Mon, 4 Aug 2014 01:30:32 +0000 (10:30 +0900)]
MAINTAINERS: change the status of vexpress board to Orphan

The email address of Matt Waddel is no longer working.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Alexei Fedorov <alexie.fedorov@arm.com>
10 years agoARM: Fix overflow in MMU setup
Marek Vasut [Sun, 3 Aug 2014 23:45:46 +0000 (01:45 +0200)]
ARM: Fix overflow in MMU setup

The patch fixes a corner case where adding size to DRAM start resulted
in a value (1 << 32), which in turn overflew the u32 computation, which
resulted in 0 and it therefore prevented correct setup of the MMU tables.

The addition of DRAM bank start and it's size can end up right at the end
of the address space in the special case of a machine with enough memory.
To prevent this overflow, shift the start and size separately and add them
only after they were shifted.

Hopefully, we only have systems in tree which have DRAM size aligned to
1MiB boundary. If not, this patch would break such systems. On the other
hand, such system would be broken by design anyway.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
10 years agoarm: bcm281xx: add board with Ethernet capability
Steve Rae [Sat, 2 Aug 2014 03:37:17 +0000 (20:37 -0700)]
arm: bcm281xx: add board with Ethernet capability

Add board which has Broadcom StarFighter2 Ethernet capability.

Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: bcm281xx: net: Add Ethernet Driver
Jiandong Zheng [Sat, 2 Aug 2014 03:37:16 +0000 (20:37 -0700)]
arm: bcm281xx: net: Add Ethernet Driver

The Broadcom StarFighter2 Ethernet driver is used in multiple Broadcom
SoC(s) and:
- supports multiple MAC blocks,
- provides support for the Broadcom GMAC.
This driver requires MII and PHYLIB.

Signed-off-by: Jiandong Zheng <jdzheng@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoarm: bcm281xx: Add Ethernet Clock support
Jiandong Zheng [Sat, 2 Aug 2014 03:37:15 +0000 (20:37 -0700)]
arm: bcm281xx: Add Ethernet Clock support

Enable Ethernet clock when Broadcom StarFighter2 Ethernet block
(CONFIG_BCM_SF2_ETH) is enabled.

Signed-off-by: Jiandong Zheng <jdzheng@broadcom.com>
Signed-off-by: Steve Rae <srae@broadcom.com>
10 years agoARM: enable ARMv7 virt support for the Arndale board
Andre Przywara [Fri, 1 Aug 2014 11:35:44 +0000 (13:35 +0200)]
ARM: enable ARMv7 virt support for the Arndale board

To enable hypervisors utilizing the ARMv7 virtualization extension
on the Arndale board, add the simple SMP pen address writer function
and add the required configuration variables to switch all cores to
HYP mode before launching the OS.
This allows booting KVM and Xen directly from u-boot.

Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Andre Przywara <andre.przywara@linaro.org>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
10 years agoarm: ep9315: Add .vectors section to lds and remove obsolete lds
Sergey Kostanbaev [Mon, 28 Jul 2014 08:08:01 +0000 (16:08 +0800)]
arm: ep9315: Add .vectors section to lds and remove obsolete lds

However ep9315 don't use
interrupt vectors during startup, but _startup symbol is used inside uboot to
calculate actual monitor size.

Signed-off-by: Sergey Kostanbaev <sergey.kostanbaev@gmail.com>
Cc: albert.u.boot@aribaud.net
10 years agosocfpga: cleanup socfpga_dw_mmc
Pavel Machek [Mon, 21 Jul 2014 11:30:19 +0000 (13:30 +0200)]
socfpga: cleanup socfpga_dw_mmc

Cleanups as suggested by wd on mailing list.

Signed-off-by: Pavel Machek <pavel@denx.de>
Acked-by: Chin Liang See <clsee@altera.com>
10 years agosocfpga: initialize designware ethernet
Pavel Machek [Mon, 14 Jul 2014 12:14:17 +0000 (14:14 +0200)]
socfpga: initialize designware ethernet

Enable initialization fo designware ethernet controller. With this
patch, ethernet works in my configuration, provided I set ethernet
address in the environment.

Signed-off-by: Pavel Machek <pavel@denx.de>
10 years agonios2: rebase nios2-generic board to 3c120 reference design
Thomas Chou [Sat, 30 Aug 2014 09:45:23 +0000 (17:45 +0800)]
nios2: rebase nios2-generic board to 3c120 reference design

Though nios2-generic board meant to be a template, it is helpful
to be able to test on a real hardware. As the nios2 linux is
developed and tested on a 3c120 FPGA based Golden Hardware Reference
Design, it makes sense to rebase nios2-generic on this FPGA design.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
10 years agonios2: link to CONFIG_SYS_MONITOR_BASE and remove text_base hook
Thomas Chou [Thu, 28 Aug 2014 09:29:06 +0000 (17:29 +0800)]
nios2: link to CONFIG_SYS_MONITOR_BASE and remove text_base hook

This patch changes the link script to base at CONFIG_SYS_MONITOR_BASE.
Then we can remove the text_base hook in nios2-generic board.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
10 years agoserial: move nios2-yanu.h into opencores_yanu driver
Thomas Chou [Mon, 25 Aug 2014 09:43:12 +0000 (17:43 +0800)]
serial: move nios2-yanu.h into opencores_yanu driver

The nios2-yanu.h contains hardware registers and bits of
opencores yanu. As there is no other user of this header
, it should be moved into the driver.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
CC: Renato Andreola <renato.andreola@imagos.it>
10 years agonios2: move nios2.h to arch asm directory
Thomas Chou [Mon, 25 Aug 2014 09:09:07 +0000 (17:09 +0800)]
nios2: move nios2.h to arch asm directory

The nios2.h is nios2 cpu specific, and should go arch asm
directory.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
10 years agonios2: divide nios2-io.h into each specific drivers and remove it
Thomas Chou [Mon, 25 Aug 2014 08:50:14 +0000 (16:50 +0800)]
nios2: divide nios2-io.h into each specific drivers and remove it

The nios2-io.h defines hardware registers and bits of several FPGA
IP cores. It could be divided in to the specific drivers, including
altera timer, altera sysid, altera uart and altera jtag uart. The
altera pio and altera spi drivers use their own hardware definitions.
The removal of nios2-io.h will help modularity and maintenance.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
10 years agonios2: remove epled driver
Thomas Chou [Mon, 25 Aug 2014 07:57:06 +0000 (15:57 +0800)]
nios2: remove epled driver

The epled driver was replaced by altera_pio and gpio_led.

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
10 years agosocfpga: Fix SOCFPGA build error for Altera dev kit
Chin Liang See [Tue, 22 Jul 2014 09:28:35 +0000 (04:28 -0500)]
socfpga: Fix SOCFPGA build error for Altera dev kit

To fix the build error when build for Altera dev kit, not
virtual target. At same time, set the build for Altera dev
kit as default instead virtual target. With that, U-Boot
is booting well and SPL still lack of few drivers.

Signed-off-by: Chin Liang See <clsee@altera.com>
Cc: Pavel Machek <pavel@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Tom Rini <trini@ti.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
10 years agosocfpga: fix clock manager register definition
Pavel Machek [Sat, 19 Jul 2014 21:57:59 +0000 (23:57 +0200)]
socfpga: fix clock manager register definition

Structure defining clock manager hardware was wrong, leading to
wrong registers being accessed and hang in MMC init.

This fixes structure to match hardware.

Signed-off-by: Pavel Machek <pavel@denx.de>
10 years agoarm: include config.h in arch/arm/lib/vectors.S
Christian Riesch [Mon, 7 Jul 2014 09:07:25 +0000 (11:07 +0200)]
arm: include config.h in arch/arm/lib/vectors.S

config.h is required for CONFIG_SYS_DV_NOR_BOOT_CFG.

Signed-off-by: Christian Riesch <christian.riesch@omicron.at>
Reported-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
10 years agoARM:asm:io.h use static inline
Jeroen Hofstee [Sun, 22 Jun 2014 21:10:39 +0000 (23:10 +0200)]
ARM:asm:io.h use static inline

When compiling u-boot with W=1 the extern inline void for
read* is likely causing the most noise. gcc / clang will
warn there is never a actual declaration for these functions.
Instead of declaring these extern make them static inline so
it is actually declared.

cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
10 years agoMerge branch 'master' of git://git.denx.de/u-boot-ti
Tom Rini [Fri, 29 Aug 2014 17:47:42 +0000 (13:47 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-ti

10 years agoMerge git://git.denx.de/u-boot-usb
Tom Rini [Fri, 29 Aug 2014 15:15:18 +0000 (11:15 -0400)]
Merge git://git.denx.de/u-boot-usb

10 years agoMerge branch 'zynq' of git://www.denx.de/git/u-boot-microblaze
Tom Rini [Fri, 29 Aug 2014 15:07:35 +0000 (11:07 -0400)]
Merge branch 'zynq' of git://denx.de/git/u-boot-microblaze

10 years agoMerge branch 'master' of git://git.denx.de/u-boot-tegra
Tom Rini [Fri, 29 Aug 2014 15:07:10 +0000 (11:07 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-tegra

10 years agoMerge branch 'master' of git://www.denx.de/git/u-boot-imx
Tom Rini [Fri, 29 Aug 2014 15:06:51 +0000 (11:06 -0400)]
Merge branch 'master' of git://denx.de/git/u-boot-imx

10 years agoMerge branch 'master' of http://git.denx.de/u-boot-sunxi
Tom Rini [Fri, 29 Aug 2014 15:06:26 +0000 (11:06 -0400)]
Merge branch 'master' of git.denx.de/u-boot-sunxi

10 years agousb: hub: don't check CONNECTION in hub_port_reset()
Stephen Warren [Thu, 7 Aug 2014 23:07:59 +0000 (17:07 -0600)]
usb: hub: don't check CONNECTION in hub_port_reset()

One specific USB 3.0 device behaves strangely when reset by
usb_new_device()'s call to hub_port_reset(). For some reason, the device
appears to briefly drop off the bus when this second bus reset is
executed, yet if we retry this loop, it'll eventually come back after
another two resets.

If USB bus reset is executed over and over within usb_new_device()'s call
to hub_port_reset(), I see the following sequence of results, which
repeats as long as you want:

1) STAT_C_CONNECTION = 1 STAT_CONNECTION = 0  USB_PORT_STAT_ENABLE 0
2) STAT_C_CONNECTION = 1 STAT_CONNECTION = 1  USB_PORT_STAT_ENABLE 0
3) STAT_C_CONNECTION = 1 STAT_CONNECTION = 1  USB_PORT_STAT_ENABLE 1

The device in question is a SanDisk Ultra USB 3.0 16GB memory stick with
USB VID/PID 0x0781/0x5581.

In order to allow this device to work with U-Boot, ignore the
{C_,}CONNECTION bits in the status/change registers, and only use the
ENABLE bit to determine if the reset was successful.

To be honest, extensive investigation has failed to determine why this
problem occurs. I'd love to know! I don't know if it's caused by:
* A HW bug in the device
* A HW bug in the Tegra USB controller
* A SW bug in the U-Boot Tegra USB driver
* A SW bug in the U-Boot USB core

This issue only occurs when the device's USB3 pins are attached to the
host; if only the USB2 pins are connected the issue does not occur. The
USB3 controller on Tegra is in reset, so is not actively communicating
with the device at all - a USB3 analyzer confirms this. Slightly
unplugging the device (so the USB3 pins don't contact) or using a USB2
cable or hub as an intermediary avoids the problem. For some reason,
the Linux kernel (either on the same Tegra board, or on an x86 host)
has no issue with the device, and I observe no disconnections during
reset.

This change won't affect any USB device that already works, since such
devices could not currently be triggering the error return this patch
removes, or they wouldn't be working currently.

However, this patch is quite reliable in practice, hence I hope it's
acceptable to solve the problem.

The only potential fallout I can see from this patch is:

* A broken device that triggers C_CONNECTION/!CONNECTION now causes the
  loop in hub_port_reset() to run multiple times. If it never succeeds,
  this will cause "usb start" to take roughly 1s extra to execute.

* If the user unplugs a device while hub_port_reset() is executing, and
  very quickly swaps in a new device, hub_port_reset() might succeed on
  the new device. This would mean that any information cached about the
  original device (from the descriptor read in usb_new_device(), which
  simply caches the max packet size) might be invalid, which would cause
  problems talking to the new device. However, without this change, the
  new device wouldn't work anyway, so this is probably not much of a
  loss.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
10 years agousb: Handle -ENODEV from usb_lowlevel_init()
Marek Vasut [Fri, 1 Aug 2014 01:09:53 +0000 (03:09 +0200)]
usb: Handle -ENODEV from usb_lowlevel_init()

As we support both Host and Device mode operation, an OTG controller
can return -ENODEV on a port which it found to be in Device mode during
Host mode scan for devices. In case -ENODEV is returned, print that the
port is not available and continue instead of screaming a bloody error
message.

Signed-off-by: Marek Vasut <marex@denx.de>
10 years agoREADME.kconfig: document backward compatibility "make *_config"
Masahiro Yamada [Thu, 28 Aug 2014 01:56:55 +0000 (10:56 +0900)]
README.kconfig: document backward compatibility "make *_config"

Commit 3ff291f371fa9858426774f3732924bacb61ed1c
(kconfig: convert Kconfig helper script into a shell script)
restored "<board>_config" target for backward compatibility.
It should be documented.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
10 years agotools/genboardscfg.py: change shebang into /usr/bin/env python2
Masahiro Yamada [Wed, 27 Aug 2014 05:05:51 +0000 (14:05 +0900)]
tools/genboardscfg.py: change shebang into /usr/bin/env python2

This tool only works on python 2 (python 2.6 or lator).

Change the shebang to make sure the script is run by python 2
and clearly say the supported version in the comment block.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agonet: cpsw: am335x: Drop constant link checking from rx/tx path's
Stefan Roese [Mon, 25 Aug 2014 09:26:19 +0000 (11:26 +0200)]
net: cpsw: am335x: Drop constant link checking from rx/tx path's

We noticed on the DXR2 platform (AM335x with a SMSC LAN9303 switch connected
to the CPSW MAC) that the network performance in U-Boot is quite poor. Only
when the transfer is started without a cable connected, and the cable is
plugged after the first timeout "T" occured, an increased in performance
can be seen. Debugging has revealed, that the cpsw driver has constant
link checking builtin into the rx and tx functions. This results in the
bad performance and seems to be unnecessary. The link has already been
checked in the init function, before the transfer is started. This usually
is sufficient.

BTW: I have seen no other network driver in U-Boot so far, that constantly
checks for link in the rx / tx functions.

The performance numbers on the DXR2 board are:

0.56 MiB/s cpsw_check_link() in rx and tx path
0.87 MiB/s cpsw_check_link() only in tx path
1.0  MiB/s cpsw_check_link() only in rx path
2.7  MiB/s no cpsw_check_link() in rx and tx path

So with this patch the network performance on DXR2 increases from 0.56
to 2.7 MiB/s (nearly 5 times as fast).

Signed-off-by: Stefan Roese <sr@denx.de>
Tested-by: Samuel Egli <samuel.egli@siemens.com>
Tested-by: Heiko Schocher <hs@denx.de>
Cc: Vladimir Koutny <vladimir.koutny@streamunlimited.com>
Cc: Mugunthan V N <mugunthanvnm@ti.com>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
Cc: Tom Rini <trini@ti.com>
10 years agotools/genboardscfg.py: improve performance
Masahiro Yamada [Mon, 25 Aug 2014 03:39:48 +0000 (12:39 +0900)]
tools/genboardscfg.py: improve performance

I guess some developers are already getting sick of this tool
because it generally takes a few minites to generate the boards.cfg
on a reasonable computer.

The idea popped up on my mind was to skip Makefiles and
to run script/kconfig/conf directly.
This tool should become about 4 times faster.
You might still not be satisfied, but better than doing nothing.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: check if the boards.cfg is up to date
Masahiro Yamada [Mon, 25 Aug 2014 03:39:47 +0000 (12:39 +0900)]
tools/genboardscfg.py: check if the boards.cfg is up to date

It looks silly to regenerate the boards.cfg even when it is
already up to date.

The tool should exit with doing nothing if the boards.cfg is newer
than any of defconfig, Kconfig and MAINTAINERS files.

Specify -f (--force) option to get the boards.cfg regenerated
regardless its time stamp.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: fix minor problems on termination
Masahiro Yamada [Mon, 25 Aug 2014 03:39:46 +0000 (12:39 +0900)]
tools/genboardscfg.py: fix minor problems on termination

This tool deletes the incomplete boards.cfg
if it encounters an error or is is terminated by the user.

I notice some problems even though they rarely happen.

[1] The boards.cfg is removed if the program is terminated
during __gen_boards_cfg() function but before boards.cfg
is actually touched.  In this case, the previous boards.cfg
should be kept as it is.

[2] If an error occurs while deleting the incomplete boards.cfg,
the program throws another exception.  This hides the privious
exception and we will not be able to know the real cause.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: wait for unfinished subprocesses before error-out
Masahiro Yamada [Mon, 25 Aug 2014 03:39:45 +0000 (12:39 +0900)]
tools/genboardscfg.py: wait for unfinished subprocesses before error-out

When an error occurs or the program is terminated by the user
on the way, the destructer __del__ of class Slot is invoked and
the work directories are removed.

We have to make sure there are no subprocesses (in this case,
"make O=<work_dir> ...") using the work directories before
removing them.  Otherwise the subprocess spits a bunch of error
messages possibly causing more problems.  Perhaps some users
may get upset to see too many error messages.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: be tolerant of insane Kconfig
Masahiro Yamada [Mon, 25 Aug 2014 03:39:44 +0000 (12:39 +0900)]
tools/genboardscfg.py: be tolerant of insane Kconfig

The tools/genboardscfg.py expects all the Kconfig and defconfig are
written correctly.  Imagine someone accidentally has broken a board.
Error-out just for one broken board is annoying for the other
developers.  Let the tool skip insane boards and continue processing.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: be tolerant of missing MAINTAINERS
Masahiro Yamada [Mon, 25 Aug 2014 03:39:43 +0000 (12:39 +0900)]
tools/genboardscfg.py: be tolerant of missing MAINTAINERS

tools/genboardscfg.py expects all the boards have MAINTAINERS.
If someone adds a new board but misses to add its MAINTAINERS file,
tools/genboardscfg.py fails to generate the boards.cfg file.
It is annoying for the other developers.

This commit allows tools/genboardscfg.py to display warning messages
and continue processing even if some MAINTAINERS files are missing
or have broken formats.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agotools/genboardscfg.py: ignore defconfigs starting with a dot
Masahiro Yamada [Mon, 25 Aug 2014 03:39:42 +0000 (12:39 +0900)]
tools/genboardscfg.py: ignore defconfigs starting with a dot

Kconfig in U-Boot creates a temporary file configs/.tmp_defconfig
during processing "make <board>_defconfig".  The temporary file
might be left over for some reasons.

Just in case, tools/genboardscfg.py should make sure to
not read such garbage files.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agoCorrect sandbox filesystem commands in FIT image test
Simon Glass [Fri, 22 Aug 2014 20:26:44 +0000 (14:26 -0600)]
Correct sandbox filesystem commands in FIT image test

The host filesystem name has changed, so update the tests. The tests now
run again correctly:

$ make O=b/sandbox sandbox_defconfig all
...
$ test/image/test-fit.py -u b/sandbox/u-boot
FIT Tests

=========
Kernel load
Kernel + FDT load
Kernel + FDT + Ramdisk load

Tests passed
Caveat: this is only a sanity check - test coverage is poor

Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agoFix test failure caused by bad handling of ramdisk
Simon Glass [Fri, 22 Aug 2014 20:26:43 +0000 (14:26 -0600)]
Fix test failure caused by bad handling of ramdisk

Commit e3a5bbce broke the FIT image tests by not loading a ramdisk even if
a load address is provided in the FIT. The rationale was that a load address
of 0 should be considered to mean 'do not load'.

Add a new load operation which supports this feature, so that the ramdisk
will be loaded if a non-zero load address is provided.

Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agokconfig: add CONFIG_CC_OPTIMIZE_FOR_SIZE
Masahiro Yamada [Fri, 22 Aug 2014 10:42:29 +0000 (19:42 +0900)]
kconfig: add CONFIG_CC_OPTIMIZE_FOR_SIZE

Copy the Kconfig option from "init/Kconfig" of Linux v3.16 tag
and adjust the help document.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoscripts: refetch scripts/setlocalversion from Linux 3.16
Masahiro Yamada [Fri, 22 Aug 2014 10:42:28 +0000 (19:42 +0900)]
scripts: refetch scripts/setlocalversion from Linux 3.16

Now we have CONFIG_LOCALVERSION and CONFIG_LOCALVERSION_AUTO
in Kconfig so we can use scripts/setlocalversion without
any adjustment.  Copy it from Linux 3.16 as is.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agokconfig: add CONFIG_LOCALVERSION and CONFIG_LOCALVERSION_AUTO
Masahiro Yamada [Fri, 22 Aug 2014 10:42:27 +0000 (19:42 +0900)]
kconfig: add CONFIG_LOCALVERSION and CONFIG_LOCALVERSION_AUTO

Copy Kconfig options from "init/Kconfig" of Linux v3.16 tag
and adjust some parts of the help document.

Move CONFIG_SPL, CONFIG_TPL, ... etc. to "Boot images" menu.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agobuildman: run genboardscfg.py all the time
Masahiro Yamada [Fri, 22 Aug 2014 05:33:41 +0000 (14:33 +0900)]
buildman: run genboardscfg.py all the time

This commit makes sure boards.cfg is up to date before starting
the build tests.  tools/genboardscfg.py exits immediately printing
"boards.cfg is up to date. Nothing to do." when boards.cfg is
already new.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agoMAKEALL: run genboardscfg.py all the time
Masahiro Yamada [Fri, 22 Aug 2014 05:33:40 +0000 (14:33 +0900)]
MAKEALL: run genboardscfg.py all the time

This commit makes sure boards.cfg is up to date before starting
the build tests.  tools/genboardscfg.py exits immediately printing
"boards.cfg is up to date. Nothing to do." when boards.cfg is
already new.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agotools/genboardscfg.py: fix a bug of MAINTAINERS handling
Masahiro Yamada [Fri, 22 Aug 2014 05:10:43 +0000 (14:10 +0900)]
tools/genboardscfg.py: fix a bug of MAINTAINERS handling

This patch fixes a minor problem:
If a block without "F:   configs/*_defconfig" is followed by another
block with "F:   configs/*_defconfig", the maintainers from the
former block are squashed into the latter.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agosamsung: s5p_goni: fix: Add missing definitions for G_DNL_UMS gadget
Łukasz Majewski [Fri, 22 Aug 2014 07:12:58 +0000 (09:12 +0200)]
samsung: s5p_goni: fix: Add missing definitions for G_DNL_UMS gadget

The commit (SHA1: 8fc171318e352) reintroduced correct values for vendor and
product IDs required for UMS gadget to work properly either at Windows or
Linux.

This data was missing for GONI target, so this commit corrects this mistake.

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Acked-by: Robert Baldyga <r.baldyga@samsung.com>
Acked-by: Minkyu Kang <mk7.kang@samsung.com>
10 years agoMerge branch 'master' of git://git.denx.de/u-boot-arm
Tom Rini [Thu, 28 Aug 2014 17:03:25 +0000 (13:03 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-arm

10 years agoMerge branch 'patman' of http://git.denx.de/u-boot-x86
Tom Rini [Thu, 28 Aug 2014 15:49:12 +0000 (11:49 -0400)]
Merge branch 'patman' of git.denx.de/u-boot-x86

10 years agopatman: Support the 'reverse' option for 'git log'
Simon Glass [Fri, 15 Aug 2014 03:59:11 +0000 (21:59 -0600)]
patman: Support the 'reverse' option for 'git log'

This option is currently not supported, but needs to be, for buildman to
operate as expected.

Reported-by: York Sun <yorksun@freescale.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agomtd,ubi,ubifs: sync with linux v3.15
Heiko Schocher [Tue, 15 Jul 2014 14:08:43 +0000 (16:08 +0200)]
mtd,ubi,ubifs: sync with linux v3.15

snyc with linux v3.15:

commit 1860e379875dfe7271c649058aeddffe5afd9d0d
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Sun Jun 8 11:19:54 2014 -0700

    Linux 3.15

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Tom Rini <trini@ti.com>
10 years agomtd, ubi, ubifs: update for the sync with linux v3.14
Heiko Schocher [Tue, 15 Jul 2014 14:08:42 +0000 (16:08 +0200)]
mtd, ubi, ubifs: update for the sync with linux v3.14

while playing with the new mtd/ubi/ubifs sync, found some
small updates for it:

- add del_mtd_partition() to include/linux/mtd/mtd
- mtd: add a debug_printf
- remove some not used functions

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Tom Rini <trini@ti.com>
10 years agomtd, ubi, ubifs: resync with Linux-3.14
Heiko Schocher [Tue, 24 Jun 2014 08:10:04 +0000 (10:10 +0200)]
mtd, ubi, ubifs: resync with Linux-3.14

resync ubi subsystem with linux:

commit 455c6fdbd219161bd09b1165f11699d6d73de11c
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Sun Mar 30 20:40:15 2014 -0700

    Linux 3.14

A nice side effect of this, is we introduce UBI Fastmap support
to U-Boot.

Signed-off-by: Heiko Schocher <hs@denx.de>
Signed-off-by: Tom Rini <trini@ti.com>
Cc: Marek Vasut <marex@denx.de>
Cc: Sergey Lapin <slapin@ossfans.org>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Joerg Krause <jkrause@posteo.de>
10 years agolib, linux: move linux specific defines to linux/compat.h
Heiko Schocher [Tue, 24 Jun 2014 08:10:03 +0000 (10:10 +0200)]
lib, linux: move linux specific defines to linux/compat.h

- move linux specific defines from usb and video code
  into linux/compat.h
- move common linux specific defines from include/ubi_uboot.h
  to linux/compat.h
- add for new mtd/ubi/ubifs sync new needed linux specific
  defines to linux/compat.h

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Anatolij Gustschin <agust@denx.de>
[trini: Add spin_lock_irqsave/spin_unlock_irqrestore dummies from
usb/lin_gadet_compat.h]
Signed-off-by: Tom Rini <trini@ti.com>
10 years agolinux include: add ERR_CAST
Heiko Schocher [Tue, 24 Jun 2014 08:10:02 +0000 (10:10 +0200)]
linux include: add ERR_CAST

add missing ERR_CAST to linux/err.h as it is needed for ubi/ubifs support

Signed-off-by: Heiko Schocher <hs@denx.de>
10 years agolib, list_sort: add list_sort from linux 3.14
Heiko Schocher [Tue, 24 Jun 2014 08:10:01 +0000 (10:10 +0200)]
lib, list_sort: add list_sort from linux 3.14

from linux 3.14:

commit 455c6fdbd219161bd09b1165f11699d6d73de11c
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Sun Mar 30 20:40:15 2014 -0700

    Linux 3.14

Needed for the MTD/UBI/UBIFS resync

Just copied the files from Linux, and added in the c-file
the "#define __UBOOT__" for adding U-Boot special code. In
this case we use this just for adding including U-Boot
headers.

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Sergey Lapin <slapin@ossfans.org>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Tom Rini <trini@ti.com>
10 years agolib, rbtree: resync with Linux-3.14
Heiko Schocher [Tue, 24 Jun 2014 08:10:00 +0000 (10:10 +0200)]
lib, rbtree: resync with Linux-3.14

resync with linux:

commit 455c6fdbd219161bd09b1165f11699d6d73de11c
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Sun Mar 30 20:40:15 2014 -0700

    Linux 3.14

Needed for the MTD/UBI/UBIFS resync

Just copied the files from Linux, changed the license file header,
and add in the c-file:

+#define __UBOOT__
 #include <linux/rbtree_augmented.h>
+#ifndef __UBOOT__
 #include <linux/export.h>
+#else
+#include <ubi_uboot.h>
+#endif

so, it compiles for U-Boot.

Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Sergey Lapin <slapin@ossfans.org>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Tom Rini <trini@ti.com>
10 years agopcm051: use ti_am335x_common.h config
Matwey V. Kornilov [Sat, 26 Jul 2014 14:48:45 +0000 (18:48 +0400)]
pcm051: use ti_am335x_common.h config

Include general configs/ti_am335x_common.h and drop redundant #defines.

Signed-off-by: Matwey V. Kornilov <matwey.kornilov@gmail.com>
10 years agoARM: DRA: Enable VTT regulator
Lokesh Vutla [Mon, 4 Aug 2014 14:12:24 +0000 (19:42 +0530)]
ARM: DRA: Enable VTT regulator

DRA7 evm REV G and later boards uses a vtt regulator for DDR3 termination
and this is controlled by gpio7_11. Configuring gpio7_11.
The pad A22(offset 0x3b4) is used by gpio7_11 on REV G and later boards,
and left unused on previous boards, so it is safe enough to enable gpio
on all DRA7 boards.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
10 years agoam335x_evm: Convert CONFIG_CONS_INDEX into a menu choice
Tom Rini [Fri, 1 Aug 2014 13:53:24 +0000 (09:53 -0400)]
am335x_evm: Convert CONFIG_CONS_INDEX into a menu choice

- Drop CONFIG_SERIAL[1-6] and use CONFIG_CONS_INDEX tests instead
- Add choice and help text to board/ti/am335x/Kconfig
- Correct comment about IDK in board/ti/am335x/mux.c
- Remove am335x_evm_uart* defconfig files as they're just variations
  on a config option now.

Signed-off-by: Tom Rini <trini@ti.com>
10 years agocm-t54: convert to generic board
Dmitry Lifshitz [Thu, 31 Jul 2014 11:30:41 +0000 (14:30 +0300)]
cm-t54: convert to generic board

Use generic board setup functions by defining
CONFIG_SYS_GENERIC_BOARD.

Signed-off-by: Dmitry Lifshitz <lifshitz@compulab.co.il>
10 years agocm-t54: fix eMMC boot mode check
Dmitry Lifshitz [Thu, 31 Jul 2014 11:30:40 +0000 (14:30 +0300)]
cm-t54: fix eMMC boot mode check

Boot from eMMC boot partition corresponds to BOOT_DEVICE_MMC2
omap_bootmode, while BOOT_DEVICE_MMC2_2 corresponds to the user
data partition boot.

Fix mmc_get_env_part() boot mode check to use a correct value.

Signed-off-by: Dmitry Lifshitz <lifshitz@compulab.co.il>
10 years agocm-t54: fix EEPROM read return value check
Dmitry Lifshitz [Thu, 31 Jul 2014 11:30:39 +0000 (14:30 +0300)]
cm-t54: fix EEPROM read return value check

Fix cl_eeprom_read_mac_addr() return value check.
Fix long line codding style issue in board_init().

Signed-off-by: Dmitry Lifshitz <lifshitz@compulab.co.il>
10 years agoARM: DRA7: Enable software leveling for dra7
Sricharan R [Thu, 31 Jul 2014 06:35:50 +0000 (12:05 +0530)]
ARM: DRA7: Enable software leveling for dra7

Currently hw leveling is enabled by default on DRA7/72.
But the hardware team suggested to use sw leveling as hw leveling
is not characterized and seen some test case failures.
So enabling sw leveling on all DRA7 platforms.

Signed-off-by: Sricharan R <r.sricharan@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
10 years agoSOM: tam3517: convert to generic board
Jeroen Hofstee [Mon, 28 Jul 2014 21:34:42 +0000 (23:34 +0200)]
SOM: tam3517: convert to generic board

Cc: Raphael Assenat <raph@8d.com>
Cc: Stefano Babic <sbabic@denx.de>
Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
10 years agokeystone2: use EFUSE_BOOTROM information to configure PLLs
Vitaly Andrianov [Fri, 25 Jul 2014 19:23:19 +0000 (22:23 +0300)]
keystone2: use EFUSE_BOOTROM information to configure PLLs

This patch reads EFUSE_BOOTROM register to see the maximum supported
clock for CORE and TETRIS PLLs and configure them accordingly.

Acked-by: Murali Karicheri <m-karicheri2@ti.com>
Signed-off-by: Vitaly Andrianov <vitalya@ti.com>
Signed-off-by: Ivan Khoronzhuk <ivan.khoronzhuk@ti.com>
10 years agoboard/ti/dra7xx: add support for parallel NOR
pekon gupta [Tue, 22 Jul 2014 10:33:24 +0000 (16:03 +0530)]
board/ti/dra7xx: add support for parallel NOR

This patch adds support for parallel NOR device (S29GL512S10) present on J6-EVM.
The Flash device is connected to GPMC controller on chip-select[0] and accessed
as memory-mapped device. It has data-witdh=x16, capacity-64MBytes(512Mbits) and
is CFI compatible.

As multiple devices are share GPMC pins on this board, so following board
settings are required to detect NOR device:
     SW5.1 (NAND_BOOTn) = OFF (logic-1)
     SW5.2 (NOR_BOOTn)  = ON  (logic-0) /* Active-low */
     SW5.3 (eMMC_BOOTn) = OFF (logic-1)
     SW5.4 (QSPI_BOOTn) = OFF (logic-1)

And also set appropriate SYSBOOT configurations:
     SW3.1 (SYSBOOT[ 8])= ON  (logic-1) /* selects SYS_CLK1 speed */
     SW3.2 (SYSBOOT[ 9])= OFF (logic-0) /* selects SYS_CLK1 speed */
     SW3.3 (SYSBOOT[10])= ON  (logic-1) /* wait-pin monitoring = enabled */
     SW3.4 (SYSBOOT[11])= OFF (logic-0) /* device type: Non Muxed */
     SW3.5 (SYSBOOT[12])= OFF (logic-0) /* device type: Non Muxed */
     SW3.6 (SYSBOOT[13])= ON  (logic-1) /* device bus-width: 1(x16) */
     SW3.7 (SYSBOOT[14])= OFF (logic-0) /* reserved */
     SW3.8 (SYSBOOT[15])= ON  (logic-1) /* reserved */

Also, following changes are required to enable NOR Flash support in
dra7xx_evm board profile:

10 years agoboard/ti/dra7xx: add support for parallel NAND
pekon gupta [Tue, 22 Jul 2014 10:33:23 +0000 (16:03 +0530)]
board/ti/dra7xx: add support for parallel NAND

This patch adds support for x16 NAND device (MT29F2G16AAD) connected to GPMC
chip-select[0] on DRA7xx EVM.
As GPMC pins are shared by multiple devices, so in addition to this patch
following board settings are required for NAND device detection [1]:

  SW5.9 (GPMC_WPN)   = OFF (logic-1)
  SW5.1 (NAND_BOOTn) = ON  (logic-0) /* Active-low */
  SW5.2 (NOR_BOOTn)  = OFF (logic-1)
  SW5.3 (eMMC_BOOTn) = OFF (logic-1)
  SW5.4 (QSPI_BOOTn) = OFF (logic-1)

And also set appropriate SYSBOOT configurations
  SW2.1 (SYSBOOT[0]) = ON  (logic-1) /* selects NAND Boot */
  SW2.2 (SYSBOOT[1]) = OFF (logic-0) /* selects NAND Boot */
  SW2.3 (SYSBOOT[2]) = OFF (logic-0) /* selects NAND Boot */
  SW2.4 (SYSBOOT[3]) = OFF (logic-0) /* selects NAND Boot */
  SW2.5 (SYSBOOT[4]) = ON  (logic-1) /* selects NAND Boot */
  SW2.6 (SYSBOOT[5]) = ON  (logic-1) /* selects NAND Boot */
  SW2.7 (SYSBOOT[6]) = OFF (logic-0) /* reserved */
  SW2.8 (SYSBOOT[7]) = OFF (logic-0) /* reserved */

  SW3.1 (SYSBOOT[ 8])= ON  (logic-1) /* selects SYS_CLK1 speed */
  SW3.2 (SYSBOOT[ 9])= OFF (logic-0) /* selects SYS_CLK1 speed */
  SW3.3 (SYSBOOT[10])= ON  (logic-1) /* wait-pin monitoring = enabled */
  SW3.4 (SYSBOOT[11])= OFF (logic-0) /* device type: Addr/Data Muxed */
  SW3.5 (SYSBOOT[12])= ON  (logic-1) /* device type: Addr/Data Muxed */
  SW3.6 (SYSBOOT[13])= ON  (logic-1) /* device bus-width: 1(x16) */
  SW3.7 (SYSBOOT[14])= OFF (logic-0) /* reserved */
  SW3.8 (SYSBOOT[15])= ON  (logic-1) /* reserved */

Following changes are required in board.cfg to enable NAND on J6-EVM: