Kumar Gala [Mon, 7 Jul 2008 14:39:06 +0000 (09:39 -0500)]
Fix compiler warnings
gcc-4.3.x generates the following:
bootm.c: In function 'do_bootm_linux':
bootm.c:208: warning: cast from pointer to integer of different size
bootm.c:215: warning: cast from pointer to integer of different size
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Harald Welte [Mon, 7 Jul 2008 07:40:39 +0000 (15:40 +0800)]
Remove code duplication for setting the default environment
common/env_common.c (default_env): new function that resets the environment to
the default value
common/env_common.c (env_relocate): use default_env instead of own copy
common/env_nand.c (env_relocate_spec): use default_env instead of own copy
include/environment.h: added default_env prototype
Signed-off-by: Werner Almesberger <werner@openmoko.org> Signed-off-by: Harald Welte <laforge@openmoko.org>
avr32: Use CONFIG_ATMEL_MCI to select the atmel_mci driver
After we move the atmel_mci driver into drivers/mmc, we can't select
it with CONFIG_MMC anymore. Introduce a new symbol specifically for
this driver so that there's no ambiguity.
Andrew Klossner [Mon, 7 Jul 2008 13:41:14 +0000 (06:41 -0700)]
Fix printf errors.
The compiler will help find mismatches between printf formats and
arguments if you let it. This patch adds the necessary attributes to
declarations in include/common.h, then begins to correct the resulting
compiler warnings. Some of these were bugs, e.g., "$d" instead of
"%d" and incorrect arguments. Others were just annoying, like
int-long mismatches on a system where both are 32 bits. It's worth
fixing the annoying errors to catch the real ones.
Signed-off-by: Andrew Klossner <andrew@cesa.opbu.xerox.com>
Stefan Roese [Tue, 8 Jul 2008 10:57:14 +0000 (12:57 +0200)]
jedec_flash: Fix AM29DL800BB device ID
As pointed out by Jerry Hicks, this patch corrects the device ID of
the Spansion AM29DL800BB NOR device. Verified against latest Spansion
datasheet (rev C4 from Dezember 2006).
By Cleanup out-or-tree building for some boards (.depend)
(commit:c8a3b109f07f02342d097b30908965f7261d9f15)
because filse ware changed, some SH-boards have compile error.
I revised this problem.
Ben Warren [Tue, 24 Jun 2008 05:57:27 +0000 (22:57 -0700)]
Add mechanisms for CPU and board-specific Ethernet initialization
This patch is the first step in cleaning up net/eth.c, by moving Ethernet
initialization to CPU or board-specific code. Initial implementation is
only on the Freescale TSEC controller, but others will be added soon.
Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Patrice Vilchez [Tue, 27 May 2008 09:15:29 +0000 (11:15 +0200)]
[AT91SAM9] Fix NAND FLASH timings
Fix NAND FLASH timings for at91sam9x evaluation kits.
New timings are based on application note
"NAND Flash Support on AT91SAM9 Microcontrollers" available at
http://atmel.com/dyn/resources/prod_documents/doc6255.pdf
Stelian Pop [Wed, 21 May 2008 22:15:40 +0000 (00:15 +0200)]
Fix boot from NOR due to incorrect reset delay.
AT91 RSTC registers are battery-backuped, so their values
are not reset across power cycles. One of those registers,
the AT91_RSTC_MR register, is being modified by U-Boot, in
the ethernet initialisation routine, to generate a 500ms
user reset.
Unfortunately, this value is not being restored afterwards,
causing subsequent resets to also last for 500ms.
This long reset sequence causes problems (at least) in the
boot sequence from NOR: by the time the CPU tries to load
a program from the NOR flash, the latter is still in reset
and not yet available.
Additionaly, this patch fixes a bug in the original code which
caused the reset delay to last for 2s instead of 500ms.
Signed-off-by: Stelian Pop <stelian@popies.net> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Steven A. Falco [Thu, 12 Jun 2008 17:24:42 +0000 (13:24 -0400)]
cmd_nvedit.c: clean up syntax highlighting
My text-editor (vim) has a bit of trouble syntax-highlighting the
cmd_nvedit.c file, because it apparently does not parse C
ifdef/else/endif. The following patch does not change the behavior of
the code at all, but does allow the editor to properly
syntax-highlight the file.
Juergen Kilb [Sun, 8 Jun 2008 15:59:53 +0000 (17:59 +0200)]
i.MX31: fixed CTRL-C detection
The Register URXD contains status information in bits [15..8].
With status bit 15 set, CTRL-C was reported as 0x8003 instead
of 0x03. Therefore CTRL-C was not detected.
To solve this, bits [15..8] were masked out now.
Signed-off-by: Juergen Kilb <J.Kilb@gmx.de> Acked-by: Felix Radensky <felix@embedded-sol.com>
Global FIT image operations like format check cannot be performed on
a first sector data, defer them to the point when whole FIT image was
uploaded to a system RAM.
Signed-off-by: Marian Balakowicz <m8@semihalf.com>
Partial ('cmd_nand' case) Acked-by: Grant Erickson <gerickson@nuovations.com>
NAND and DOC bits Acked-by: Scott Wood <scottwood@freescale.com>
Dave Liu [Tue, 3 Jun 2008 09:38:19 +0000 (17:38 +0800)]
sata: wait for device updating signature to host
The driver need wait for the device updating signature to host.
If we don't wait for it, the driver can not detect the device(disk)
when the system powers up.
Stefan Roese [Sat, 28 Jun 2008 12:56:17 +0000 (14:56 +0200)]
ppc4xx: Fix 460EX errata with CPU lockup upon high AHB traffic
This patch implements a fix provided by AMCC so that the lockup upon
simultanious traffic on AHB USB OTG, USB 2.0 and SATA doesn't occur
anymore:
Set SDR0_AHB_CFG[A2P_INCR4] (bit 24) and clear SDR0_AHB_CFG[A2P_PROT2]
(bit 25) for a new 460EX errata regarding concurrent use of AHB USB OTG,
USB 2.0 host and SATA.
This errata is not officially available yet. I'll update the comment
to add the errata number later.
Hugo Villeneuve [Wed, 21 May 2008 17:58:41 +0000 (13:58 -0400)]
ARM: Add support for Lyrtech SFF-SDR board (ARM926EJS)
This patch adds support for the Lyrtech SFF-SDR board,
based on the TI DaVinci architecture (ARM926EJS).
Signed-off-by: Hugo Villeneuve <hugo.villeneuve@lyrtech.com> Signed-off-by: Philip Balister <philip@balister.org> Signed-off-by: Wolfgang Denk <wd@denx.de>
This moves the MMC and SD Card command definitions from
include/asm/arch/mmc.h into include/mmc.h. These definitions are
given by the MMC and SD Card standards, not by any particular
architecture.
There's a lot more room for consolidation in the MMC drivers which
I'm hoping to get done eventually, but this patch is a start.
Compile-tested for all avr32 boards as well as lpc2292sodimm and
lubbock. This should cover all three mmc drivers in the tree.
Andy Fleming [Mon, 16 Jun 2008 18:58:56 +0000 (13:58 -0500)]
Resize device tree to allow space for board changes and the chosen node
Current code requires that a compiled device tree have space added to the end to
leave room for extra nodes added by board code (and the chosen node). This
requires that device tree creators anticipate how much space U-Boot will add to
the tree, which is absurd. Ideally, the code would resize and/or relocate the
tree when it needed more space, but this would require a systemic change to the
fdt code, which is non-trivial. Instead, we resize the tree inside
boot_relocate_fdt, reserving either the remainder of the bootmap (in the case
where the fdt is inside the bootmap), or adding CFG_FDT_PAD bytes to the size.
Signed-off-by: Andy Fleming <afleming@freescale.com>
Andy Fleming [Mon, 16 Jun 2008 18:58:55 +0000 (13:58 -0500)]
Fix an underflow bug in __lmb_alloc_base
__lmb_alloc_base can underflow if it fails to find free space. This was fixed
in linux with commit d9024df02ffe74d723d97d552f86de3b34beb8cc. This patch
merely updates __lmb_alloc_base to resemble the current version in Linux.
Signed-off-by: Andy Fleming <afleming@freescale.com>
When compile-testing on powerpc, I get errors like this:
net/nfs.c:422: undefined reference to `__stack_chk_fail_local'
This seems to be because -fstack-protector is on by default, so
let's explicitly disable it on all architectures that support the
option.
The Ubuntu toolchain is affected by this problem, and according to
Mike Frysinger, Gentoo has been running with SSP enabled for years.
More and more distros are turning SSP on by default, so this problem
is likely to get worse in the future.
Also, powerpc just happens to be one of the arches I do
compile-testing on. There may be other arches affected by this too.
Kim Phillips [Tue, 17 Jun 2008 22:45:27 +0000 (17:45 -0500)]
mpc83xx: move CPU_TYPE_ENTRY over to processor.h
to avoid this:
cpu.c:47:1: warning: "CPU_TYPE_ENTRY" redefined
In file included from cpu.c:33:
/home/kim/git/u-boot/include/asm/processor.h:982:1: warning: this is the location of the previous definition
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>