ARM: uncompress.c: copy executable to SDRAM if necessary

We used to relocate the executable to the current address. This does
not work when the executable runs from a readonly location like for
example NOR Flash. Test if we run from inside the available memory and
if we do, relocate to the current address as before. Otherwise copy
the executable to the start of memory and relocate to that address.
While at it add some comments to the code.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: Phytec-phyCORE-imx27: Register board env during runtime

Register the board specific environment during runtime using
defaultenv_append_directory() to make it available for multi
image support.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: i.MX bbu: Add update handler for external NOR boot

External NOR boot only requires copying the image to NOR Flash.
This also adds (un)protecting the flash which is required for
NOR Flash.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: Phytec-phyCORE-imx27: Register NOR/NAND update handlers

To make barebox_update work on the board.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: Phytec-phyCORE-imx27: Switch to multiimage support

Tested on the phyCORE-imx27 to boot on NOR and NAND using the
registered update handlers.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
param: Add support for long long read only dev param

Signed-off-by: Herve Codina <Herve.CODINA@celad.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
mtd: use long long dev param for size

Signed-off-by: Herve Codina <Herve.CODINA@celad.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: AM335x: Beaglebone: Fix memory setup for Beaglebone black

Commit 0d6392de4ad824a6553c0e3e3e18edef689a7c85 introduced a stripped
down device tree used for both white and black Beaglebone variants
that included the 256 MiB memory node from am335x-bone-common.dtsi.
This leads to the following error in the MLO:

    mmu: Critical Error: Can't request SDRAM region for ttb at 9fff4000

This patch removes the (for the Beaglebone black) invalid memory size
from the common device tree and instead registers the memory bank
manually in the board file.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
commands: gpio_direction_output: add missed VALUE parameter to help message

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: dts: i.MX51 babbage: remove unused hoggrp

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
dts: update to v3.15-rc6

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
dts: update to v3.15-rc7

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
dts: update to v3.15-rc8

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
dts: update to v3.16-rc1

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
boot: Fix boot -m

We have to continue when bootentries_collect succeeds, not when it fails.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
commands: ls: add ll as an alias for ls -l

This saves one second of user time on every interactive boot.

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: AM335x: beaglebone: remove obsolete config

The bootargs are now autogenerated by barebox and the hostname should
not be preconfigured.

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: AM335x: beaglebone: add simple script to change usb current limit

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM: versatile: drop redundant <mach/gpio.h>

The arch/arm/include/asm/gpio.h header file contains

  #ifndef CONFIG_GPIOLIB
  #include <mach/gpio.h>
  #else
  #include <asm-generic/gpio.h>
  #endif

We use CONFIG_GPIOLIB=y for the only mach-versatile
Versatile/PB board so there is no need of <mach/gpio.h>.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
i2c: versatile: add devicetree support

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>