S5P DRAM support

Signed-off-by: Alexey Galakhov <agalakhov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM tqma53: Add standard flash header

So that bootm detects the image as a barebox image.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM tqma53: switch to new environment

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
scripts/mkublheader: add program to produce an UBL image header

This image header is used for booting from SPI using the TI User
Boot Loader (UBL).

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Add bootargs script to boot on ext filesystems

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Cc: Brian Lilly <brian@crystalfontz.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Add support for the Crystalfontz CFA-10036 board

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Cc: Brian Lilly <brian@crystalfontz.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
hush getopt: shift argv arguments

Make the nonopt arguments to a script available starting from $1
after running getopt. This allows for scripts which use option
parsing but also have nonopts.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
defenv-2: Add usage information for bootargs scripts

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
defenv-2: improve boot script

- add usage information
- add option parsing:
  -v verbose
  -v -v more verbose
  -l list b´possible boot sources
  -d dryrun

The dryrun option sets the global variables necessary for booting
but does not actually boot the system. This way it is possible to
make additional adjustments to the boot variables and then invoke
bootm manually.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
string: add strim for ONFI code

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
nand_base: add ONFI flash detection

the code is taken from linux & u-boot implementations
Validated on an i.MX53 which gives the following log :
ONFI flash detected ... ONFI param page 0 valid
NAND device: Manufacturer ID: 0x2c, Chip ID: 0x38 (Micron MT29F8G08ABABAWP), page size: 4096, OOB size: 224

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
nand_imx: update to support onfi & 4k flashs

- add CMD_PARAM and read_param to get the ONFI structure
- fix OOB size for flash with 224 OOB on i.MX51/3
- add the same ecc layout as the one in the kernel for
  4k page flashs

Tested on an i.MX53.

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
MIPS: malta: register memory bank

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
MIPS: remove unused processor-specific constants and macros

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
mtd: fix 'write: Invalid argument' while writing to nand-bb devices

The 'off_t cur_ofs' variable was missed during the 64 bit conversion.
For the MEMGETBADBLOCK ioctl, a pointer to a loff_t is needed.

Also adjust the debug format strings.

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
filetype: add forgotten mips barebox filetype_str

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
ARM/MXS: the GPIO bitkeeper enable logic is inverse to the pullup enable logic

While a set bit enables the pullup (if exists) it disables the bitkeeper (if
exists). Both features are using the same register bit and only one of this
feature is present on a per pin base.

Signed-off-by: Juergen Beisert <jbe@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
commands/crc: assert newline after output with big offsets

This fixes

	barebox@Very long board name:/ crc32 -f /dev/mem 0x83f00000+0xfff
	CRC32 for /dev/mem 0x83fff000 ... 0x83fffffe ==> 0xa080584bbarebox@Very long board name:/

The problem here was that the return value of
lseek(fd, 0x83f00000, SEEK_SET) (which is 0x83f00000) was casted to an
int (which is -2081423360), returned to do_crc and interpreted as
error there without yielding another error message.

This also makes

	crc32 -f /dev/mem 0xffffffff+0x1

die on a NULL pointer exception instead of reporting:

	lseek: No error

:-)

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
input: Add i.MX matrix keypad driver

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
input: add i.MX51 platform code for matrix keypad driver

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