oweals/u-boot.git
13 years agoOMAP3: SPI driver
Dirk Behme [Sat, 11 Dec 2010 16:01:00 +0000 (11:01 -0500)]
OMAP3: SPI driver

CC: Ruslan N. Araslanov <byaaka@yandex.ru>
Signed-off-by: Ruslan Araslanov <ruslan.araslanov@vitecmm.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoARMV7: OMAP4: twl6030 add battery charging support
Balaji T K [Thu, 25 Nov 2010 10:52:04 +0000 (16:22 +0530)]
ARMV7: OMAP4: twl6030 add battery charging support

Add battery charging support twl6030 driver.
Add support for battery voltage and current measurements.
Add command to get battery status and start/stop battery charging from USB.

Signed-off-by: Balaji T K <balajitk@ti.com>
Tested-by: Steve Sakoman <steve.sakoman@linaro.org>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoMerge branch 'next' of git://git.denx.de/u-boot into next
Sandeep Paulraj [Sat, 11 Dec 2010 15:35:40 +0000 (10:35 -0500)]
Merge branch 'next' of git://git.denx.de/u-boot into next

13 years agoMove LDSCRIPT definitions to board config files.
Wolfgang Denk [Sun, 28 Nov 2010 20:18:58 +0000 (21:18 +0100)]
Move LDSCRIPT definitions to board config files.

Recent cleanup actions resulted in a number of config.mk files that
contained only LDSCRIPT definitions.  Move these into th respective
board config files and remove the now empty config.mk files.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Matthias Fuchs <matthias.fuchs@esd-electronics.com>
Cc: Detlev Zundel <dzu@denx.de>
Cc: Heiko Schocher <hs@denx.de>
Cc: Andre Schwarz <andre.schwarz@matrix-vision.de>
Cc: Peter De Schrijver <p2@mind.be>
Acked-by: Detlev Zundel < dzu@denx.de>
Acked-by: Andre Schwarz <andre.schwarz@matrix-vision.de>
Acked-by: Heiko Schocher<hs@denx.de>
Acked-by: Matthias Fuchs <matthias.fuchs@esd.eu>
13 years agoRemove redundant config.mk files
Wolfgang Denk [Sun, 28 Nov 2010 20:18:57 +0000 (21:18 +0100)]
Remove redundant config.mk files

Recent cleanup actions resulted in a number of config.mk files that
contained only redundant entries like

PLATFORM_CPPFLAGS += -I$(TOPDIR)

or settings of variables that were not used anywhere in the code, like

TEXT_END  = 0xfe080000

Remove these unnecessary files.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Scott McNutt <smcnutt@psyent.com>
Cc: Wolfgang Wegner <w.wegner@astro-kom.de>
Cc: Josef Wagner <Wagner@Microsys.de>
Cc: Tolunay Orkun <torkun@nextio.com>
Cc: Frank Panno <fpanno@delphintech.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Brad Kemp <Brad.Kemp@seranoa.com>
Acked-by: Heiko Schocher<hs@denx.de>
13 years agoDavinci: add support for the ea20 board
Stefano Babic [Tue, 30 Nov 2010 16:46:56 +0000 (11:46 -0500)]
Davinci: add support for the ea20 board

This board uses the OMAP-L138 SOM stacked on a
custom baseboard. It supports SPI Flash, Ethernet
with RMII.

Signed-off-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoDavinci 8xx: Move common functions to share code
Stefano Babic [Tue, 30 Nov 2010 16:32:10 +0000 (11:32 -0500)]
Davinci 8xx: Move common functions to share code

As more Davinci 8xx board can be added, move common code
to be shared between boards.

 * rebased ontop of Sugosh's patches
 * moving the HAWKBOARD_KICK{0,1}_UNLOCK defines to
   arch/arm/include/asm/arch-davinci/davinci_misc.h from to
   arch/arm/include/asm/arch-davinci/da8xx_common.h
 * don't define dram functions in PRELOADER
 * move sync_env_enetaddr into existing EMAC ifdef
 * use misc.c in hawkboard nand_spl

Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda850: Add RMII support for EMAC
Sudhakar Rajashekhara [Thu, 18 Nov 2010 14:59:37 +0000 (09:59 -0500)]
da850: Add RMII support for EMAC

This patch is a port of the work by Sudhakar Rajeshekhara in commit
ab3effbcad8851cc65dc5241a01c064d2030a3b2 of
git://arago-project.org/git/people/sandeep/u-boot-davinci.git.

The da850 UI board has on it an RMII PHY which can be used if the MDC line
to the MII PHY on the baseboard is disabled and the RMII PHY is enabled by
configuring the values of some GPIO pins on the IO expander of the UI board.
This patch implements disabling that line via GPIO2[6], configuring the UI
board's IO expander and setting only the pinmux settings that are needed for
RMII operation.

Tested on da850evm by adding a define for CONFIG_DRIVER_TI_EMAC_USE_RMII.

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
CC: Sandeep Paulraj <s-paulraj@ti.com>
CC: Ben Warren <biggerbadderben@gmail.com>
CC: Mike Frysinger <vapier@gentoo.org>
CC: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoAdd board support for hawkboard
Sughosh Ganu [Tue, 30 Nov 2010 16:25:01 +0000 (11:25 -0500)]
Add board support for hawkboard

The patch adds basic board support for TI's OMAP-L138 based
Hawkboard. This board is pretty similar to the da850 EVM. Support for
nand and network access is added in this version.

The following bootup procedure is used.

At reset, the Rom Boot Loader(RBL), initialises the ddr and the nand
controllers and copies the second stage bootloader(nand_spl) to
RAM. The secondary bootloader then copies u-boot from a predefined
location in the nand flash to the RAM, and passes control to the
u-boot image.

Three config options are supported
* hawkboard_config - Used to create the u-boot.bin. Tftp the
 u-boot.bin image to the RAM from u-boot, and flash to the nand flash
 at address 0xe0000.

* hawkboard_nand_config - Used to generate the secondary
 bootloader(nand_spl) image. This creates an elf file u-boot-spl
 under nand_spl/. Create an AIS signed image using this file, and
 flash it to the nand flash at address 0x20000. The ais file should
 fit in one block.

* hawkboard_uart_config - This is same as the first image, but with
 the TEXT_BASE as expected by the RBL(0xc1080000). Create the AIS

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoRemove board_init_f function from nand_boot.c
Sughosh Ganu [Mon, 29 Nov 2010 01:21:58 +0000 (20:21 -0500)]
Remove board_init_f function from nand_boot.c

Remove the board_init_f function from nand_spl/nand_boot.c. This
 function is to be defined by all boards using the nand_spl
 functionality in their individual board directory.

 Currently this function was being used by the smdk6400 board. Added
 the board specific function definition.

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Acked-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoMove and rename common headers from under
Sughosh Ganu [Mon, 29 Nov 2010 01:21:27 +0000 (20:21 -0500)]
Move and rename common headers from under

board/davinci.

 Move the davinci common headers to the architecture specific
 include file path.

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda850: Enable SPI Flash
Stefano Babic [Thu, 11 Nov 2010 14:38:02 +0000 (15:38 +0100)]
da850: Enable SPI Flash

The patch was already posted to the arago project,
but not yet to mainline. It allows to save environment into
the spi flash. Tested on LogiPD tmdxl138.

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Detlev Zundev <dzu@denx.de>
CC: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda8xx: Add cpu_is_da8xx macros
Sudhakar Rajashekhara [Thu, 11 Nov 2010 14:38:01 +0000 (15:38 +0100)]
da8xx: Add cpu_is_da8xx macros

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
CC: Stefano Babic <sbabic@denx.de>
CC: Detlev Zundev <dzu@denx.de>
CC: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agopl01x: use C structs and readl/writel
Rabin Vincent [Wed, 5 May 2010 03:53:07 +0000 (09:23 +0530)]
pl01x: use C structs and readl/writel

Use C structs for registers, and use readl/writel instead of custom
accessors.

Acked-by: Michael Brandt <michael.brandt@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
13 years agoadd Xilinx_abort_fn to Xilinx_Spartan3_Slave_Serial_fns
Wolfgang Wegner [Fri, 23 Apr 2010 09:08:05 +0000 (11:08 +0200)]
add Xilinx_abort_fn to Xilinx_Spartan3_Slave_Serial_fns

Currently the hardware was left in an undefined state in case Spartan3
serial load failed. This patch adds Xilinx_abort_fn to give the board
a possibility to clean up in this case.

Signed-off-by: Wolfgang Wegner <w.wegner@astro-kom.de>
13 years agoext2: constify file/dir names
Mike Frysinger [Wed, 20 Oct 2010 11:18:09 +0000 (07:18 -0400)]
ext2: constify file/dir names

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agostdio: constify "name" arg in public api
Mike Frysinger [Wed, 20 Oct 2010 11:18:03 +0000 (07:18 -0400)]
stdio: constify "name" arg in public api

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoMerge branch 'next' of git://git.denx.de/u-boot-arm into next
Wolfgang Denk [Tue, 30 Nov 2010 21:13:15 +0000 (22:13 +0100)]
Merge branch 'next' of git://git.denx.de/u-boot-arm into next

13 years agopl01x: use C structs and readl/writel
Rabin Vincent [Wed, 5 May 2010 03:53:07 +0000 (09:23 +0530)]
pl01x: use C structs and readl/writel

Use C structs for registers, and use readl/writel instead of custom
accessors.

Acked-by: Michael Brandt <michael.brandt@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
13 years agoadd Xilinx_abort_fn to Xilinx_Spartan3_Slave_Serial_fns
Wolfgang Wegner [Fri, 23 Apr 2010 09:08:05 +0000 (11:08 +0200)]
add Xilinx_abort_fn to Xilinx_Spartan3_Slave_Serial_fns

Currently the hardware was left in an undefined state in case Spartan3
serial load failed. This patch adds Xilinx_abort_fn to give the board
a possibility to clean up in this case.

Signed-off-by: Wolfgang Wegner <w.wegner@astro-kom.de>
13 years agoDavinci: add support for the ea20 board
Stefano Babic [Tue, 30 Nov 2010 16:46:56 +0000 (11:46 -0500)]
Davinci: add support for the ea20 board

This board uses the OMAP-L138 SOM stacked on a
custom baseboard. It supports SPI Flash, Ethernet
with RMII.

Signed-off-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoDavinci 8xx: Move common functions to share code
Stefano Babic [Tue, 30 Nov 2010 16:32:10 +0000 (11:32 -0500)]
Davinci 8xx: Move common functions to share code

As more Davinci 8xx board can be added, move common code
to be shared between boards.

 * rebased ontop of Sugosh's patches
 * moving the HAWKBOARD_KICK{0,1}_UNLOCK defines to
   arch/arm/include/asm/arch-davinci/davinci_misc.h from to
   arch/arm/include/asm/arch-davinci/da8xx_common.h
 * don't define dram functions in PRELOADER
 * move sync_env_enetaddr into existing EMAC ifdef
 * use misc.c in hawkboard nand_spl

Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda850: Add RMII support for EMAC
Sudhakar Rajashekhara [Thu, 18 Nov 2010 14:59:37 +0000 (09:59 -0500)]
da850: Add RMII support for EMAC

This patch is a port of the work by Sudhakar Rajeshekhara in commit
ab3effbcad8851cc65dc5241a01c064d2030a3b2 of
git://arago-project.org/git/people/sandeep/u-boot-davinci.git.

The da850 UI board has on it an RMII PHY which can be used if the MDC line
to the MII PHY on the baseboard is disabled and the RMII PHY is enabled by
configuring the values of some GPIO pins on the IO expander of the UI board.
This patch implements disabling that line via GPIO2[6], configuring the UI
board's IO expander and setting only the pinmux settings that are needed for
RMII operation.

Tested on da850evm by adding a define for CONFIG_DRIVER_TI_EMAC_USE_RMII.

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
CC: Sandeep Paulraj <s-paulraj@ti.com>
CC: Ben Warren <biggerbadderben@gmail.com>
CC: Mike Frysinger <vapier@gentoo.org>
CC: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoAdd board support for hawkboard
Sughosh Ganu [Tue, 30 Nov 2010 16:25:01 +0000 (11:25 -0500)]
Add board support for hawkboard

The patch adds basic board support for TI's OMAP-L138 based
Hawkboard. This board is pretty similar to the da850 EVM. Support for
nand and network access is added in this version.

The following bootup procedure is used.

At reset, the Rom Boot Loader(RBL), initialises the ddr and the nand
controllers and copies the second stage bootloader(nand_spl) to
RAM. The secondary bootloader then copies u-boot from a predefined
location in the nand flash to the RAM, and passes control to the
u-boot image.

Three config options are supported
* hawkboard_config - Used to create the u-boot.bin. Tftp the
 u-boot.bin image to the RAM from u-boot, and flash to the nand flash
 at address 0xe0000.

* hawkboard_nand_config - Used to generate the secondary
 bootloader(nand_spl) image. This creates an elf file u-boot-spl
 under nand_spl/. Create an AIS signed image using this file, and
 flash it to the nand flash at address 0x20000. The ais file should
 fit in one block.

* hawkboard_uart_config - This is same as the first image, but with
 the TEXT_BASE as expected by the RBL(0xc1080000). Create the AIS

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoRemove board_init_f function from nand_boot.c
Sughosh Ganu [Mon, 29 Nov 2010 01:21:58 +0000 (20:21 -0500)]
Remove board_init_f function from nand_boot.c

Remove the board_init_f function from nand_spl/nand_boot.c. This
 function is to be defined by all boards using the nand_spl
 functionality in their individual board directory.

 Currently this function was being used by the smdk6400 board. Added
 the board specific function definition.

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Acked-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoMove and rename common headers from under
Sughosh Ganu [Mon, 29 Nov 2010 01:21:27 +0000 (20:21 -0500)]
Move and rename common headers from under

board/davinci.

 Move the davinci common headers to the architecture specific
 include file path.

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda850: Enable SPI Flash
Stefano Babic [Thu, 11 Nov 2010 14:38:02 +0000 (15:38 +0100)]
da850: Enable SPI Flash

The patch was already posted to the arago project,
but not yet to mainline. It allows to save environment into
the spi flash. Tested on LogiPD tmdxl138.

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Detlev Zundev <dzu@denx.de>
CC: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoda8xx: Add cpu_is_da8xx macros
Sudhakar Rajashekhara [Thu, 11 Nov 2010 14:38:01 +0000 (15:38 +0100)]
da8xx: Add cpu_is_da8xx macros

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
CC: Stefano Babic <sbabic@denx.de>
CC: Detlev Zundev <dzu@denx.de>
CC: Ben Gardiner <bengardiner@nanometrics.ca>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoext2: constify file/dir names
Mike Frysinger [Wed, 20 Oct 2010 11:18:09 +0000 (07:18 -0400)]
ext2: constify file/dir names

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agostdio: constify "name" arg in public api
Mike Frysinger [Wed, 20 Oct 2010 11:18:03 +0000 (07:18 -0400)]
stdio: constify "name" arg in public api

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoboot cmds: convert to getenv_yesno() with autostart
Mike Frysinger [Wed, 20 Oct 2010 11:17:55 +0000 (07:17 -0400)]
boot cmds: convert to getenv_yesno() with autostart

Use the new helper func to clean up duplicate logic handling of the
autostart env var.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoctype: constify lookup table
Mike Frysinger [Wed, 20 Oct 2010 11:17:45 +0000 (07:17 -0400)]
ctype: constify lookup table

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoimage: constify lookup tables
Mike Frysinger [Wed, 20 Oct 2010 11:17:39 +0000 (07:17 -0400)]
image: constify lookup tables

These are pure lookup tables -- no need to be writable.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agocmd_itest: constify & localize op table
Mike Frysinger [Wed, 20 Oct 2010 11:17:33 +0000 (07:17 -0400)]
cmd_itest: constify & localize op table

No one else needs this table.  While we're here, use the standard
ARRAY_SIZE helper macro.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agocmd_date: constify
Mike Frysinger [Wed, 20 Oct 2010 11:17:23 +0000 (07:17 -0400)]
cmd_date: constify

Many strings in this file need not be writable.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agostring_to_ip: constify "s" arg
Mike Frysinger [Wed, 20 Oct 2010 11:16:58 +0000 (07:16 -0400)]
string_to_ip: constify "s" arg

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agostring_to_VLAN: constify "var" arg
Mike Frysinger [Wed, 20 Oct 2010 11:16:48 +0000 (07:16 -0400)]
string_to_VLAN: constify "var" arg

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agocopy_filename: constify "src" arg
Mike Frysinger [Wed, 20 Oct 2010 11:16:40 +0000 (07:16 -0400)]
copy_filename: constify "src" arg

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoautocomplete: remove runtime handler install
Mike Frysinger [Wed, 20 Oct 2010 07:52:39 +0000 (03:52 -0400)]
autocomplete: remove runtime handler install

Rather than add runtime overhead of installing completion handlers, do it
statically at build time.  This requires a new build time helper macro to
declare a command and the completion handler at the same time.  Then we
convert the env related funcs over to this.

This gives an opportunity to also unify the U_BOOT_CMD macros.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agodo_reset: unify duplicate prototypes
Mike Frysinger [Wed, 20 Oct 2010 07:41:17 +0000 (03:41 -0400)]
do_reset: unify duplicate prototypes

The duplication of the do_reset prototype has gotten out of hand,
and they're not all in sync.  Unify them all in command.h.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agodo_bootd: unify duplicate prototypes
Mike Frysinger [Wed, 20 Oct 2010 07:36:26 +0000 (03:36 -0400)]
do_bootd: unify duplicate prototypes

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agodo_bootm: unify duplicate prototypes
Mike Frysinger [Wed, 20 Oct 2010 07:35:39 +0000 (03:35 -0400)]
do_bootm: unify duplicate prototypes

The duplication of the do_bootm prototype has gotten out of hand,
and they're pretty much all outdated (wrt constness).  Unify them
all in command.h.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agocommand_t: punt unused type
Mike Frysinger [Wed, 20 Oct 2010 07:35:09 +0000 (03:35 -0400)]
command_t: punt unused type

The recent command clean up to constify the argv option to command funcs
missed the command_t type itself.  This is probably because there are no
build time warnings from it because no one is actually using this thing.
So just punt it rather than fix it.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agocmd_mii: localize & constify local funcs/data
Mike Frysinger [Wed, 20 Oct 2010 05:06:48 +0000 (01:06 -0400)]
cmd_mii: localize & constify local funcs/data

No need for these structures to be writable or global.

While we're here, also drop local versions of the ARRAY_SIZE macro.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoPrepare v2010.12-rc2 v2010.12-rc2
Wolfgang Denk [Sun, 28 Nov 2010 18:44:59 +0000 (19:44 +0100)]
Prepare v2010.12-rc2

Signed-off-by: Wolfgang Denk <wd@denx.de>
13 years agocfi_flash: fix bug introduced while recent change to flash_get_size()
Anatolij Gustschin [Sun, 28 Nov 2010 01:13:33 +0000 (02:13 +0100)]
cfi_flash: fix bug introduced while recent change to flash_get_size()

commit ec50a8e389863ac35bfd9d9a2e8b30187318e59e
"cfi_flash: handle 'chip size exceeds address window' situation"
added 3rd argument to flash_get_size() but didn't fix all the
function calls from the board specific code. Many boards have
their own flash_get_size() definitions in the board code and
use them there, but some boards (e.g. tqm834x, tqm85xx, pdm360ng)
use flash_get_size() from the cfi_flash.c driver.

The bug shows up if the value of the "max_size" argument (which
is not defined when calling the function with two arguments)
happens to be less than "info->size". In this case on the
affected boards we end up with a bank of reduced size and
in the worst case might even be not able to update U-Boot or
to boot the kernel from flash:

=> fli

Bank # 1: CFI conformant FLASH (32 x 16)  Size: 0 kB in 1 Sectors
  AMD Standard command set, Manufacturer ID: 0x01, Device ID: 0x227E
  Erase timeout: 4096 ms, write timeout: 1 ms
  Buffer write timeout: 3 ms, buffer size: 64 bytes

  Sector Start Addresses:
  F0000000   RO

Bank # 2: CFI conformant FLASH (32 x 16)  Size: 128 MB in 512 Sectors
  AMD Standard command set, Manufacturer ID: 0x01, Device ID: 0x227E
  Erase timeout: 4096 ms, write timeout: 1 ms
  Buffer write timeout: 3 ms, buffer size: 64 bytes

  Sector Start Addresses:
  F8000000        F8040000        F8080000        F80C0000        F8100000
  F8140000        F8180000        F81C0000        F8200000        F8240000
  ...

E.g., updating U-Boot is not possible now:

=> protect off ${u-boot_addr} +${u-boot_size}
Error: end address (0xf007ffff) not in flash!
Bad address format
=> era ${u-boot_addr} +${u-boot_size}
Error: end address (0xf007ffff) not in flash!
Bad address format

This patch removes the 3rd argument of flash_get_size() again
and sets "max_size" in the function itself instead of passing
it as a function argument.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
13 years agoDaVinci: DM355 Leopard : Fix for ARM Relocation support
Sandeep Paulraj [Sat, 27 Nov 2010 23:50:11 +0000 (18:50 -0500)]
DaVinci: DM355 Leopard : Fix for ARM Relocation support

Fix for ARM Relocation support

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoDaVinci DM365: Fix for ARM Relocation support
Sandeep Paulraj [Sat, 27 Nov 2010 23:50:22 +0000 (18:50 -0500)]
DaVinci DM365: Fix for ARM Relocation support

Fix for ARM Relocation support

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoDaVinci DM355: Fix for ARM Relocation support
Sandeep Paulraj [Sat, 27 Nov 2010 23:49:49 +0000 (18:49 -0500)]
DaVinci DM355: Fix for ARM Relocation support

Fix for ARM Relocation support

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
13 years agoMerge branch 'master' of git://git.denx.de/u-boot-ppc4xx
Wolfgang Denk [Sun, 28 Nov 2010 16:44:00 +0000 (17:44 +0100)]
Merge branch 'master' of git://git.denx.de/u-boot-ppc4xx

13 years agoFix compiler warning in fdt_support.c
Dirk Behme [Sun, 21 Nov 2010 19:19:34 +0000 (20:19 +0100)]
Fix compiler warning in fdt_support.c

Fix compiler warning

fdt_support.c: In function 'of_bus_default_count_cells':
fdt_support.c:957: warning: passing argument 1 of '__swab32p' discards qualifiers from pointer target type
fdt_support.c:965: warning: passing argument 1 of '__swab32p' discards qualifiers from pointer target type

be32_to_cpup() expects an 'u32 *' while prop is 'const u32 *'.

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
13 years agoDevkit8000: Fix build after introduction of GENERATED_GBL_DATA_SIZE
Thomas Weber [Thu, 18 Nov 2010 07:45:25 +0000 (08:45 +0100)]
Devkit8000: Fix build after introduction of GENERATED_GBL_DATA_SIZE

This patch fixes the issue by defining and using
CONFIG_SYS_INIT_RAM_SIZE and CONFIG_SYS_INIT_RAM_ADDR.

This patch adopts the
commit 31bfcf1c5776df3d90286aa15104c45096d53dc6
from Steve Sakoman and Sandeep Paulraj on Devkit8000.

Signed-off-by: Thomas Weber <weber@corscience.de>
13 years agoppc4xx: Flush complete dcache in relocate_code()
Stefan Roese [Fri, 26 Nov 2010 14:45:34 +0000 (15:45 +0100)]
ppc4xx: Flush complete dcache in relocate_code()

When the cache is enabled in SDRAM we need to flush not only the global
data area but also the bd_info struct in relocate_code. This patch now
flushed the complete dcache (all dcache lines) via flush_dcache() instead
of adding a flush_dcache_range() call for bd_info since this is faster.

Signed-off-by: Stefan Roese <sr@denx.de>
13 years agoppc4xx/POST: Handle cached SDRAM correctly in Denali (440EPx) ECC POST
Stefan Roese [Fri, 26 Nov 2010 14:45:22 +0000 (15:45 +0100)]
ppc4xx/POST: Handle cached SDRAM correctly in Denali (440EPx) ECC POST

This patch fixes a problem in the Denali (440EPx) SDRAM ECC POST test.
When cache is enabled in the SDRAM area, the values written to SDRAM
need to be flushed from cache to SDRAM using the dcfb instruction.

Without this patch the POST ECC test failed. Now its working again on
platforms with cache enabled in SDRAM.

Signed-off-by: Stefan Roese <sr@denx.de>
13 years agoCoding Style (white space) cleanup
Wolfgang Denk [Sat, 27 Nov 2010 22:30:56 +0000 (23:30 +0100)]
Coding Style (white space) cleanup

Signed-off-by: Wolfgang Denk <wd@denx.de>
13 years agopowerpc: cmd_ecctest: Use return value of cmd_usage
Thomas Weber [Thu, 25 Nov 2010 07:05:30 +0000 (08:05 +0100)]
powerpc: cmd_ecctest: Use return value of cmd_usage

Use the return value of cmd_usage instead of ignoring this
and returning a 1.

Signed-off-by: Thomas Weber <weber@corscience.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
13 years agogdsys: osd: Use return value of cmd_usage
Thomas Weber [Thu, 25 Nov 2010 07:05:29 +0000 (08:05 +0100)]
gdsys: osd: Use return value of cmd_usage

Use the return value of cmd_usage instead of ignoring this
and returning a 1.

Signed-off-by: Thomas Weber <weber@corscience.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
13 years agocommon/cmd_nvedit: Use return value of cmd_usage
Thomas Weber [Thu, 25 Nov 2010 07:05:28 +0000 (08:05 +0100)]
common/cmd_nvedit: Use return value of cmd_usage

Use the return value of cmd_usage instead of ignoring this
and returning a 1.

Signed-off-by: Thomas Weber <weber@corscience.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
13 years agoCommon/command: Guard strchr/strlen from NULL pointer
Thomas Weber [Wed, 24 Nov 2010 12:07:51 +0000 (13:07 +0100)]
Common/command: Guard strchr/strlen from NULL pointer

Guard strchr/strlen from being called with NULL pointer.
This line is crashing when command "env" is called without subcommand.

The cmd is NULL in this case because the calling function "do_env"
decremented the argc without checking if there are still arguments available.

Signed-off-by: Thomas Weber <weber@corscience.de>
13 years agoCommon/cmd_nvedit: Check for env subcommand
Thomas Weber [Wed, 24 Nov 2010 12:07:52 +0000 (13:07 +0100)]
Common/cmd_nvedit: Check for env subcommand

The env command needs one subcommand. If this is not available
print the usage help.

Signed-off-by: Thomas Weber <weber@corscience.de>
13 years agosort and reformat boards.cfg
Eric Cooper [Tue, 23 Nov 2010 19:19:15 +0000 (14:19 -0500)]
sort and reformat boards.cfg

update suggested sort command in comment to produce desired order
suggest use of "column -t" to reformat

Signed-off-by: Eric Cooper <ecc@cmu.edu>
13 years agoFix jornada memory init
Kristoffer Ericson [Sat, 6 Nov 2010 13:24:27 +0000 (14:24 +0100)]
Fix jornada memory init

* Fix memory initialization. This fixes the problem
  with kernel oopses during heavy load.

* Cleanup pinsetup, which for reference is among
  other things needed for proper flash erasing.

Signed-off-by: Kristoffer Ericson <kristoffer.ericson@gmail.com>
13 years ago74xx_7xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Thu, 25 Nov 2010 11:14:07 +0000 (12:14 +0100)]
74xx_7xx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago8260: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Wed, 24 Nov 2010 18:19:08 +0000 (19:19 +0100)]
8260: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago824x: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Tue, 23 Nov 2010 22:48:56 +0000 (23:48 +0100)]
824x: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago8220: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Thu, 25 Nov 2010 11:15:31 +0000 (12:15 +0100)]
8220: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago5xxx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Tue, 23 Nov 2010 12:20:22 +0000 (13:20 +0100)]
5xxx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago512x: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Mon, 22 Nov 2010 22:36:42 +0000 (23:36 +0100)]
512x: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Anatolij Gustschin <agust@denx.de>
Cc: Timur Tabi <timur@freescale.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago5xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Mon, 22 Nov 2010 21:44:01 +0000 (22:44 +0100)]
5xx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago8xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Sat, 20 Nov 2010 14:07:45 +0000 (15:07 +0100)]
8xx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago86xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Mon, 22 Nov 2010 07:31:41 +0000 (08:31 +0100)]
86xx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago83xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Thu, 25 Nov 2010 11:15:34 +0000 (12:15 +0100)]
83xx: Cleanup for partial linking and --gc-sections

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Kim Phillips <kim.phillips@freescale.com>
Cc: Haiying Wang <r54964@freescale.com>
13 years agoppc4xx/NAND: Reduce size of NAND SPL image
Stefan Roese [Tue, 23 Nov 2010 13:32:48 +0000 (14:32 +0100)]
ppc4xx/NAND: Reduce size of NAND SPL image

This is needed for the canyonlands_nand build target. Without it
the resulting image won't fit into 4k.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Acked-by: Scott Wood <scottwood@freescale.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoppc4xx: Cleanup for partial linking and --gc-sections
Wolfgang Denk [Sun, 21 Nov 2010 19:55:42 +0000 (20:55 +0100)]
ppc4xx: Cleanup for partial linking and --gc-sections

This commit adapts 4xx boards for partial linking with --gc-sections.

Signed-off-by: Stefan Roese <sr@denx.de>
Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Tirumala Marri <tmarri@apm.com>
Cc: David Updegraff <dave@cray.com>
Cc: Matthias Fuchs <matthias.fuchs@esd-electronics.com>
Cc: Dirk Eibach <eibach@gdsys.de>
Cc: Larry Johnson <lrj@acm.org>
Cc: Peter De Schrijver <p2@mind.be>
Cc: Niklaus Giger <niklaus.giger@netstal.com>
Cc: Daniel Poirot <dan.poirot@windriver.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoPOWERPC: enable --gc-sections and -ffunction-sections -fdata-sections
Wolfgang Denk [Sun, 21 Nov 2010 19:46:02 +0000 (20:46 +0100)]
POWERPC: enable --gc-sections and -ffunction-sections -fdata-sections

The switch from archive libraries to partial linking has introduced a
number of problems, that are non-trivial to solve.  For example, it is
no longer possible to include individual object files in the linker
script as we did before for example in the case of boards with
embedded environment to fill up the gap caused by the need to align
the environment on flash erase block boundaries.

The best (but unfortunately not easiest) approach to address this
problem is to enable -ffunction-sections (and -fdata-sections) so
we can again (and even in much finer granularity) place certain code
where we want it.  When doing this step, it seems only consequent to
also add --gc-sections which has the added benefit of reducing the
memory footprint of the U-Boot image (both in flash and in RAM).

Unfortunately, this requires changes to a lot of linker scripts.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Kim Phillips <kim.phillips@freescale.com>
Cc: Andy Fleming <afleming@gmail.com>
Cc: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Stefan Roese <sr@denx.de>
13 years ago83xx: Fix NAND_SPL link address
Scott Wood [Wed, 24 Nov 2010 13:28:40 +0000 (13:28 +0000)]
83xx: Fix NAND_SPL link address

Apply the same fix for 83xx as was done for 85xx in commit
96196a1f7546904563994d2d041804a816d7c139.

Without this, NAND SPLs are built with the text base intended for the main
image, resulting in a broken, very large u-boot-nand.bin.

The block of defines for NAND boot is moved closer to where
CONFIG_SYS_TEXT_BASE is defined.  We can't directly use
CONFIG_SYS_NAND_U_BOOT_DST in the definition of CONFIG_SYS_TEXT_BASE because
autoconf.mk will include the literal text "CONFIG_SYS_NAND_U_BOOT_DST",
but at least keep them close and point out that they're supposed to be
the same.

Signed-off-by: Scott Wood <scottwood@freescale.com>
13 years agoppc4xx: Fix build problems of IBM DDR2 NAND booting targets
Stefan Roese [Tue, 23 Nov 2010 13:32:06 +0000 (14:32 +0100)]
ppc4xx: Fix build problems of IBM DDR2 NAND booting targets

This change is needed to compile the PPC4xx NAND booting targets
equipped with the IBM DDR2 SDRAM controller.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoPPChameleonEVB and CATcenter need a custom linker script
Wolfgang Denk [Sun, 21 Nov 2010 16:04:17 +0000 (17:04 +0100)]
PPChameleonEVB and CATcenter need a custom linker script

These boards use an embedded environment, which is not supported by the
generic arch/powerpc/cpu/ppc4xx/u-boot.lds script.

The breakage was introduced by commit 2cd95a2 "ppc4xx: Remove board
specific linker scripts from most PPC4xx boards"

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Andrea Marson <andrea.marson@dave-tech.it>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoarch/powerpc/*/config.mk: make CONFIG_SYS_LDSCRIPT settings work
Wolfgang Denk [Sun, 21 Nov 2010 15:34:05 +0000 (16:34 +0100)]
arch/powerpc/*/config.mk: make CONFIG_SYS_LDSCRIPT settings work

As we try to get rid of board specific config.mk files we must
provide a way for board specific settings of the LDSCRIPT variable
(path to the linker script) where needed.

We now implement the following hierarchy:

- Highest priority has a "#define CONFIG_SYS_LDCONFIG" in the board
  config file.
- If CONFIG_SYS_LDCONFIG is not set, and the system is booting from
  NAND (CONFIG_NAND_SPL is set), then a board specific linker
  script board/$(BOARDDIR)/u-boot-nand.lds gets used.
- If we are not booting from NAND, we test if a processor specific
  linker script arch/powerpc/cpu/$(CPU)/u-boot.lds exists; if so we
  use that.
- As default, arch/powerpc/config.mk gets used.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Kim Phillips <kim.phillips@freescale.com>
Cc: Kumar Gala <kumar.gala@freescale.com>
Cc: Andy Fleming <afleming@gmail.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years agocpu/ppc4xx/Makefile: build only needed object files
Wolfgang Denk [Sat, 20 Nov 2010 23:03:32 +0000 (00:03 +0100)]
cpu/ppc4xx/Makefile: build only needed object files

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agocommon/Makefile: don't include env_embedded.o into libcommon
Wolfgang Denk [Sat, 20 Nov 2010 14:04:02 +0000 (15:04 +0100)]
common/Makefile: don't include env_embedded.o into libcommon

Some boards use an embedded environment, where env_embedded.o has to
be linked at a special position in the U-Boot image; to make this
possible, we do not include it into libcommon.o for such boards.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agocam5200_niosflash: fix build warnings
Wolfgang Denk [Wed, 24 Nov 2010 21:27:08 +0000 (22:27 +0100)]
cam5200_niosflash: fix build warnings

Fix warnings:

cam5200_flash.c: In function 'write_word_32':
cam5200_flash.c:443: warning: dereferencing type-punned pointer will break strict-aliasing rules
cam5200_flash.c: In function 'write_word_16':
cam5200_flash.c:684: warning: dereferencing type-punned pointer will break strict-aliasing rules

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoWINBOND_83C553: enable only on boards that actually use it.
Wolfgang Denk [Tue, 23 Nov 2010 22:17:18 +0000 (23:17 +0100)]
WINBOND_83C553: enable only on boards that actually use it.

So far, only the BAB7xx board would call the initialise_w83c553f()
function for the WINBOND 83C553 chip, even though some other boards
(HIDDEN_DRAGON, Sandpoint8240, Sandpoint8245) enabled it in their
board configuration.  These boards were also missing other config
settings needed for that, which resulted in build errors like this:

drivers/pci/libpci.o:(.got2+0x84): undefined reference to `ide_bus_offset'

Switch arch/powerpc/lib/board.c to call initialise_w83c553f() not on a
per-board base, but when a WINBOND_83C553 in enabled in a
configuration (like BAB7xx), and disable it in the boards that had
this set so far.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Yusdi Santoso <yusdi_santoso@adaptec.com>
Cc: Jim Thompson <jim@musenki.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoIDS8247: remove redundant flash.c file
Wolfgang Denk [Tue, 23 Nov 2010 23:00:16 +0000 (00:00 +0100)]
IDS8247: remove redundant flash.c file

The IDS8247 board is configured to use the CFI flash driver, so drop
the now redundant custom flash.c file.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoe1000: fix compile warning
Wolfgang Denk [Mon, 22 Nov 2010 08:48:45 +0000 (09:48 +0100)]
e1000: fix compile warning

Get rid of compiler warning:
e1000.c: In function 'e1000_transmit':
e1000.c:5028: warning: passing argument 1 of 'virt_to_phys' discards qualifiers from pointer target type

Signed-off-by: Wolfgang Denk <wd@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agobarco: drop unsupported board configuration
Wolfgang Denk [Tue, 23 Nov 2010 12:45:46 +0000 (13:45 +0100)]
barco: drop unsupported board configuration

The barco board appears to be unmaintained since it was added about 5
years ago. The environment location has probably never been correct.
Drop it.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Marc Leeman <marc.leeman@barco.com>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoERIC: drop unsupported board configuration
Wolfgang Denk [Sun, 21 Nov 2010 19:40:23 +0000 (20:40 +0100)]
ERIC: drop unsupported board configuration

The ERIC board appears to be unmaintained for more than 9 years. The
environment location has probably never been correct, and has been
definitely broken since for at least a year.  Drop it.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Swen Anderson <sand@peppercon.de>
Acked-by: Stefan Roese <sr@denx.de>
13 years agoMerge branch 'master' of /home/wd/git/u-boot/custodians
Wolfgang Denk [Fri, 26 Nov 2010 20:52:52 +0000 (21:52 +0100)]
Merge branch 'master' of /home/wd/git/u-boot/custodians

13 years agoMerge branch 'master' of git://git.denx.de/u-boot-usb
Wolfgang Denk [Fri, 26 Nov 2010 20:52:30 +0000 (21:52 +0100)]
Merge branch 'master' of git://git.denx.de/u-boot-usb

13 years agoMerge branch 'master' of git://git.denx.de/u-boot-arm
Wolfgang Denk [Fri, 26 Nov 2010 20:33:14 +0000 (21:33 +0100)]
Merge branch 'master' of git://git.denx.de/u-boot-arm

13 years agousb: Remove usb_dev_init() from ehci-ppc4xx.c
Stefan Roese [Fri, 26 Nov 2010 14:43:44 +0000 (15:43 +0100)]
usb: Remove usb_dev_init() from ehci-ppc4xx.c

Calling usb_dev_init() from within the EHCI host driver is wrong.
The EHCI host driver should have no dependency/interconnection to the
USB device driver.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
13 years agousb: Clear CMD_RUN while issuing CMD_RESET in ehci_reset()
Stefan Roese [Fri, 26 Nov 2010 14:44:00 +0000 (15:44 +0100)]
usb: Clear CMD_RUN while issuing CMD_RESET in ehci_reset()

This patch fixes a problem noticed on lwmon5 (PPC440EPx) using the
common EHCI driver, when "usb reset" is issued multiple times.
Upon the 2nd (and further) "usb reset" command, the command fails
with the following messages:

=> usb reset
(Re)start USB...
USB:   Register 1111 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 5 USB Device(s) found
       scanning bus for storage devices... 2 Storage Device(s) found
=> usb reset
(Re)start USB...
USB:   EHCI fail to reset
Error, couldn't init Lowlevel part

This patch fixes this problem. Now "usb reset" can be called multiple
times.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
13 years agoarm1176: bugfix: fix start.S for ELF relocation
Albert Aribaud [Fri, 26 Nov 2010 18:42:10 +0000 (19:42 +0100)]
arm1176: bugfix: fix start.S for ELF relocation

The start.S file was only half-rewritten for ELF relocations.
This bugfix completes the rewrite.

Signed-off-by: Albert Aribaud <albert.aribaud@free.fr>
13 years agoarm: add ELF relocation support to rest of cpus
Albert Aribaud [Thu, 25 Nov 2010 21:45:02 +0000 (22:45 +0100)]
arm: add ELF relocation support to rest of cpus

bulk addition of ELF relocation support to ARM cpus
arm946es, arm720t,arm920t, arm925t, arm_intcm, ixp,
lh7a40x, s3c44b0, and sa1100.

Signed-off-by: Albert Aribaud <albert.aribaud@free.fr>
13 years agousb: Add WATCHDOG_RESET call to polling loop
Stefan Roese [Fri, 26 Nov 2010 14:43:28 +0000 (15:43 +0100)]
usb: Add WATCHDOG_RESET call to polling loop

This watchdog reset call is needed here, otherwise the lwmon5 board
(PPC440EPx based) will reset upon the "usb reset" command.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
13 years agousb: fix for USB_ST_STALLED status reporting in ehci_submit_async()
Anatolij Gustschin [Tue, 2 Nov 2010 10:47:29 +0000 (11:47 +0100)]
usb: fix for USB_ST_STALLED status reporting in ehci_submit_async()

Checking the status field of the qTD token in the current code
do not take into acount cases where endpoint stall (halted) bit
is set together with XactErr status bit. As a result clearing
stall on an endpoint won't be done if this status bit was also
set. Check for halted bit and report USB_ST_STALLED status
if the host controller also indicates endpoit stall condition.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
13 years agoSeagate FreeAgent DockStar support
Eric Cooper [Wed, 24 Nov 2010 11:41:32 +0000 (17:11 +0530)]
Seagate FreeAgent DockStar support

start with sheevaplug configuration
add modifications by Alexander Holler <holler@ahsoftware.de>
    change RAM definitions to one bank (128 MB)
    change ident string and prompt
define MTD partitions and default environment variables
add support for LEDs

Signed-off-by: Eric Cooper <ecc@cmu.edu>
13 years agoFix NAND booting make target
Stefan Roese [Wed, 24 Nov 2010 06:12:55 +0000 (07:12 +0100)]
Fix NAND booting make target

Without this fix, the NAND_SPL target (in nand_spl/) is not built
at all for those boards defining NAND_U_BOOT=y in boards.cfg.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
14 years agoBlackfin: tweak objects specified before embedded environment
Mike Frysinger [Sat, 20 Nov 2010 00:28:56 +0000 (19:28 -0500)]
Blackfin: tweak objects specified before embedded environment

The partial linking patch changes how objects are specified to the linker
and breaks boards with an embedded environment.  So we need to tweak the
list of objects we specify via the linker script that go in the gap before
the embedded env to work with this new behavior.  This fixes linker errors
for all the boards in question.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
14 years agoBlackfin: drop initcode.o from combined object
Mike Frysinger [Sat, 20 Nov 2010 00:17:53 +0000 (19:17 -0500)]
Blackfin: drop initcode.o from combined object

We explicitly link in the initcode.o in the Blackfin linker script, so
there is no need to merge it into the main common object for the linker
to pull in itself.  This also fixes duplicate symbol errors with the new
partial linking logic.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>