oweals/u-boot.git
11 years agotreewide: include libfdt_env.h before fdt.h
Kim Phillips [Wed, 16 Jan 2013 13:59:04 +0000 (13:59 +0000)]
treewide: include libfdt_env.h before fdt.h

and, if including libfdt.h which includes libfdt_env.h in
the correct order, don't include fdt.h before libfdt.h.

this is needed to get the fdt type definitions set from
the project environment before fdt.h uses them.

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Cc: Jerry Van Baren <gvb.uboot@gmail.com>
11 years agofdt: fix dts preprocessor options
Allen Martin [Tue, 8 Jan 2013 16:07:54 +0000 (16:07 +0000)]
fdt: fix dts preprocessor options

Using "-ansi" preprocessor option will cause dts lines that begin with
'#' to choke the preprocessor.  Change to "-x assembler-with-cpp"
instead which is what the kernel uses to preprocess dts files.

Signed-off-by: Allen Martin <amartin@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Simon Glass <sjg@chromium.org>
11 years agoam33xx: Drop gpio0_7_pin_mux from phytec pcm051
Tom Rini [Mon, 4 Feb 2013 17:21:39 +0000 (12:21 -0500)]
am33xx: Drop gpio0_7_pin_mux from phytec pcm051

This mux is not currently used and appears to be a carry-over from the
am335x evm code.

Acked-by: Lars Poeschel <poeschel@lemonage.de>
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoOMAP3: igep00x0: fix a build warning on IGEP boards
Javier Martinez Canillas [Sat, 26 Jan 2013 12:18:32 +0000 (13:18 +0100)]
OMAP3: igep00x0: fix a build warning on IGEP boards

commit b689cd5 OMAP3: use a single board file for IGEP devices

introduced the following build warning:

igep00x0.h:168:24: warning: backslash-newline at end of file [enabled
by default]

This patch fixes the issue.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
11 years agoAM335X: Set fdt_high for AM335X devices to enable booting with Device Tree
hvaibhav@ti.com [Tue, 18 Sep 2012 09:26:05 +0000 (09:26 +0000)]
AM335X: Set fdt_high for AM335X devices to enable booting with Device Tree

For AM335X boards, such as the EVM and Bone Linux kernel fails to
locate the device tree blob on boot. The reason being is that
u-boot is copying the DT blob to the upper part of RAM when booting
the kernel and the kernel is unable to access the blob.
By setting the fdt_high variable to 0xffffffff (to prevent the copy)
the kernel is able to locate the DT blob and boot.

This patch is tested on BeagleBone platform.

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Cc: Tom Rini <trini@ti.com>
11 years agoAdd DDR3 support for AM335x-EVM (Version 1.5A)
Jeff Lance [Mon, 14 Jan 2013 05:32:20 +0000 (05:32 +0000)]
Add DDR3 support for AM335x-EVM (Version 1.5A)

AM335x EVM 1.5A uses Micron MT41J512M8RH-125 SDRAM 4Gb (512Mx8) as the
DDR3 chip.

[Hebbar Gururaja <gururaja.hebbar@ti.com>]
- Resolve merge conflict while rebasing. File structure is
  changed in the mainline. So re-arrange the code accordingly.
- Update commit message to reflect the DDR3 part number

Signed-off-by: Jeff Lance <j-lance1@ti.com>
Signed-off-by: Tom Rini <trini@ti.com>
Signed-off-by: Hebbar Gururaja <gururaja.hebbar@ti.com>
11 years agoam335x: display msg when reading MAC from efuse
Lars Poeschel [Fri, 11 Jan 2013 00:53:32 +0000 (00:53 +0000)]
am335x: display msg when reading MAC from efuse

When ethaddr is not set in environment the MAC address is read
from efuse. The message was only printed in debug case, but this
message could be of interest for the ordinary user, so printf it.

Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
11 years agopcm051: Add support for Phytec phyCORE-AM335x
Lars Poeschel [Fri, 11 Jan 2013 00:53:31 +0000 (00:53 +0000)]
pcm051: Add support for Phytec phyCORE-AM335x

The board is named pcm051 and has this hardware:
SOC: TI AM3359
DDR3-RAM: 2x MT41J256M8HX-15EIT:D 512MiB
ETH 1: LAN8710AI
SPI-Flash: W25Q64BVSSIG
RTC: RV-4162-C7
I2C-EEPROM: CAT32WC32
NAND: MT29F4G08_VFPGA63
PMIC: TPS65910A3
LCD

Supported:
UART 1
MMC/SD
ETH 1
USB
I2C
SPI

Not yet supported:
NAND
RTC
LCD

Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
[trini: Add #define CONFIG_PHY_ADDR 0 to config]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoam33xx: add a pulldown macro to pinmux config
Lars Poeschel [Fri, 11 Jan 2013 00:53:30 +0000 (00:53 +0000)]
am33xx: add a pulldown macro to pinmux config

Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
11 years agoomap4: allow the use of a plain text env file instead boot scripts
Javier Martinez Canillas [Mon, 7 Jan 2013 03:51:20 +0000 (03:51 +0000)]
omap4: allow the use of a plain text env file instead boot scripts

For production systems it is better to use script images since
they are protected by checksums and carry valuable information like
name and timestamp. Also, you can't validate the content passed to
env import.

But for development, it is easier to use the env import command and
plain text files instead of script-images.

Since both OMAP4 supported boards (Panda and TI SDP4430) are used
primarily for development, this patch allows U-Boot to load env var
from a text file in case that an boot.scr script-image is not present.

The variable uenvcmd (if existent) will be executed (using run) after
uEnv.txt was loaded. If uenvcmd doesn't exist the default boot sequence
will be started.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Acked-by: Nishanth Menon <nm@ti.com>
11 years agoOMAP3: igep00x0: add boot status GPIO LED
Javier Martinez Canillas [Thu, 27 Dec 2012 03:36:01 +0000 (03:36 +0000)]
OMAP3: igep00x0: add boot status GPIO LED

This patch adds an GPIO LED boot status for IGEP boards.

The GPIO LED used is the red LED0 while the Linux kernel
uses the green LED0 as the boot status.

By using different GPIO LEDs, the user can know in which
step of the boot process the board currently is.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
11 years agoOMAP3: use a single board file for IGEP devices
Javier Martinez Canillas [Thu, 27 Dec 2012 01:35:56 +0000 (01:35 +0000)]
OMAP3: use a single board file for IGEP devices

Even when the IGEPv2 board and the IGEP Computer-on-Module
are different from a form factor point of view, they are
very similar in the fact that share many components and how
they are wired.

So, it is possible (and better) to have a single board file
for both devices and just use the CONFIG_MACH_TYPE to make
a differentiation between each board when needed.

This change avoids code duplication by removing 298 lines of
code and makes future maintenance easier.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
11 years agosf: stmicro: Add support for N25Q256A
Jagannadha Sutradharudu Teki [Tue, 29 Jan 2013 11:43:38 +0000 (17:13 +0530)]
sf: stmicro: Add support for N25Q256A

Add support for Numonyx N25Q256A SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agosf: stmicro: Add support for N25Q32A
Jagannadha Sutradharudu Teki [Tue, 29 Jan 2013 11:43:37 +0000 (17:13 +0530)]
sf: stmicro: Add support for N25Q32A

Add support for Numonyx N25Q32A SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agosf: stmicro: Add support for N25Q32
Jagannadha Sutradharudu Teki [Tue, 29 Jan 2013 11:43:36 +0000 (17:13 +0530)]
sf: stmicro: Add support for N25Q32

Add support for Numonyx N25Q32 SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agosf: stmicro: Add support for N25Q64A
Jagannadha Sutradharudu Teki [Wed, 23 Jan 2013 12:51:45 +0000 (18:21 +0530)]
sf: stmicro: Add support for N25Q64A

Add support for Numonyx N25Q64A SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agosf: winbond: Add W25Q64W
Jagannadha Sutradharudu Teki [Wed, 23 Jan 2013 12:29:29 +0000 (13:29 +0100)]
sf: winbond: Add W25Q64W

Add support for Winbond's W25Q64W SPI flash.
This device is used on xilinx zynq emulation platform.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agosf: spansion: Correct the first byte of idcode1 for S25FL256S part
Jagannadha Sutradharudu Teki [Fri, 14 Sep 2012 15:16:11 +0000 (20:46 +0530)]
sf: spansion: Correct the first byte of idcode1 for S25FL256S part

This patch corrected the first byte of idcode1 for S25FL256S SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-x86
Tom Rini [Mon, 4 Feb 2013 22:50:11 +0000 (17:50 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-x86

11 years agoMerge branch 'master' of git://git.denx.de/u-boot
Kim Phillips [Mon, 4 Feb 2013 17:16:26 +0000 (11:16 -0600)]
Merge branch 'master' of git://git.denx.de/u-boot

11 years agoMerge branch 'master' of git://www.denx.de/git/u-boot-microblaze
Tom Rini [Mon, 4 Feb 2013 14:07:34 +0000 (09:07 -0500)]
Merge branch 'master' of git://denx.de/git/u-boot-microblaze

11 years agoserial: arm_dcc: Fix compilation warning and remove unneeded initialization
Michal Simek [Tue, 22 Jan 2013 23:40:07 +0000 (23:40 +0000)]
serial: arm_dcc: Fix compilation warning and remove unneeded initialization

- arm_dcc_dev is already initialized.
- Remove unused rc variable
Warning log:
arm_dcc.c: In function 'drv_arm_dcc_init':
arm_dcc.c:145:6: warning: unused variable 'rc' [-Wunused-variable]

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Marek Vasut <marex@denx.de>
11 years agoserial: arm_dcc: Remove CONFIG_ARM_DCC_MULTI option
Michal Simek [Tue, 22 Jan 2013 23:40:06 +0000 (23:40 +0000)]
serial: arm_dcc: Remove CONFIG_ARM_DCC_MULTI option

CONFIG_ARM_DCC_MULTI should be also removed in the patch
"serial: Remove CONFIG_SERIAL_MULTI from serial drivers"
(sha1: a3827250606895ec2dd4b8d867342b7cabf3692f)
Because the driver defines serial_* functions
which cause conflict with serial.c (multiple definition of serial_*)

Removing CONFIG_SERIAL_MULTI function also require to define
default_serial_console for cases where another serial driver
is not available in the system.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Marek Vasut <marex@denx.de>
11 years agosf: stmicro: add support for N25Q064
Jagannadha Sutradharudu Teki [Wed, 12 Dec 2012 04:48:56 +0000 (04:48 +0000)]
sf: stmicro: add support for N25Q064

Add support for Numonyx N25Q064 SPI flash.

Signed-off-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
11 years agocmd_time: merge run_command_and_time_it with cmd_process
Richard Genoud [Mon, 3 Dec 2012 06:28:28 +0000 (06:28 +0000)]
cmd_time: merge run_command_and_time_it with cmd_process

As far as every arch has a get_timer function,
run_command_and_time_it code can now disappear.

Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Acked-By: Che-Liang Chiou <clchiou@chromium.org>
[trini: s/ulong/unsigned long/ in command.h portion]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoconsole: USB: KBD: Fix incorrect autoboot timeout
Jim Lin [Thu, 24 Jan 2013 01:05:55 +0000 (01:05 +0000)]
console: USB: KBD: Fix incorrect autoboot timeout

Autoboot timeout defined by CONFIG_BOOTDELAY will not be accurate if
CONFIG_USB_KEYBOARD and CONFIG_SYS_USB_EVENT_POLL are defined in
configuration file and when tstc() function for checking key pressed
takes longer time than 10 ms (e.g., 50 ms) to finish.

Signed-off-by: Jim Lin <jilin@nvidia.com>
11 years agoboard sc3: fix warning about nested comment
Jeroen Hofstee [Tue, 8 Jan 2013 13:35:53 +0000 (13:35 +0000)]
board sc3: fix warning about nested comment

cc: Heiko Schocher <hs@denx.de>
Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
11 years agocommon: env_mmc: Use __weak annotation to simplify code
Fabio Estevam [Tue, 8 Jan 2013 05:36:11 +0000 (05:36 +0000)]
common: env_mmc: Use __weak annotation to simplify code

Using the __weak annotation can make the code cleaner.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Marek Vasut <marex@denx.de>
11 years agocommon/cmd_bootm.c: prevent running of subcommands before 'bootm start'
Gabor Juhos [Sun, 6 Jan 2013 23:04:25 +0000 (23:04 +0000)]
common/cmd_bootm.c: prevent running of subcommands before 'bootm start'

The execution order of the bootm subcommands is fixed.
Although here is a sanity check in the state machine
which should prevent running the subcommands in wrong
order but it does not catch all possible errors.

It is possible to run any subcommand without running
'bootm start' first which leads to unexpected behaviour.
For example, running 'bootm loados' without 'bootm start'
causes a hang:

    U-Boot> bootm loados
       XIP Invalid Image ... OK
    OK

Add a sanity check to 'do_bootm_subcommand' in order
to ensure that no subcommands can be executed before
'bootm start'.

After the patch running of any subcommand without running
'bootm start' will cause an error like this:

    U-Boot> bootm loados
    Trying to execute a command out of order
    bootm - boot application image from memory

    Usage:
    bootm [addr [arg ...]]
        - boot application image stored in memory
    ...

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
11 years agodrivers/block/systemace - fixed data type in "systemace_read" to match prototype...
Alexey Brodkin [Thu, 3 Jan 2013 01:02:46 +0000 (01:02 +0000)]
drivers/block/systemace - fixed data type in "systemace_read" to match prototype in "block_dev_desc_t"

Currently we have "unsigned long blkcnt" which is fine with
CONFIG_SYS_64BIT_LBA undefined because "lbaint_t" is basically the same
"unsigned long".
If CONFIG_SYS_64BIT_LBA gets defined "lbaint_t" is defined as "unsigned
long long".

Even though not many embedded systems have CONFIG_SYS_64BIT_LBA defined
it's good to have types in function implementation that match exactly
with prototypes.

Signed-off-by: Alexey Brodkin <alexey.brodkin@gmail.com>
11 years agoFAT: remove ifdefs to make the code more readable
Richard Genoud [Thu, 13 Dec 2012 03:30:10 +0000 (03:30 +0000)]
FAT: remove ifdefs to make the code more readable

ifdefs in the code are making it harder to read.
The use of simple if(vfat_enabled) makes no more code and is cleaner.
(the code is discarded by the compiler instead of the preprocessor.)
NB: if -O0 is used, the code won't be discarded

and bonus, now the code compiles even if CONFIG_SUPPORT_VFAT is not
defined.

Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
11 years agoFAT: use toupper/tolower instead of recoding them
Richard Genoud [Thu, 13 Dec 2012 00:47:36 +0000 (00:47 +0000)]
FAT: use toupper/tolower instead of recoding them

toupper/tolower function are already declared, so use them.

Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Acked-by: Marek Vasut <marex@denx.de>
Acked-by: Stefano Babic <sbabic@denx.de>
11 years agoconfigs:Remove unused macro CONFIG_DISCOVER_PHY
Ashok [Wed, 7 Nov 2012 07:39:29 +0000 (07:39 +0000)]
configs:Remove unused macro CONFIG_DISCOVER_PHY

Remove unused macro CONFIG_DISCOVER_PHY from configs.

Signed-off-by: Ashok Kumar Reddy <ashokkourla2000@gmail.com>
Acked-by: Stefano Babic <sbabic@denx.de>
11 years agox86: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:27 +0000 (20:49 +0000)]
x86: Use generic global_data

Move x86 over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agosparc: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:26 +0000 (20:49 +0000)]
sparc: Use generic global_data

Move sparc over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agosh: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:25 +0000 (20:49 +0000)]
sh: Use generic global_data

Move sh over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agosandbox: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:24 +0000 (20:49 +0000)]
sandbox: Use generic global_data

Move sandbox over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agopowerpc: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:23 +0000 (20:49 +0000)]
powerpc: Use generic global_data

Move powerpc over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoopenrisc: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:22 +0000 (20:49 +0000)]
openrisc: Use generic global_data

Move openrisc over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agonios2: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:21 +0000 (20:49 +0000)]
nios2: Use generic global_data

Move nios2 over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Thomas Chou <thomas@wytron.com.tw>
11 years agonds32: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:20 +0000 (20:49 +0000)]
nds32: Use generic global_data

Move nds32 over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agomips: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:19 +0000 (20:49 +0000)]
mips: Use generic global_data

Move mips over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agomicroblaze: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:18 +0000 (20:49 +0000)]
microblaze: Use generic global_data

Move microblaze over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
Tested-by: Michal Simek <monstr@monstr.eu>
11 years agom68k: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:17 +0000 (20:49 +0000)]
m68k: Use generic global_data

Move m68k over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoblackfin: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:16 +0000 (20:49 +0000)]
blackfin: Use generic global_data

Move blackfin over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoavr32: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:15 +0000 (20:49 +0000)]
avr32: Use generic global_data

Move avr32 over to use generic global_data.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Use generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:14 +0000 (20:49 +0000)]
arm: Use generic global_data

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoOnly use fb_base if we have a display
Simon Glass [Thu, 13 Dec 2012 20:49:13 +0000 (20:49 +0000)]
Only use fb_base if we have a display

The ideal of having a frame buffer when there isn't a display is not
that useful. Change the bdinfo command to expect this only when we
have an lcd or video display.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoAdd generic global_data
Simon Glass [Thu, 13 Dec 2012 20:49:12 +0000 (20:49 +0000)]
Add generic global_data

Add a generic global_data structure which all archs will eventually
use.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agosandbox: Move ram_buf to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:11 +0000 (20:49 +0000)]
sandbox: Move ram_buf to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoavr32: Move cpu_hz to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:10 +0000 (20:49 +0000)]
avr32: Move cpu_hz to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoavr32: Move stack_end to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:09 +0000 (20:49 +0000)]
avr32: Move stack_end to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agomips: Move per_clk and dev_clk to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:08 +0000 (20:49 +0000)]
mips: Move per_clk and dev_clk to arch_global_data

Move these field into arch_global_data and tidy up. The other
CONFIG_JZSOC fields are used by various architectures, so just remove
the #ifdef bracketing for these.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agom68k: Move CONFIG_EXTRA_CLOCK to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:07 +0000 (20:49 +0000)]
m68k: Move CONFIG_EXTRA_CLOCK to arch_global_data

Move inp_clk, vco_clk and flb_clk into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agosparc: Drop kbd_status and reset_status from global_data
Simon Glass [Thu, 13 Dec 2012 20:49:06 +0000 (20:49 +0000)]
sparc: Drop kbd_status and reset_status from global_data

These fields is not used on sparc, so punt them.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: arm: Move sdhc_clk into arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:05 +0000 (20:49 +0000)]
ppc: arm: Move sdhc_clk into arch_global_data

This is used by both powerpc and arm, but I think it still qualifies as
architecture-specific.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move kbd_status to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:04 +0000 (20:49 +0000)]
ppc: Move kbd_status to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move wdt_last to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:03 +0000 (20:49 +0000)]
ppc: Move wdt_last to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move fpga_state to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:02 +0000 (20:49 +0000)]
ppc: Move fpga_state to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Remove console_addr from global data
Simon Glass [Thu, 13 Dec 2012 20:49:01 +0000 (20:49 +0000)]
ppc: Remove console_addr from global data

This does not appear to be used, so punt it.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move mirror_hack to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:49:00 +0000 (20:49 +0000)]
ppc: Move mirror_hack to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Move uart_clk to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:59 +0000 (20:48 +0000)]
arm: Move uart_clk to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move dp_alloc_base, dp_alloc_top to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:58 +0000 (20:48 +0000)]
ppc: Move dp_alloc_base, dp_alloc_top to arch_global_data

Move these fields into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move arbiter fields to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:57 +0000 (20:48 +0000)]
ppc: Move arbiter fields to arch_global_data

Move arbiter_event_attributes and arbiter_event_address into
arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move reset_status to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:56 +0000 (20:48 +0000)]
ppc: Move reset_status to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move mpc8220 clocks to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:55 +0000 (20:48 +0000)]
ppc: Move mpc8220 clocks to arch_global_data

Move these fields into arch_global_data and tidy up. The bExtUart field
does not appear to be used, so punt it.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move mpc512x clocks to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:54 +0000 (20:48 +0000)]
ppc: Move mpc512x clocks to arch_global_data

Move ips_clk and csb_clk into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move mpc5xxx clocks to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:53 +0000 (20:48 +0000)]
ppc: Move mpc5xxx clocks to arch_global_data

Move ipb_clk and pci_clk into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move used_tlb_cams to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:52 +0000 (20:48 +0000)]
ppc: Move used_tlb_cams to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move used_laws to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:51 +0000 (20:48 +0000)]
ppc: Move used_laws to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move CONFIG_QE to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:50 +0000 (20:48 +0000)]
ppc: Move CONFIG_QE to arch_global_data

Move the quantative easing fields into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: m68k: Move i2c1_clk, i2c2_clk to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:49 +0000 (20:48 +0000)]
ppc: m68k: Move i2c1_clk, i2c2_clk to arch_global_data

Move these fields into arch_global_data and tidy up. This is needed for
both ppc and m68k since they share the i2c driver.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move lbc_clk and cpu to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:48 +0000 (20:48 +0000)]
ppc: Move lbc_clk and cpu to arch_global_data

Move these fields into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Update for bsc9132qds.c, b4860qds.c]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agomicroblaze: Remove FSL support from generic board
Michal Simek [Wed, 23 Jan 2013 13:18:25 +0000 (14:18 +0100)]
microblaze: Remove FSL support from generic board

This code was targetting one specific Microblaze platform
configuration which is obsolete and fsl bus isn't used
in this way.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agocommon: cmd_bdinfo: Fix compilation warning for microblaze
Michal Simek [Wed, 23 Jan 2013 13:15:35 +0000 (14:15 +0100)]
common: cmd_bdinfo: Fix compilation warning for microblaze

Fix one printf compilation warning in microblaze bdinfo part.

Warning log:
cmd_bdinfo.c: In function 'do_bdinfo':
cmd_bdinfo.c:219:2: warning: format '%u' expects argument of type
'unsigned int', but argument 2 has type 'long unsigned int' [-Wformat]

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agoboard: xilinx: Remove common folder
Michal Simek [Wed, 23 Jan 2013 13:11:50 +0000 (14:11 +0100)]
board: xilinx: Remove common folder

All these files was used for ancient xilinx drivers
which are finally gone.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Tested-by: Rommel Custodio <sessyargc@gmail.com>
11 years agoboard: xilinx: Remove unused ancient i2c driver
Michal Simek [Wed, 23 Jan 2013 13:09:35 +0000 (14:09 +0100)]
board: xilinx: Remove unused ancient i2c driver

There is new driver in the driver folder.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Tested-by: Rommel Custodio <sessyargc@gmail.com>
Acked-by: Heiko Schocher <hs@denx.de>
11 years agospi: xilinx_spi: Perform software reset during slave setup
Jason Wu [Fri, 23 Nov 2012 05:05:08 +0000 (15:05 +1000)]
spi: xilinx_spi: Perform software reset during slave setup

to make sure it is in the clear state.

Signed-off-by: Jason Wu <huanyu@xilinx.com>
11 years agocommon: cmd_bdinfo: Fix bdinfo to show all MACs for Microblaze and ARM
Michal Simek [Wed, 23 Jan 2013 11:21:18 +0000 (12:21 +0100)]
common: cmd_bdinfo: Fix bdinfo to show all MACs for Microblaze and ARM

- Show all ethernet MACs in the system.
- Show current ethernet device

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agomicroblaze: Add muldi3.c which contains routines for _muldi3
David Holsgrove [Tue, 6 Nov 2012 13:01:24 +0000 (23:01 +1000)]
microblaze: Add muldi3.c which contains routines for _muldi3

Referenced arch/blackfin/lib/muldi3.c and the linux kernel.
Resolves issue seen when building u-boot for HW_MUL=0;

PLATFORM_CPPFLAGS += -mxl-soft-mul
PLATFORM_CPPFLAGS += -mno-xl-multiply-high

which resulted in error while linking to libgcc.a without mul hw (bs / m);

libgcc.a(_muldi3.o): In function `__muldi3':
.... src/gcc-4.6.2/libgcc/libgcc2.c:550: undefined reference to `_GLOBAL_OFFSET_TABLE_'

This link failure would not occur if we used gcc instead of ld directly, as
gcc will correctly use the crt's to resolve this link.

Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agoblock: systemace: Added missing "else" in "ace_writew"
Alexey Brodkin [Thu, 3 Jan 2013 09:35:23 +0000 (13:35 +0400)]
block: systemace: Added missing "else" in "ace_writew"

System ACE compact flash controller supports either 8-bit (default) or
16-bit data transfers. And in corresponding driver we need to implement
read/write of 16-bit data words properly for both modes of operation.

In existing code if width==8 both branches get executed which may cause
unexpected behavior of SystemAce controller.

Addition of "else" fixes described issue and execution is done as
expected for both (8-bit and 16-bit) data bus widths.

Signed-off-by: Alexey Brodkin <alexey.brodkin@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
11 years agoARM: highbank: use wfi macro instead of inline asm
Rob Herring [Sun, 2 Dec 2012 17:06:22 +0000 (17:06 +0000)]
ARM: highbank: use wfi macro instead of inline asm

Older compilers don't recognize v7 wfi instruction, so use wfi macro to
fix builds on old compilers.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agoARM: add wfi assembly macro
Rob Herring [Sun, 2 Dec 2012 17:06:21 +0000 (17:06 +0000)]
ARM: add wfi assembly macro

Since wfi instruction is only available on ARMv7, add a conditional
macro for it.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agoarm: rmobile: kzm9g: Adjust ETM trace clock
Tetsuyuki Kobayashi [Tue, 20 Nov 2012 16:29:17 +0000 (16:29 +0000)]
arm: rmobile: kzm9g: Adjust ETM trace clock

Set ETM TRCLK down to 78MHz to get clear wave form.
This patch makes difference only when you use ETM trace connecting JTAG debugger.

Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
11 years agoarm: rmobile: kzm9g: Adjust SDRAM setting
Tetsuyuki Kobayashi [Tue, 20 Nov 2012 16:29:16 +0000 (16:29 +0000)]
arm: rmobile: kzm9g: Adjust SDRAM setting

After stress test, I found some of kzm9g board occures memory failure.
This patch adust SDRAM setting.
- Enlarge drivability on both SDRAM controller and SDRAM itself
- Raise core voltage

Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
11 years agoMerge branch 'u-boot-imx/master' into 'u-boot-arm/master'
Albert ARIBAUD [Sat, 2 Feb 2013 18:29:59 +0000 (19:29 +0100)]
Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'

11 years agoppc: Move mpc83xx clock fields to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:47 +0000 (20:48 +0000)]
ppc: Move mpc83xx clock fields to arch_global_data

Move al mpc83xx fields into arch_global_data and tidy up. Also indent
the nested #ifdef for clarity.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move clock fields to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:46 +0000 (20:48 +0000)]
ppc: Move clock fields to arch_global_data

Move vco_out, cpm_clk, scc_clk, brg_clk into arch_global_data and tidy
up. Leave pci_clk on its own since this should really depend only on
CONFIG_PCI and not any particular chip type.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Remove extra pci_clk fields from global_data
Simon Glass [Thu, 13 Dec 2012 20:48:45 +0000 (20:48 +0000)]
ppc: Remove extra pci_clk fields from global_data

PPC has several of these fields, selected by chip type, although only one
is ever compiled in.

Instead, use a single field. It would be nice if this could be selected
by CONFIG_PCI, but some chips (e.g. mpc5xxx) use pci_clk even when
CONFIG_PCI is not enabled.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoppc: Move brg_clk to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:44 +0000 (20:48 +0000)]
ppc: Move brg_clk to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agox86: Remove reset_status, relocoff from global_data
Simon Glass [Thu, 13 Dec 2012 20:48:43 +0000 (20:48 +0000)]
x86: Remove reset_status, relocoff from global_data

These fields are not used on x86, so punt them.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agox86: Move gd_addr into arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:41 +0000 (20:48 +0000)]
x86: Move gd_addr into arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Add arch/x86/cpu/cpu.c changes after Graeme's comments]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agox86: Set up the global data pointer in C instead of asm
Simon Glass [Thu, 13 Dec 2012 20:48:42 +0000 (20:48 +0000)]
x86: Set up the global data pointer in C instead of asm

We currently assume that the global data pointer is at the start of
struct global_data. We want to remove this restriction, and it is
easiest to do this in C.

Remove the asm code and add equivalent code in C.

This idea was proposed by Graeme Russ here:
   http://patchwork.ozlabs.org/patch/199741/

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Apply Graeme Russ' comments
http://patchwork.ozlabs.org/patch/206305/ here, re-order]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agox86: Remove gdt_addr from arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:40 +0000 (20:48 +0000)]
x86: Remove gdt_addr from arch_global_data

Remove this unused field.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Move tlb_addr and tlb_size to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:39 +0000 (20:48 +0000)]
arm: Move tlb_addr and tlb_size to arch_global_data

Move these fields into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Address tlb_size in this patch as well]
Signed-off-by: Tom Rini <trini@ti.com>
11 years agonds32: Drop tlb_addr from global data
Simon Glass [Thu, 13 Dec 2012 20:48:38 +0000 (20:48 +0000)]
nds32: Drop tlb_addr from global data

This field doesn't appear to be used for anything important, so drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoixp: Move timestamp to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:37 +0000 (20:48 +0000)]
ixp: Move timestamp to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Move timer_reset_value to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:36 +0000 (20:48 +0000)]
arm: Move timer_reset_value to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Move lastinc to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:35 +0000 (20:48 +0000)]
arm: Move lastinc to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoarm: Move tbl to arch_global_data
Simon Glass [Thu, 13 Dec 2012 20:48:34 +0000 (20:48 +0000)]
arm: Move tbl to arch_global_data

Move this field into arch_global_data and tidy up.

Signed-off-by: Simon Glass <sjg@chromium.org>