Commit Graph

12778 Commits

Author SHA1 Message Date
Andreas Bießmann
f4278b716c avr32: fixup definitions to ATMEL_BASE_xxx
Signed-off-by: Andreas Bießmann <biessmann@corscience.de>
2011-05-18 07:56:50 +02:00
Andreas Bießmann
5d73bc7af7 avr32: rename memory-map.h -> hardware.h
Signed-off-by: Andreas Bießmann <biessmann@corscience.de>
2011-05-18 07:56:50 +02:00
Wolfgang Denk
535abb96fb Merge branch 'master' of git://git.denx.de/u-boot-nand-flash 2011-05-15 23:23:36 +02:00
Wolfgang Denk
77467e2560 Merge branch 'master' of git://git.denx.de/u-boot-mpc85xx 2011-05-15 23:20:10 +02:00
Stefan Roese
a9c847cb38 nand_spl: nand_boot.c: Remove CONFIG_SYS_NAND_READ_DELAY
There are multiple reasons why this define should be removed:

First it saves some space and therefore fixes a problem we have on
the canyonlands_nand and glacier_nand targets right now.

Second, the define was hackish and would most likely not work on all
board using nand_boot.c. Boards not providing a real dev_ready()
function should implement a board specific function instead.

I checked and it seems, that all boards using nand_boot.c right now
already implement a board specific dev_ready() function. So this
patch should not break any boards and will result in smaller
NAND_SPL images.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Sughosh Ganu <urwithsughosh@gmail.com>
Cc: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Tested-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Scott Wood <scottwood@freescale.com>
2011-05-13 11:13:21 -05:00
Stefan Roese
a89a990159 nand_spl: nand_boot.c: Init nand_chip.options to 0
Patch 65a9db7b [nand_spl: Fix large page nand_command()] broke
nand booting on canyonlands. "options" has to be initialized to
0. If not, boards might have the NAND_BUSWIDTH_16 bit set,
resulting in wrong offset calculation.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Alex Waterman <awaterman@dawning.com>
Signed-off-by: Scott Wood <scottwood@freescale.com>
2011-05-13 11:07:49 -05:00
Alex Waterman
8370978318 Decreases code size of the nand_spl
The canyonland boards nand_spl size is just under the maximum 4KByte size. This
patch decreases the size of the nand_spl to make a previous commit - commit
65a9db7be0 - fit in the nand_spl.

Signed-off-by: Alex Waterman <awaterman@dawning.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Scott Wood <scottwood@freescale.com>
2011-05-13 11:07:01 -05:00
Wolfgang Denk
91081e01b1 Revert "Fix building tools alone with host compiler"
This reverts commit bbc6353c74.
It breaks building on many systems:
...
.../common/env_embedded.c:28:20: fatal error: config.h: No such file or directory
compilation terminated.
.../common/image.c:27:20: fatal error: common.h: No such file or directory
compilation terminated.
.../lib/crc32.c:12:20: fatal error: common.h: No such file or directory
compilation terminated.
.../lib/md5.c:28:22: fatal error: compiler.h: No such file or directory
compilation terminated.
.../lib/sha1.c:33:20: fatal error: common.h: No such file or directory
compilation terminated.
2011-05-13 13:37:20 +02:00
York Sun
d49f8e04db powerpc/mpc8xxx: reword max tCKmin message
Reword "The DIMM max tCKmin is ..." to "The DDR clock is faster than the slowest
DIMM(s) can support". Fixed interger type in printf as well.

Signed-off-by: York Sun <yorksun@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2011-05-13 00:36:11 -05:00
Timur Tabi
ee4756d4cb powerpc/85xx: fix compatible property for the L2 cache node
The compatible property for the L2 cache node (on 85xx systems that don't
have a CPC) was using a value for the property length that did not match
the actual length of the property.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2011-05-13 00:36:11 -05:00
Nobuhiro Iwamatsu
3500e9aed6 kwbimage: Fix check variable of checksum
calc_hdrcsum two times are checked. checksumi of exthdr is not checked.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
CC: Prafulla Wadaskar <prafulla@marvell.com>
2011-05-12 23:53:41 +02:00
Mike Frysinger
201a017c2f examples: add smc911x_eeprom to clean target
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-05-12 23:52:10 +02:00
Macpaul Lin
ac56032676 ftpmu010.h: fix some missing declaration in header
Fix some missing declaration in header.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:44:33 +02:00
Macpaul Lin
10ba1d3cff ftsmc020: add missing definitions
Add missing definitions in header file according to datasheet.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:43:38 +02:00
Macpaul Lin
56cd247232 ftsmc020: un-nest the register structure in header
Un-nestted the register structure in ftsmc020.h

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:43:33 +02:00
Macpaul Lin
f194f6ba5b ftsmc020: fix relocation
Avoid relocation problem by fix global declaration.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:43:27 +02:00
Macpaul Lin
4bed7265f2 ftide020: add faraday ide ahb controller
Faraday's ftide020_s is an IDE-AHB controller for SoC design.
This patch add the u-boot driver (PIO) of ftide020 ATA (IDE) driver.
IDE commands include read, info, and other functions has been implemented.

Because this IDE controller support AHB interface only which is differ
from other most IDE controller supports PCI interface. Some registers
access is required during CMD/DATA I/O. Hence a configuration
"CONFIG_IDE_AHB" is required to be defined according to the feature in
cmd_ide.c.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:41:44 +02:00
Ben Gardiner
7124015ada README.arm-relocation: get relocated address in gdb
When your emulator is connected at reset (or is used to load u-boot)
it is possible to get the relocation address from the gd->relocaddr
since gd is always in r8 (on ARM) it is addressable before the
gdb has remapped symbols.

Document this alternate method in-line with the original method
written by Heiko Schocher.

Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
CC: Heiko Schocher <hs@denx.de>
CC: Wolfgang Denk <wd@denx.de>
Acked-by: Heiko Schocher <hs@denx.de>
2011-05-12 23:34:02 +02:00
Ben Gardiner
f4379ceff0 README.arm-relocation: get relocated address from bdinfo
The bdinfo command prints the relocaddr on ARM as it does
on PPC.

Update the debugging instructions for arm relocation to
reflect this fact rather than requiring that the user
rebuild the u-boot image using -DDEBUG.

Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
CC: Wolfgang Denk <wd@denx.de>
Acked-by: Heiko Schocher <hs@denx.de>
2011-05-12 23:33:32 +02:00
Macpaul Lin
5902e8f711 cosmetic: cmd_bdinfo.c: clean up by using checkpatch.pl
cmd_bdinfo.c: clean up with 2.6.38 checkpatch.pl

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
Acked-by: Detlev Zundel <dzu@denx.de>
2011-05-12 23:31:07 +02:00
Eric Bénard
25ee9616de mp2usb: finish the removal
- remove from boards.cfg
- add to doc/README.scrapyard

Signed-off-by: Eric Bénard <eric@eukrea.com>
2011-05-12 23:28:40 +02:00
Detlev Zundel
6abe6fb68b README: Clarify difference of CONFIG_WATCHDOG and CONFIG_HW_WATCHDOG
Now that we have the documentation, the code should be changed to reflect
it ;)

Asd far as I can see, these are the places where HW_WATCHDOG is used
instead of WATCHDOG:

arch/blackfin/cpu/blackfin/watchdog.c
arch/m68k/cpu/mcf547x_8x/cpu.c

The relevant maintainers are on CC.

Signed-off-by: Detlev Zundel <dzu@denx.de>
Cc: Mike Frysinger <vapier@gentoo.org>
Cc: TsiChungLiew <Tsi-Chung.Liew@freescale.com>
2011-05-12 23:26:07 +02:00
Macpaul Lin
b1196a3fba ftsdmc021: add register definitions of ftsdmc021
Support registers definitions of ftsdmc021 SDRAM controller.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:25:28 +02:00
Macpaul Lin
4bb87d2b3f ftahbc020s: Faraday FTAHBC020s AHB Bus Controller
ftahbc020s.h provides basic definitions of this controller
to help a SoC which use this AHB Controller could
do scalable software settings in lowlevel_init.S.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
2011-05-12 23:24:11 +02:00
Joakim Tjernlund
cd8c87756a Fix a few gcc warnings.
Noticed while building all of mpc8xx. Also
constify usage string in timer.c
Warnings fixed are:
timer.c: In function 'timer':
timer.c:189: warning: format not a string literal and no format arguments
timer.c:258: warning: format not a string literal and no format arguments
atm.c: In function 'atmUnload':
atm.c:99: warning: array subscript is above array bounds
atm.c: In function 'atmLoad':
atm.c:65: warning: array subscript is above array bounds
codec.c: In function 'codsp_write_pop_int':
codec.c:678: warning: array subscript is above array bounds
codec.c: In function 'codsp_write_cop_short':
codec.c:585: warning: array subscript is above array bounds
codec.c: In function 'codsp_write_sop_int':
codec.c:512: warning: array subscript is above array bounds

Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
2011-05-12 23:17:52 +02:00
Michael Jones
2cc195e0a5 Remove remnants of obsolete CONFIG_SYS_GBL_DATA_SIZE comments
commit 25ddd1fb0a left remnants of
many comments about CONFIG_SYS_GBL_DATA_SIZE.

Signed-off-by: Michael Jones <michael.jones@matrix-vision.de>
2011-05-12 23:04:55 +02:00
Dirk Eibach
31c1bdd93d hwmon: Extend lm63.c to support LM64
This patch adds support for the National LM64 temperature
sensor with integrated fan control to lm63.c.
Main difference between LM63 and LM64 is 16°C offset in sensor
readings.

Signed-off-by: Dirk Eibach <eibach@gdsys.de>
2011-05-12 23:01:34 +02:00
François Revol
bbc6353c74 Fix building tools alone with host compiler
- don't include config.h when building with host cc,
- HOSTCFLAGS was defined with the wrong name, so wasn't used,
- make sure make finds sources outside of tools/.

Signed-off-by: Franois Revol <revol@free.fr>
2011-05-12 22:46:42 +02:00
Michal Simek
95efa79d08 net: xilinx emaclite: Fix return values
Fix return values for initialize/init/recv/send functions

Signed-off-by: Michal Simek <monstr@monstr.eu>
2011-05-12 22:29:28 +02:00
Che-liang Chiou
0da43893dd Fix variable flavor in examples/standalone/Makefile
GNU Makefile have two flavors of variables, recursively expanded that is
defined by using '=', and simply expanded that is defined by using ':='.

The bug is caused by using recursively expanded flavor for BIN and SREC.
As you can see below, they are prepended by $(obj) twice.

We can reproduce this bug with a simplified version of this Makefile:
$ cat >Makefile <<\EOF
obj := /path/to/obj/
ELF := hello_world

BIN_rec = $(addsuffix .bin,$(ELF))      # recursively expanded
BIN_sim := $(addsuffix .bin,$(ELF))     # simply expanded

ELF := $(addprefix $(obj),$(ELF))
BIN_rec := $(addprefix $(obj),$(BIN_rec))
BIN_sim := $(addprefix $(obj),$(BIN_sim))

show:
	@echo BIN_rec=$(BIN_rec)
	@echo BIN_sim=$(BIN_sim)

.PHONY: show
EOF
$ make show
BIN_rec=/path/to/obj//path/to/obj/hello_world.bin
BIN_sim=/path/to/obj/hello_world.bin

Signed-off-by: Che-Liang Chiou <clchiou@chromium.org>
2011-05-12 22:25:16 +02:00
Luca Ceresoli
ccb9ebefbe net/net.c: cosmetic: do not use assignment in if condition
This removes the following checkpatch issue:
 - ERROR: do not use assignment in if condition

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
2011-05-12 22:07:41 +02:00
Luca Ceresoli
c819abeef7 net/net.c: cosmetic: fix indentation
This removes the following checkpatch issues:
 - ERROR: switch and case should be at the same indent
 - WARNING: suspect code indent for conditional statements
 - WARNING: labels should not be indented

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
2011-05-12 22:07:31 +02:00
Luca Ceresoli
92895de978 net/net.c: cosmetic: parentheses not required for return
This removes the following checkpatch issue:
 - ERROR: return is not a function, parentheses are not required

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
2011-05-12 22:06:04 +02:00
Luca Ceresoli
6b147d1139 net/net.c: cosmetic: fix pointer syntax issues
This removes the following checkpatch issues:
 - ERROR: "foo * bar" should be "foo *bar"
 - ERROR: "(foo*)" should be "(foo *)"

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
2011-05-12 22:03:47 +02:00
Luca Ceresoli
d3c65b015a net/net.c: cosmetic: fix brace issues
This removes the following checkpatch issues:
 - WARNING: braces {} are not necessary for single statement blocks
 - WARNING: braces {} are not necessary for any arm of this statement

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
2011-05-12 22:01:34 +02:00
Luca Ceresoli
4f63acd062 net/net.c: cosmetic: fix whitespace issues
This removes the following checkpatch issues:
 - ERROR: space prohibited after that open parenthesis '('
 - ERROR: space prohibited before that close parenthesis ')'
 - ERROR: space prohibited after that open square bracket '['
 - ERROR: space prohibited after that '&' (ctx:WxW)
 - ERROR: spaces required around that '=' (ctx:VxW)
 - ERROR: space required before the open parenthesis '('
 - ERROR: space required after that ',' (ctx:VxV)
 - ERROR: need consistent spacing around '+' (ctx:WxV)
 - WARNING: unnecessary whitespace before a quoted newline
 - WARNING: please, no spaces at the start of a line
 - WARNING: space prohibited between function name and open
   parenthesis '('

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
Cc: Mike Frysinger <vapier@gentoo.org>
2011-05-12 22:01:05 +02:00
Luca Ceresoli
c586ce6e01 net/net.c: cosmetic: variable initializations
This removes the following checkpatch errors:
 - ERROR: do not initialise globals to 0 or NULL
 - ERROR: spaces required around that '=' (ctx:VxV)
 - ERROR: that open brace { should be on the previous line

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
Cc: Mike Frysinger <vapier@gentoo.org>
2011-05-12 21:49:56 +02:00
Luca Ceresoli
3e38e429ff net/net.c: cosmetic: fix lines over 80 characters
This removes the following checkpatch warning:
 - WARNING: line over 80 characters

There are three such warnings left.

The first is hard to fix with cosmetic-only changes without compromising code
readability, so I'm leaving it as it is for now:
  WARNING: line over 80 characters
  #1537: FILE: net.c:1537:
  + [4 tabs] memcpy(((Ethernet_t *)NetArpWaitTxPacket)->et_dest, ...

The other two cannot be fixed without splitting string literals, so it is
preferred to keep them longer than 80 characters.

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
Cc: Mike Frysinger <vapier@gentoo.org>
2011-05-12 21:49:49 +02:00
Heiko Schocher
a7fd0d9ffd lib, vsprintf: introduce strict_strtoul
as checkpatch proposes to use strict_strtoul instead of
simple_strtoul, introduce it.

Ported this function from Linux 2.6.38 commit ID:
521cb40b0c44418a4fd36dc633f575813d59a43d

Signed-off-by: Heiko Schocher <hs@denx.de>
cc: Wolfgang Denk <wd@denx.de>
cc: Detlev Zundel <dzu@denx.de>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
2011-05-12 21:07:06 +02:00
Wolfgang Denk
f0c0b3a9e6 Fix incorrect use of getenv() before relocation
A large number of boards incorrectly used getenv() in their board init
code running before relocation.  In some cases this caused U-Boot to
hang when certain environment variables grew too long.
Fix the code to use getenv_r().

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: The LEOX team <team@leox.org>
Cc: Michael Schwingen <michael@schwingen.org>
Cc: Georg Schardt <schardt@team-ctech.de>
Cc: Werner Pfister <Pfister_Werner@intercontrol.de>
Cc: Dirk Eibach <eibach@gdsys.de>
Cc: Peter De Schrijver <p2@mind.be>
Cc: John Zhan <zhanz@sinovee.com>
Cc: Rishi Bhattacharya <rishi@ti.com>
Cc: Peter Tyser <ptyser@xes-inc.com>
2011-05-12 19:48:42 +02:00
Wolfgang Denk
a02a884b95 cmd_nvedit.c: make error message more helpful
When calling getenv_f() with a too small buffer, it would print an
error message like this:

	env_buf too small [32]

This is not really helpful as it does not give any indication which of
the calls might have failed.  Change this into:

	env_buf [32 bytes] too small for value of "hwconfig"

so we know at least which variable caused the overflow; this usually
allows to quickly find the related code as well.

Signed-off-by: Wolfgang Denk <wd@denx.de>
2011-05-12 19:47:14 +02:00
Luca Ceresoli
03eb129f8a NET: pass source IP address to packet handlers
This is needed for the upcoming TFTP server implementation.

This also simplifies PingHandler() and fixes rxhand_f documentation.

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Acked-by: Detlev Zundel <dzu@denx.de>
2011-05-12 19:38:19 +02:00
Luca Ceresoli
8eccee7ae7 README: remove spurious line
Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Acked-by: Detlev Zundel <dzu@denx.de>
2011-05-12 19:37:10 +02:00
Wolfgang Denk
9e2b517637 MPC8260: Fix compile problems with "hymod" board
Commit 9d8fbd1 "powerpc, 8xx: Fixup all 8xx u-boot.lds scripts" broke
building of the MPC8260 based "hymod" board.  Fix this.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Murray Jensen <Murray.Jensen@csiro.au>
Cc: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
2011-05-12 19:31:05 +02:00
Mike Frysinger
f18185ab60 zlib: fix DEBUG build
The previous commit imported a little too much from upstream.  We need
to disable stdio.h when using U-Boot.

Reported-by: Wolfgang Denk <wd@denx.de>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-05-12 19:30:29 +02:00
Wolfgang Denk
0e0c0892a1 Merge branch 'master' of git://git.denx.de/u-boot-ppc4xx 2011-05-12 19:27:42 +02:00
Wolfgang Denk
162eee4106 Merge branch 'master' of git://git.denx.de/u-boot-arm 2011-05-12 19:26:45 +02:00
Simon Guinot
8b6bbe104f netconsole: remove `serverip' check
Netconsole use the environment variable `ncip' to configure the
destination IP. `serverip' don't need to be defined.

Signed-off-by: Simon Guinot <sguinot@lacie.com>
2011-05-12 19:11:51 +02:00
John Rigby
910f1ae3eb Serial: p1011: new vendor init options
Two new options:

CONFIG_PL011_SERIAL_RLCR

Some vendor versions of PL011 serial ports (e.g. ST-Ericsson U8500)
have separate receive and transmit line control registers.  Set
this variable to initialize the extra register.

CONFIG_PL011_SERIAL_FLUSH_ON_INIT

On some platforms (e.g. U8500) U-Boot is loaded by a second stage
boot loader that has already initialized the UART.  Define this
variable to flush the UART at init time.
empty fifo on init

Signed-off-by: John Rigby <john.rigby@linaro.org>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
2011-05-12 19:09:07 +02:00
Steven A. Falco
644362c40a PPC405EX CHIP_21 erratum
APM errata CHIP_21 for the 405EX/EXr (from the rev 1.09 document dated
4/27/11) states that rev D processors may wake up with the wrong feature
set.  This patch implements the APM-proposed workaround.

To enable this patch for your board, add the appropriate define for your
CPU to your board header file.  See kilauea.h for more information.  The
following variants are supported:

#define CONFIG_SYS_4xx_CHIP_21_405EX_NO_SECURITY
#define CONFIG_SYS_4xx_CHIP_21_405EX_SECURITY
#define CONFIG_SYS_4xx_CHIP_21_405EXr_NO_SECURITY
#define CONFIG_SYS_4xx_CHIP_21_405EXr_SECURITY

Please note that if you select the wrong define, your board will not
boot, and JTAG will be required to recover.

Tested on custom boards using:

CONFIG_SYS_4xx_CHIP_21_405EX_NO_SECURITY  <sfalco@harris.com>
CONFIG_SYS_4xx_CHIP_21_405EX_SECURITY     <eibach@gdsys.de>

Signed-off-by: Steve Falco <sfalco@harris.com>
Acked-by: Dirk Eibach <eibach@gdsys.de>
Signed-off-by: Stefan Roese <sr@denx.de>
2011-05-12 16:10:51 +02:00