platform/kernel/u-boot.git
9 years agotools/kwbimage.c: fix build on darwin
Andreas Bießmann [Fri, 24 Oct 2014 21:39:11 +0000 (23:39 +0200)]
tools/kwbimage.c: fix build on darwin

kwbimage uses get_current_dir_name(3) which is a gnu extension and not
available on darwin host. Fix this by converting to portable getcwd(3)
function.

This patch fixes the following error:
---8<---
  HOSTCC  tools/kwbimage.o
tools/kwbimage.c:399:16: warning: implicit declaration of function 'get_current_dir_name' is invalid in C99 [-Wimplicit-function-declaration]
                        char *cwd = get_current_dir_name();
                                    ^
tools/kwbimage.c:399:10: warning: incompatible integer to pointer conversion initializing 'char *' with an expression of type 'int' [-Wint-conversion]
                        char *cwd = get_current_dir_name();
                              ^     ~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
...
Undefined symbols for architecture x86_64:
  "_get_current_dir_name", referenced from:
      _image_headersz_v1 in kwbimage.o
ld: symbol(s) not found for architecture x86_64
--->8---

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
Cc: Stefan Roese <sr@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
[agust: fixed getcwd() return warning]
Signed-off-by: Anatolij Gustschin <agust@denx.de>
9 years agoarm: mxs: Define bootscript env variable on m28evk
Marek Vasut [Sat, 11 Oct 2014 22:00:50 +0000 (00:00 +0200)]
arm: mxs: Define bootscript env variable on m28evk

The patch below failed to define the variable, so define it
to make it consistent with M53EVK.

commit a428ac914b2b6db851c1feac98622f2d9844db45
Author: Lothar Rubusch <lothar@denx.de>
Date:   Thu Jun 26 11:01:29 2014 +0200

    ARM: m28evk: Update default environment

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Tom Rini <trini@ti.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
9 years agoarm: arch-mx6: typo fixes in crm_regs.h
Soeren Moch [Fri, 24 Oct 2014 14:33:28 +0000 (16:33 +0200)]
arm: arch-mx6: typo fixes in crm_regs.h

fix typos in video pll related register names and bit defines

Signed-off-by: Soeren Moch <smoch@web.de>
9 years agoodroid: adjust gpio calls to dm gpio api
Przemyslaw Marczak [Tue, 28 Oct 2014 16:31:07 +0000 (17:31 +0100)]
odroid: adjust gpio calls to dm gpio api

Setting gpio value before dm gpio init has no effect,
so now, odroid gpio settings are moved after the gpio uclass init.

Using non-requested gpio pin cases printing error messages.
To avoid this, gpio_request() is added for those gpios.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
9 years agoexynos4/4x12: gpio: use gpio extra base addresses
Przemyslaw Marczak [Tue, 28 Oct 2014 16:31:06 +0000 (17:31 +0100)]
exynos4/4x12: gpio: use gpio extra base addresses

This patch adds extra gpio part addresses to exynos4
and exynos4x12_gpio_data arrays, which are required
since the gpio enum lists are linear

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
9 years agoexynos4/4x12: cpu: add extra gpio base addresses
Przemyslaw Marczak [Tue, 28 Oct 2014 16:31:05 +0000 (17:31 +0100)]
exynos4/4x12: cpu: add extra gpio base addresses

After remove the offsets in Exynos4/4x12 gpio enums,
an additional gpio base addresses are required.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
9 years agomtd: nand: mxs: Add ECC geometry for 2048b/112b NAND
Marek Vasut [Thu, 25 Sep 2014 19:13:36 +0000 (21:13 +0200)]
mtd: nand: mxs: Add ECC geometry for 2048b/112b NAND

Add ECC geometry for NAND which has 2048b pagesize and 112b OOB
size. This is for example Macronix MX30LF2G28AB chip.

Signed-off-by: Marek Vasut <marex@denx.de>
9 years agoarm: imx6: fix typos in CCM_ANALOG_PLL_VIDEO_DENOM register name
Anatolij Gustschin [Thu, 16 Oct 2014 18:37:25 +0000 (20:37 +0200)]
arm: imx6: fix typos in CCM_ANALOG_PLL_VIDEO_DENOM register name

Fix name for Video PLL denominator register.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
9 years agonovena: Fix ethernet PHY reset sequence
Nikolay Dimitrov [Sun, 12 Oct 2014 10:47:51 +0000 (13:47 +0300)]
novena: Fix ethernet PHY reset sequence

This patch fixes conflict between PHY pins becoming outputs after reset and
imx6 still driving the pins. It also fixes the reset timing as recommended by
the PHY datasheet.

Signed-off-by: Nikolay Dimitrov <picmaster@mail.bg>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Sean Cross <xobs@kosagi.com>
Cc: Marek Vasut <marex@denx.de>
Reviewed-by: Fabio Estevam <fabio.estevam@freescale.com>
9 years agoot1200: rework card detect for eMMC
Christian Gmeiner [Thu, 23 Oct 2014 11:46:43 +0000 (13:46 +0200)]
ot1200: rework card detect for eMMC

Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
9 years agoot1200: add support for usdhc4
Christian Gmeiner [Thu, 23 Oct 2014 11:46:42 +0000 (13:46 +0200)]
ot1200: add support for usdhc4

On the 'mr' variant switching to 'mmc dev 1' will result
in "MMC: no card present".

Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
9 years agoot1200: add feature pads
Christian Gmeiner [Thu, 23 Oct 2014 11:46:41 +0000 (13:46 +0200)]
ot1200: add feature pads

The older 'mr' variant and the generic variant of the
OT1200 differ in some places. As the name suggests the
generic variant supports more boot devices.

In order to be compatible with the 'mr' variant we define
some 'feature' GPIOs. On the 'mr' variant this pads are
not connected so we define their state with the help
of the internal pullups.

On the generic variant this GPIOs are connected and
represent the state of the hardware.

Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
9 years agotqma6: fix typo in header guard define
Markus Niebel [Thu, 23 Oct 2014 13:47:06 +0000 (15:47 +0200)]
tqma6: fix typo in header guard define

Signed-off-by: Markus Niebel <Markus.Niebel@tq-group.com>
9 years agotqma6: fix sf detection
Markus Niebel [Thu, 23 Oct 2014 13:47:05 +0000 (15:47 +0200)]
tqma6: fix sf detection

Commit 155fa9af95ac5be857a7327e7a968a296e60d4c8 changed the way
to define a GPIO line, which can be used to force CS high
across multiple transactions. In order to fix sf detection
change board code to make use of board_spi_cs_gpio(..).

Signed-off-by: Markus Niebel <Markus.Niebel@tq-group.com>
9 years agomx6sabresd: Add Seiko WVGA panel support
Fabio Estevam [Tue, 21 Oct 2014 23:14:53 +0000 (21:14 -0200)]
mx6sabresd: Add Seiko WVGA panel support

Add support for the 4.3'' Seiko WVGA parallel display.

In order to direct the splash screen to the Seiko display:

=> setenv panel SEIKO-WVGA
=> save
=> reset

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Stefano Babic <sbabic@denx.de>
9 years agoARM: mx6: Add support for Kosagi Novena
Marek Vasut [Fri, 24 Oct 2014 21:39:07 +0000 (23:39 +0200)]
ARM: mx6: Add support for Kosagi Novena

Add support for the Kosagi Novena board. Currently supported are:
- I2C busses
- FEC Ethernet
- MMC0, MMC1, Booting from MMC
- SATA
- USB ports
- USB Ethernet

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Sean Cross <xobs@kosagi.com>
Cc: Nikolay Dimitrov <picmaster@mail.bg>
Reviewed-by: Nikolay Dimitrov <picmaster@mail.bg>
9 years agoboard: wandboard: add usb storage
Jeroen Hofstee [Thu, 23 Oct 2014 21:02:01 +0000 (23:02 +0200)]
board: wandboard: add usb storage

Cc: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
Acked-by: Fabio Estevam <fabio.estevam@freescale.com>
9 years agoMerge git://git.denx.de/u-boot-x86
Tom Rini [Wed, 29 Oct 2014 19:57:59 +0000 (15:57 -0400)]
Merge git://git.denx.de/u-boot-x86

9 years agoMerge branch 'master' of git://git.denx.de/u-boot-mpc5xxx
Tom Rini [Wed, 29 Oct 2014 19:57:33 +0000 (15:57 -0400)]
Merge branch 'master' of git://git.denx.de/u-boot-mpc5xxx

9 years agox86: config: Increase CONFIG_SYS_BOOTM_LEN to 16MB
Simon Glass [Fri, 10 Oct 2014 14:22:01 +0000 (08:22 -0600)]
x86: config: Increase CONFIG_SYS_BOOTM_LEN to 16MB

The code density of x86_64 is not wonderful. Increase the maximum boot
size and adjust the load address to cope.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agopowerpc: TQM5200: convert to generic board
Wolfgang Denk [Fri, 24 Oct 2014 13:33:43 +0000 (15:33 +0200)]
powerpc: TQM5200: convert to generic board

Signed-off-by: Wolfgang Denk <wd@denx.de>
9 years agopowerpc: tqm8xx*: convert to generic board
Wolfgang Denk [Fri, 24 Oct 2014 13:31:26 +0000 (15:31 +0200)]
powerpc: tqm8xx*: convert to generic board

This converts all TQM8xx boards (MPC8xx based) to generic board.

Signed-off-by: Wolfgang Denk <wd@denx.de>
9 years agoserial: UniPhier: add static to locally used functions
Masahiro Yamada [Fri, 24 Oct 2014 08:00:11 +0000 (17:00 +0900)]
serial: UniPhier: add static to locally used functions

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agoserial: UniPhier: add .pending handler
Masahiro Yamada [Fri, 24 Oct 2014 08:00:10 +0000 (17:00 +0900)]
serial: UniPhier: add .pending handler

Without .pending handler, tstc() function always returns 1.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agoARM: UniPhier: make pinmon command optional
Masahiro Yamada [Mon, 20 Oct 2014 11:45:22 +0000 (20:45 +0900)]
ARM: UniPhier: make pinmon command optional

Add CONFIG_CMD_PINMON to UniPhier-specific Kconfig and make the
"pinmon" command user-configurable.  This command can be disabled
via the configuration if users do not need it.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agoarm: interrupt_init: set sp in IRQ/FIQ modes
Georges Savoundararadj [Tue, 28 Oct 2014 22:16:12 +0000 (23:16 +0100)]
arm: interrupt_init: set sp in IRQ/FIQ modes

Before this commit, the stack addresses for IRQ and FIQ modes,
IRQ_STACK_START and FIQ_STACK_START, were computed in interrupt_init but
they were not used.

This commit sets the stack pointers for IRQ and FIQ modes.

Signed-off-by: Georges Savoundararadj <savoundg@gmail.com>
Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
9 years agoarm: relocate the exception vectors
Georges Savoundararadj [Tue, 28 Oct 2014 22:16:11 +0000 (23:16 +0100)]
arm: relocate the exception vectors

This commit relocates the exception vectors.
As ARM1176 and ARMv7 have the security extensions, it uses VBAR.  For
the other ARM processors, it copies the relocated exception vectors to
the correct address: 0x00000000 or 0xFFFF0000.

Signed-off-by: Georges Savoundararadj <savoundg@gmail.com>
Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Cc: Tom Warren <twarren@nvidia.com>
9 years agoarm: make .vectors section allocatable
Georges Savoundararadj [Tue, 28 Oct 2014 22:16:10 +0000 (23:16 +0100)]
arm: make .vectors section allocatable

A regression was introduced in commit 41623c91. The consequence of that
is the non-relocation of the section .vectors symbols :
_undefined_instruction, _software_interrupt, _prefetch_abort,
_data_abort, _not_used, _irq and _fiq.

Before commit 41623c91, the exception vectors were in a .text section.
The .text section has the attributes allocatable and executable [1].

In commit 41623c91, a specific section is created, called .vectors, with
the attribute executable only.

What have changed between commit 41623c91^ and 41623c91 is the attribute
of the section which contains the exception vectors.
An allocatable section is "a section [that] occupies memory during
process execution" [1] which is the case of the section .vectors.
Adding the lacking attribute (SHF_ALLOC or "a") for the definition of
the section .vectors fixed the issue.

To summarize, the fix has to mark .vectors as allocatable because the
exception vectors reside in "memory during execution" and they need to
be relocated.

[1] http://man7.org/linux/man-pages/man5/elf.5.html

Signed-off-by: Georges Savoundararadj <savoundg@gmail.com>
Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
9 years agokconfig: arm: introduce symbol for ARM CPUs
Georges Savoundararadj [Tue, 28 Oct 2014 22:16:09 +0000 (23:16 +0100)]
kconfig: arm: introduce symbol for ARM CPUs

This commit introduces a Kconfig symbol for each ARM CPU:
CPU_ARM720T, CPU_ARM920T, CPU_ARM926EJS, CPU_ARM946ES, CPU_ARM1136,
CPU_ARM1176, CPU_V7, CPU_PXA, CPU_SA1100.
Also, it adds the CPU feature Kconfig symbol HAS_VBAR which is selected
for CPU_ARM1176 and CPU_V7.

For each target, the corresponding CPU is selected and the definition of
SYS_CPU in the corresponding Kconfig file is removed.

Also, it removes redundant "string" type in some Kconfig files.

Signed-off-by: Georges Savoundararadj <savoundg@gmail.com>
Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Cc: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agoi2c: designware: Convert driver to multibus/multiadapter framework
Stefan Roese [Tue, 28 Oct 2014 11:12:00 +0000 (12:12 +0100)]
i2c: designware: Convert driver to multibus/multiadapter framework

In preparation for the SoCFPGA support of the designware I2C driver,
convert this driver to the common CONFIG_SYS_I2C framework.

This patch converts all users of this driver, this is:

- ST spearxxx boards
- AXS101 (ARC700 platform)

I couldn't test this patch on those boards. Only compile tested for all
spear boards. And tested on SoCFPGA.

Signed-off-by: Stefan Roese <sr@denx.de>
Reviewed-by: Marek Vasut <marex@denx.de>
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
Tested-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Vipin Kumar <vk.vipin@gmail.com>
Cc: Jeroen Hofstee <jeroen@myspectrum.nl>
9 years agoi2c: mxs: Add support for I2C 1 on i.MX28
Marek Vasut [Sun, 19 Oct 2014 22:23:43 +0000 (00:23 +0200)]
i2c: mxs: Add support for I2C 1 on i.MX28

Add support for I2C bus 1 on the i.MX28.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Heiko Schocher <hs@denx.de>
9 years agoi2c: mxs: Pass the i2c_adapter around
Marek Vasut [Sun, 19 Oct 2014 22:23:42 +0000 (00:23 +0200)]
i2c: mxs: Pass the i2c_adapter around

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

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Heiko Schocher <hs@denx.de>
9 years agoi2c: mxs: Add basic support for i2c framework
Marek Vasut [Sun, 19 Oct 2014 22:23:41 +0000 (00:23 +0200)]
i2c: mxs: Add basic support for i2c framework

This patch just converts the function prototypes used throughout
this driver to match those of the i2c framework. There is so far
no functional change. This patch does not do the deeper integration
of the framework bits.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Heiko Schocher <hs@denx.de>
9 years agoi2c: mxs: Consolidate hard-coded bus address
Marek Vasut [Sun, 19 Oct 2014 22:23:40 +0000 (00:23 +0200)]
i2c: mxs: Consolidate hard-coded bus address

This patch prepares the MXS I2C driver for the conversion to the
new I2C driver framework by pulling out the hard-coded I2C0 address
from all the places.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Heiko Schocher <hs@denx.de>
9 years agox86: Correct a few progress message nits
Simon Glass [Fri, 10 Oct 2014 14:21:59 +0000 (08:21 -0600)]
x86: Correct a few progress message nits

We should use puts() instead of printf() where possible. Also clarify
the setup.bin message.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: bootm: Support booting a 64-bit raw kernel
Simon Glass [Fri, 10 Oct 2014 14:21:58 +0000 (08:21 -0600)]
x86: bootm: Support booting a 64-bit raw kernel

Detect an x86_64 kernel and boot it in 64-bit mode.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: image: Add new image type for x64_64
Simon Glass [Fri, 10 Oct 2014 14:21:57 +0000 (08:21 -0600)]
x86: image: Add new image type for x64_64

This is a bit odd in that we are permitted to boot images for either, even
though they are separate architectures.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Move kernel boot function to arch/x86/lib/bootm.c
Simon Glass [Fri, 10 Oct 2014 14:21:56 +0000 (08:21 -0600)]
x86: Move kernel boot function to arch/x86/lib/bootm.c

The boot_zimage() function is badly named it can also boot a raw kernel.
Rename it, and try to avoid pointers for memory addresses as it involves
lots of casting.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Add support for starting 64-bit kernel
Simon Glass [Fri, 10 Oct 2014 14:21:55 +0000 (08:21 -0600)]
x86: Add support for starting 64-bit kernel

Add code to jump to a 64-bit Linux kernel. We need to set up a flat page
table structure, a new GDT and then go through a few hoops in the right
order.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Display basic CPU information on boot
Simon Glass [Fri, 10 Oct 2014 14:21:54 +0000 (08:21 -0600)]
x86: Display basic CPU information on boot

Display the type of CPU (x86 or x86_64) when starting up.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Bring in msr-index.h from linux 3.8
Simon Glass [Fri, 10 Oct 2014 14:21:53 +0000 (08:21 -0600)]
x86: Bring in msr-index.h from linux 3.8

Update this file to include x86_64 fields.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Move paging functions into cpu.c
Simon Glass [Fri, 10 Oct 2014 14:21:52 +0000 (08:21 -0600)]
x86: Move paging functions into cpu.c

These functions really don't belong in physmem as they relate to the
cpu. Move them.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoppc/arm: zap EMK boards
Wolfgang Denk [Tue, 28 Oct 2014 14:44:10 +0000 (15:44 +0100)]
ppc/arm: zap EMK boards

The following bard configurations have been without active maintenance
for a long time, and the board maintainer agrees to have them removed:

MPC5200: TOP5200, MINI5200, EVAL5200
MPC860: TOP860
at91sam9xeXXX: top9000eval_xe, top9000su_xe

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Reinhard Meyer <reinhard.meyer@emk-elektronik.de>
[trini: Add missing Kconfig removals]
Signed-off-by: Tom Rini <trini@ti.com>
9 years agodoc/README.scrapyard: update commit IDs
Wolfgang Denk [Tue, 28 Oct 2014 14:44:09 +0000 (15:44 +0100)]
doc/README.scrapyard: update commit IDs

Signed-off-by: Wolfgang Denk <wd@denx.de>
9 years agodwc_ahsata: use bitwise operator in sata_port_status
Nikita Kiryanov [Tue, 28 Oct 2014 12:59:29 +0000 (14:59 +0200)]
dwc_ahsata: use bitwise operator in sata_port_status

The logic of the return statement in sata_port_status() calls for a
bitwise 'AND' operator, not logical 'AND'. Fix the typo.

Reported-by: Jeroen Hofstee <jeroen@myspectrum.nl>
Cc: Jeroen Hofstee <jeroen@myspectrum.nl>
Cc: Stefano Babic <sbabic@denx.de>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
9 years agoMerge git://git.denx.de/u-boot-dm
Tom Rini [Tue, 28 Oct 2014 16:39:26 +0000 (12:39 -0400)]
Merge git://git.denx.de/u-boot-dm

9 years agoe1000: add i211 and unprogrammed i210/i211 support
Marcel Ziswiler [Sun, 7 Sep 2014 22:03:50 +0000 (00:03 +0200)]
e1000: add i211 and unprogrammed i210/i211 support

This patch adds support for i211 as well as unprogrammed aka tools only
i210/i211 chip support.

Signed-off-by: Marcel Ziswiler <marcel@ziswiler.com>
9 years agoodroid: dts: fix name of included dtsi
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:09 +0000 (17:45 +0200)]
odroid: dts: fix name of included dtsi

Odroid is based on Exynos4412.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoodroid: dts: adjust sd cd-gpios for SD Card
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:08 +0000 (17:45 +0200)]
odroid: dts: adjust sd cd-gpios for SD Card

There is no gaps in exynos gpio enum after rework, so the gpio
numbers should be adjusted to the new numbering.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agotrats2: dts: adjust gpio numbers after gpio rework
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:07 +0000 (17:45 +0200)]
trats2: dts: adjust gpio numbers after gpio rework

There is no gaps in exynos gpio enum after rework, so the gpio
numbers should be adjusted to the new numbering.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agotrats: dts: adjust gpio numbers to new api
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:06 +0000 (17:45 +0200)]
trats: dts: adjust gpio numbers to new api

There is no gaps in exynos gpio enum after rework, so the gpio
numbers should be adjusted to the new numbering.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agouniversal: dts: adjust gpio numbers to new api
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:05 +0000 (17:45 +0200)]
universal: dts: adjust gpio numbers to new api

There is no gaps in exynos gpio enum after rework, so the gpio
numbers should be adjusted to the new numbering.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agouniversal: request soft i2c gpio
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:03 +0000 (17:45 +0200)]
universal: request soft i2c gpio

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoexynos4210: dts: fix gpio offset in pinctrl-uboot
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:02 +0000 (17:45 +0200)]
exynos4210: dts: fix gpio offset in pinctrl-uboot

The gpy0 don't need any additional register offset,
but the gpx0 does, so now it is fixed.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoexynos4412: dts: adjust pinctrl-uboot to changed gpio order
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:01 +0000 (17:45 +0200)]
exynos4412: dts: adjust pinctrl-uboot to changed gpio order

The gpf0 offset was bad and it's now fixed.
After fix gpio order in *pinctrl.dts , the gpy0 offset is not required now.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoexynos4412: dts: fix bad gpio order in pinctrl
Przemyslaw Marczak [Fri, 24 Oct 2014 15:45:00 +0000 (17:45 +0200)]
exynos4412: dts: fix bad gpio order in pinctrl

The pinctrl dts was imported from the kernel, but the order
of GPM and GPY is wrong. The gpio enum in: asm/arch/gpio.h
is proper.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoexynos: common: enable generic fs operations
Przemyslaw Marczak [Fri, 24 Oct 2014 15:44:57 +0000 (17:44 +0200)]
exynos: common: enable generic fs operations

This config is required by Odroid, and could be also useful for the other
boards.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agommc: s5p: set SD detection pin as input
Przemyslaw Marczak [Fri, 24 Oct 2014 15:44:56 +0000 (17:44 +0200)]
mmc: s5p: set SD detection pin as input

The SD Card slot detection pin should be configured as input.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agogit-mailrc: add pmic custodian
Przemyslaw Marczak [Mon, 27 Oct 2014 13:10:34 +0000 (14:10 +0100)]
git-mailrc: add pmic custodian

This adds custodian to the pmic subsystem.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Cc: Tom Rini <trini@ti.com>
9 years agogitignore: ignore atmel pmecc parameter tool
Andreas Bießmann [Sat, 25 Oct 2014 00:58:50 +0000 (02:58 +0200)]
gitignore: ignore atmel pmecc parameter tool

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
9 years agospl: move comment to the right place
Andreas Bießmann [Sat, 25 Oct 2014 00:54:55 +0000 (02:54 +0200)]
spl: move comment to the right place

Commit ae83d882f5fdf7aa7c5aec09cfafb593153c25d6 moved the fixed size mentioned
in the comment but missed the comment.

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
9 years agoUse __stringify() instead of xstr()
Anatolij Gustschin [Fri, 24 Oct 2014 18:13:51 +0000 (20:13 +0200)]
Use __stringify() instead of xstr()

Some boards still use xstr(). Replace remaining occurrences
of xstr() by commonly used __stringify().

Signed-off-by: Anatolij Gustschin <agust@denx.de>
9 years agoppc4xx: update PMC440 board support
Matthias Fuchs [Fri, 24 Oct 2014 10:44:40 +0000 (12:44 +0200)]
ppc4xx: update PMC440 board support

- switch to GENERIC_BOARD
- fix env support from eeprom

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd.eu>
9 years agoimage: Fix Android boot image support
Ahmad Draidi [Thu, 23 Oct 2014 17:50:07 +0000 (20:50 +0300)]
image: Fix Android boot image support

This patch makes the following changes:
- Set kernel entry point correctly
- Append bootargs from image to global bootargs instead
        of replacing them
- Return end address instead of size from android_image_get_end()
- Give correct parameter to genimg_get_format() in boot_get_ramdisk()
- Move ramdisk message printing from android_image_get_kernel() to
android_image_get_ramdisk()

Signed-off-by: Ahmad Draidi <ar2000jp@gmail.com>
Cc: Tom Rini <trini@ti.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
9 years agoarm: db-mv784mp-gp/maxbcm Add placeholder bin_hdr file so that linking works
Stefan Roese [Thu, 23 Oct 2014 15:04:09 +0000 (17:04 +0200)]
arm: db-mv784mp-gp/maxbcm Add placeholder bin_hdr file so that linking works

This file should contain the bin_hdr generated by the original Marvell
U-Boot implementation. As this is currently not included in this
U-Boot version, we have added this placeholder, so that the U-Boot
image can be generated without errors.

If you have a known to be working bin_hdr for your board, then you
just need to replace this text file here with the binary header
and recompile U-Boot.

In a few weeks, mainline U-Boot will get support to generate the
bin_hdr with the DDR training code itself. By implementing this code
as SPL U-Boot. Then this file will not be needed any more and will
get removed.

Signed-off-by: Stefan Roese <sr@denx.de>
9 years agocmd_mem: call unmap_sysmem() after map_sysmem()
Masahiro Yamada [Thu, 23 Oct 2014 08:46:24 +0000 (17:46 +0900)]
cmd_mem: call unmap_sysmem() after map_sysmem()

Actually, unmap_sysmem() does nothing.  Just in case.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Simon Glass <sjg@chromium.org>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agocommon: command: trivial coding style fixes
Masahiro Yamada [Thu, 23 Oct 2014 08:27:30 +0000 (17:27 +0900)]
common: command: trivial coding style fixes

- Do not insert a whitespace between a function name and
   an open paranthesis
 - Fix comment style
 - Do not split an error message into multiple lines
   even if it exceeds 80 columns
 - Do not split "for" statement where it fits in 80 columns
 - Do not use assignment in if condition

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agoCorrect two non-functional misspellings "overrided".
Robert P. J. Day [Tue, 21 Oct 2014 20:44:32 +0000 (16:44 -0400)]
Correct two non-functional misspellings "overrided".

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
9 years agoCorrect single misspelling of "consitant" in source tree.
Robert P. J. Day [Tue, 21 Oct 2014 20:35:28 +0000 (16:35 -0400)]
Correct single misspelling of "consitant" in source tree.

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
9 years agodoc: fix README.standalone
Masahiro Yamada [Tue, 21 Oct 2014 15:41:49 +0000 (00:41 +0900)]
doc: fix README.standalone

Since commit fe1378a961e5 (ARM: use r9 for gd), r9 register
is used on ARM to hold global_data.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Jeroen Hofstee <jeroen@myspectrum.nl>
9 years agoe1000: fix sw fw sync on igb i210/i211
Marcel Ziswiler [Tue, 21 Oct 2014 12:26:36 +0000 (14:26 +0200)]
e1000: fix sw fw sync on igb i210/i211

I finally had a look at the datasheet and spotted an additional
register address difference between regular E1000 and i210/i211 chips.
This patch fixes this and now successfully works on programmed
i210/i211 as well as unprogrammed i211.

Signed-off-by: Marcel Ziswiler <marcel@ziswiler.com>
9 years agoREADME.kconfig: fix typo
Igor Grinberg [Tue, 21 Oct 2014 10:27:45 +0000 (13:27 +0300)]
README.kconfig: fix typo

Fix typo in defconfig file format description.

Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
Cc: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agokconfig: add CONFIG_SUPPORT_TPL
Masahiro Yamada [Mon, 20 Oct 2014 08:45:57 +0000 (17:45 +0900)]
kconfig: add CONFIG_SUPPORT_TPL

CONFIG_TPL should not be enabled for boards that do not have TPL.
CONFIG_SUPPORT_TPL introduced by this commit should be "select"ed
by boards with TPL support and CONFIG_TPL should depend on it.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
9 years agokconfig: add CONFIG_SUPPORT_SPL
Masahiro Yamada [Mon, 20 Oct 2014 08:45:56 +0000 (17:45 +0900)]
kconfig: add CONFIG_SUPPORT_SPL

CONFIG_SPL should not be enabled for boards that do not have SPL.
CONFIG_SUPPORT_SPL introduced by this commit should be "select"ed
by boards with SPL support and CONFIG_SPL should depend on it.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agocommon/cmd_io.c: Fix incorrect help for iod/iow
Bin Meng [Mon, 20 Oct 2014 08:14:53 +0000 (16:14 +0800)]
common/cmd_io.c: Fix incorrect help for iod/iow

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Acked-by: Simon Glass <sjg@chromium.org>
9 years agonet/e1000: Fix EEPROM access error
York Sun [Fri, 17 Oct 2014 20:44:06 +0000 (13:44 -0700)]
net/e1000: Fix EEPROM access error

Commit 951860634fdb557bbb58e0f99215391bc0c29779 may have changed
the logic unintentially from "if (!(swfw_sync & (fwmask | swmask)))"
to "if ((swfw_sync & swmask) && !(swfw_sync & fwmask))". This change
breaks some e1000 NIC with a message "ERROR: Unable to read EEPROM!".

Signed-off-by: York Sun <yorksun@freescale.com>
CC: Marek Vasut <marex@denx.de>
CC: Tim Harvey <tharvey@gateworks.com>
Acked-by: Marcel Ziswiler <marcel@ziswiler.com>
9 years agoaboot: fix block addressing for don't care chunk type
Rob Herring [Thu, 16 Oct 2014 03:19:36 +0000 (11:19 +0800)]
aboot: fix block addressing for don't care chunk type

CHUNK_TYPE_DONT_CARE should skip over the specified number of blocks, but
currently fails to increment the device block address. This results in
filesystem images getting written incorrectly. Add the missing block
address incrementing.

Cc: Steve Rae <srae@broadcom.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Steve Rae <srae@broadcom.com>
9 years agoTI:OMAP4: enable EXT support in SPL for OMAP4 boards
Guillaume GARDET [Wed, 15 Oct 2014 15:53:15 +0000 (17:53 +0200)]
TI:OMAP4: enable EXT support in SPL for OMAP4 boards

Enable EXT support in SPL for OMAP4 boards.
Build tested for duovero, omap4_sdp4430 and omap4_panda.
Run time tested on omap4_panda.

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>
Cc: Tom Rini <trini@ti.com>
9 years agospl: do not hang in spl_register_fat_device but return error value. It allows to...
Guillaume GARDET [Wed, 15 Oct 2014 15:53:14 +0000 (17:53 +0200)]
spl: do not hang in spl_register_fat_device but return error value. It allows to use both CONFIG_SPL_FAT_SUPPORT and CONFIG_SPL_EXT_SUPPORT.

Do not hang in spl_register_fat_device but return an error value.
It allows to use both CONFIG_SPL_FAT_SUPPORT and CONFIG_SPL_EXT_SUPPORT.
If FAT load fails, then EXT load is tried.

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>
Cc: Tom Rini <trini@ti.com>
9 years agodoc: Update documentation according to the EXT SPL support patch set
Guillaume GARDET [Wed, 15 Oct 2014 15:53:13 +0000 (17:53 +0200)]
doc: Update documentation according to the EXT SPL support patch set

Update documentation according to the EXT SPL support patch set.

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>
Cc: Tom Rini <trini@ti.com>
9 years agospl: Add EXT support to SPL
Guillaume GARDET [Wed, 15 Oct 2014 15:53:12 +0000 (17:53 +0200)]
spl: Add EXT support to SPL

Add EXT filesystem support to SPL.

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>
[trini: Fix a warning and checkpatch problems]
Signed-off-by: Tom Rini <trini@ti.com>
9 years agoSPI: mxc_spi: delay initialisation until claim bus
Markus Niebel [Thu, 23 Oct 2014 14:09:39 +0000 (16:09 +0200)]
SPI: mxc_spi: delay initialisation until claim bus

it is not correct to init for a specific slave in spi_setup_slave.
instead buffer the values and delay init until spi_claim_bus.

Signed-off-by: Markus Niebel <Markus.Niebel@tq-group.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agoSPI: mxc_spi: remove second reset from ECSPI config handler
Markus Niebel [Thu, 23 Oct 2014 14:09:38 +0000 (16:09 +0200)]
SPI: mxc_spi: remove second reset from ECSPI config handler

the second reset prevents other registers to be written.
This will prevent to have the correct signal levels for
SCLK before writing to the config reg in spi_xchg_single.

Tested with GPIO based chipselect and SPI_MODE_3 on i.MX6S

Signed-off-by: Markus Niebel <Markus.Niebel@tq-group.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Move the config options to the top
Marek Vasut [Wed, 22 Oct 2014 19:56:04 +0000 (21:56 +0200)]
spi: altera: Move the config options to the top

Just move the configuration options scattered all over the driver
to the top of the source file. No functional change.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Add short note about EPCS/EPCQx1
Marek Vasut [Wed, 22 Oct 2014 19:56:03 +0000 (21:56 +0200)]
spi: altera: Add short note about EPCS/EPCQx1

Add short documentation-alike note on how to use the Altera SPI
driver with the EPCS/EPCQx1 FPGA IP block on SoCFPGA Cyclone V
into doc/SPI/README.altera_spi

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Cc: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Clean up the use of variable d
Marek Vasut [Wed, 22 Oct 2014 19:56:02 +0000 (21:56 +0200)]
spi: altera: Clean up the use of variable d

The variable d is used in rather questionable way. Rework the code
a bit so it's clearer what it does. Also, rename the variable from
d to data to make it's name less mysterious. Finally, change it's
data type to uint32_t , since it's accessed as a 32bit number.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Cc: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Zap endless loop
Marek Vasut [Wed, 22 Oct 2014 19:56:01 +0000 (21:56 +0200)]
spi: altera: Zap endless loop

The driver contained an endless loop when waiting for TX completion,
this is a bad idea since if the hardware fails, the loop might spin
forever. Add timeout and handle it.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Cc: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Clean up most checkpatch issues
Marek Vasut [Wed, 22 Oct 2014 19:56:00 +0000 (21:56 +0200)]
spi: altera: Clean up most checkpatch issues

This patch just zaps most of the checkpatch cries present in the
driver. There is one more left, which will be addressed separately.
There is no functional change.

This patch also adds a bunch of newlines all around the place, this
is to make the code much more readable.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Clean up bit definitions
Marek Vasut [Wed, 22 Oct 2014 19:55:59 +0000 (21:55 +0200)]
spi: altera: Clean up bit definitions

Clean up the definitions of bits in the Altera SPI driver, there
is no need to put braces around numbers afterall. No functional
change.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agospi: altera: Use struct-based register access
Marek Vasut [Wed, 22 Oct 2014 19:55:58 +0000 (21:55 +0200)]
spi: altera: Use struct-based register access

Zap the offset-based register access and use the struct-based one
as this is the preferred method.

No functional change, but there are some line-over-80 problems in
the driver, which will be addressed later.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@altera.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Pavel Machek <pavel@denx.de>
Acked-by: Pavel Machek <pavel@denx.de>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
9 years agoRename some defines containing FAT in their name to be filesystem generic
Guillaume GARDET [Wed, 15 Oct 2014 15:53:11 +0000 (17:53 +0200)]
Rename some defines containing FAT in their name to be filesystem generic

Rename some defines containing FAT in their name to be filesystem generic:
MMCSD_MODE_FAT => MMCSD_MODE_FS
CONFIG_SPL_FAT_LOAD_ARGS_NAME => CONFIG_SPL_FS_LOAD_ARGS_NAME
CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME => CONFIG_SPL_FS_LOAD_PAYLOAD_NAME
CONFIG_SYS_MMC_SD_FAT_BOOT_PARTITION => CONFIG_SYS_MMC_SD_FS_BOOT_PARTITION

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>
Cc: Tom Rini <trini@ti.com>
9 years agotest: Add a simple test to detected warnings with uint64_t, uintptr_t
Simon Glass [Wed, 15 Oct 2014 10:38:39 +0000 (04:38 -0600)]
test: Add a simple test to detected warnings with uint64_t, uintptr_t

These types are problematic because they are typically declared in a
non-standard way in U-Boot. For example, U-Boot uses 'long long' for
int64_t even on a 64-bit machine whereas stdint.h uses 'long'.
Similarly, U-Boot always uses 'long' for intptr_t whereas stdint.h mostly
uses 'int'.

This simple test script runs a few toolchains on a few archs to check for
warnings.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agousb: Use correct printf() format string for uintptr_t
Simon Glass [Wed, 15 Oct 2014 10:38:38 +0000 (04:38 -0600)]
usb: Use correct printf() format string for uintptr_t

Use the inttypes header file to provide this.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoscsi: Use correct printf() format string for uintptr_t
Simon Glass [Wed, 15 Oct 2014 10:38:37 +0000 (04:38 -0600)]
scsi: Use correct printf() format string for uintptr_t

Use the inttypes header file to provide this.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agox86: Use correct printf() format string for uintptr_t
Simon Glass [Wed, 15 Oct 2014 10:38:36 +0000 (04:38 -0600)]
x86: Use correct printf() format string for uintptr_t

Use the inttypes header file to provide this.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoTidy up data sizes and function comment in display_options
Simon Glass [Wed, 15 Oct 2014 10:38:35 +0000 (04:38 -0600)]
Tidy up data sizes and function comment in display_options

Use inttypes.h and uint64_t to correct the code so that it will not issue
warnings on 64-bit machines where 'uint64_t' is 'unsigned long'.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoUse uint64_t instead of u64 in put_dec()
Simon Glass [Wed, 15 Oct 2014 10:38:34 +0000 (04:38 -0600)]
Use uint64_t instead of u64 in put_dec()

Use the correct type required by do_div().

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoUse uint64_t for time types
Simon Glass [Wed, 15 Oct 2014 10:38:33 +0000 (04:38 -0600)]
Use uint64_t for time types

Unfortunately 'unsigned long long' and 'uint64_t' are not necessarily
compatible on 64-bit machines. Use the correct typedef instead of
writing the supposed type out in full.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoext4: Use inttypes for printf() string
Simon Glass [Wed, 15 Oct 2014 10:38:32 +0000 (04:38 -0600)]
ext4: Use inttypes for printf() string

On 64-bit platforms (like sandbox) 64-bit integers may be 'long' rather
than 'long long'. Use the inttypes header to avoid compiler warnings.

Signed-off-by: Simon Glass <sjg@chromium.org>
9 years agoAdd some standard headers external code might need
Gabe Black [Wed, 15 Oct 2014 10:38:31 +0000 (04:38 -0600)]
Add some standard headers external code might need

inttypes.h defines format specifiers for printf which work with data types of
particular sizes. stdlib.h is currently just a passthrough to malloc.h which
has declarations of the various *alloc functions.

Add the required #define to common.h so that these printf format specifiers
will be made available.

Signed-off-by: Gabe Black <gabeblack@google.com>
Reviewed-by: Gabe Black <gabeblack@chromium.org>
Tested-by: Gabe Black <gabeblack@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@google.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
(Replaced with a GPL version from glibc)