Commit Graph

5370 Commits

Author SHA1 Message Date
Hugo Villeneuve c7f879ec2b 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>
2008-06-28 22:54:21 +02:00
Haavard Skinnemoen 341188b9cc MMC: Consolidate MMC/SD command definitions
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.

Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
2008-06-28 22:40:15 +02:00
Kyungmin Park fa60edfc4c Use better Ethernet timings for apollon board
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
2008-06-28 22:28:15 +02:00
Andy Fleming 41c5eaa725 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>
2008-06-28 22:23:13 +02:00
Andy Fleming 7570a9941f 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>
2008-06-28 22:22:05 +02:00
Andy Fleming 63796c4e61 Add lmb_free
lmb_free allows us to unreserve some memory so we can use lmb_alloc_base or
lmb_reserve to temporarily reserve some memory.

Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-06-28 22:21:38 +02:00
Andy Fleming 4b03ac8b51 Add ALIGN() macro
ALIGN() returns the smallest aligned value greater than the passed
in address or size.  Taken from Linux.

Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-06-28 22:20:29 +02:00
Haavard Skinnemoen 28eab0d773 Conditionally add -fno-stack-protector to CFLAGS
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.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2008-06-26 19:46:02 +02:00
Jean-Christophe PLAGNIOL-VILLARD dfd3be881c pcmcia/ti_pci1410a: Move compile condition to the Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-06-26 17:04:25 +02:00
Jean-Christophe PLAGNIOL-VILLARD 72d5d5f7b5 pxa_pcmcia: Move compile condition to the Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-06-26 17:03:41 +02:00
Jean-Christophe PLAGNIOL-VILLARD c9eff32881 marabun_pcmcia: Move compile condition to the Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-06-26 17:01:41 +02:00
Wolfgang Denk 914f58c576 Merge branch 'master' of git://www.denx.de/git/u-boot-cfi-flash 2008-06-19 22:58:36 +02:00
Wolfgang Denk 8115c6f9eb Merge branch 'master' of git://www.denx.de/git/u-boot-ppc4xx 2008-06-19 22:57:58 +02:00
Wolfgang Denk 51a6ca2c3a Merge branch 'master' of git://www.denx.de/git/u-boot-nand-flash 2008-06-19 22:57:06 +02:00
Wolfgang Grandegger b4fe1a7109 MPC8360ERDK: adapt NAND interface for the re-written FSL NAND UPM driver
This patch is based on the following patch sent a few minutes ago:
"NAND FSL UPM: driver re-write using the hwcontrol callback"
It is untested, of course. Anton, could you please give it a try.

Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
Acked-by: Anton Vorontsov <avorontsov@ru.mvista.com>
2008-06-19 22:54:45 +02:00
Anatolij Gustschin 96026d42fa Fix 4xx build issue
Building for 4xx doesn't work since commit 4dbdb768:

In file included from 4xx_pcie.c:28:
include/asm/processor.h:971: error: expected ')' before 'ver'
make[1]: *** [4xx_pcie.o] Error 1

This patch fixes the problem.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Stefan Roese <sr@denx.de>
Acked-by: Kumar Gala <galak@kernel.crashing.org>
2008-06-19 22:48:45 +02:00
Stefan Roese fb8c061ea0 cfi-flash: Fix problem in flash_toggle(), busy was not detected reliably
This patch simplifies flash_toggle() (AMD commandset), which is used to
detect if a FLASH device is still busy with erase/program operations. On
800MHz Canyonlands/Glacier boards (460EX/GT) the current implementation
did not detect the busy state reliably, resulting in non erased sectors
etc. This patch now simplifies this function by "just" comparing the
complete data-word instead of ANDing it with the command-word (0x40)
before the compatison. It is done the same way in the Linux implementation
chip_ready() in cfi_cmdset_0002.c.

Signed-off-by: Stefan Roese <sr@denx.de>
2008-06-19 15:08:17 +02:00
Philip Balister 9e4006bca3 NAND: Add missing declaration to non-redundant saveenv().
Signed-off-by: Scott Wood <scottwood@freescale.com>
2008-06-16 12:25:58 -05:00
Wolfgang Grandegger 2cdb7f50ac MPC8360ERDK: adapt NAND interface for the re-written FSL NAND UPM driver
Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
Acked-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: Scott Wood <scottwood@freescale.com>
2008-06-12 11:24:27 -05:00
Stefan Roese 212ed90615 ppc4xx: Canyonlands: Disable the RTC M41T62 square wave output
This patch disables the square wave output of the M41T62 RTC used on
Canyonlands & Glacier. Here the explanation:

The serial real-time clock part used in the design is an
STMicro M41T62. This part has a full-time 32KHz square wave
output that is connected to the TmrClk input to the
processor. The default state for this square wave output is
enabled so the output runs continuously when the board is
powered normally and also from the battery. The TmrClk input
to the processor goes to ground when the power is removed
from the board/processor, and therefore the running square
wave output is driving ground which drains the battery quickly.

Signed-off-by: Stefan Roese <sr@denx.de>
2008-06-12 15:50:31 +02:00
Andy Fleming a94f22f08f Fix build issue with string.h and linux/string.h
This commit:
commit 338cc03846
Author: Wolfgang Denk <wd@denx.de>
Date:   Fri Jun 6 14:28:14 2008 +0200

    tools/mkimage: fix compiler warnings on some systems.

Broke building on some systems, because the host's string.h was interfering
with u-boot's linux/string.h.  It doesn't look like we need the u-boot one if
we're building for the host, so now we only include when building inside
u-boot.

Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-06-12 08:51:35 +02:00
Becky Bruce 9973e3c614 Change initdram() return type to phys_size_t
This patch changes the return type of initdram() from long int to phys_size_t.
This is required for a couple of reasons: long int limits the amount of dram
to 2GB, and u-boot in general is moving over to phys_size_t to represent the
size of physical memory.  phys_size_t is defined as an unsigned long on almost
all current platforms.

This patch *only* changes the return type of the initdram function (in
include/common.h, as well as in each board's implementation of initdram).  It
does not actually modify the code inside the function on any of the platforms;
platforms which wish to support more than 2GB of DRAM will need to modify
their initdram() function code.

Build tested with MAKEALL for ppc, arm, mips, mips-el. Booted on powerpc
MPC8641HPCN.

Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
2008-06-12 08:50:18 +02:00
Becky Bruce 391fd93ab2 Change lmb to use phys_size_t/phys_addr_t
This updates the lmb code to use phys_size_t
and phys_addr_t instead of unsigned long.  Other code
which interacts with this code, like getenv_bootm_size()
is also updated.

Booted on MPC8641HPCN, build-tested ppc, arm, mips.

Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
2008-06-12 00:56:39 +02:00
Becky Bruce 61b09fc295 Change print_size to take phys_size_t
Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
2008-06-12 00:55:43 +02:00
Becky Bruce b57ca3e128 Change bd/gd memsize/ram_size to be phys_size_t.
Currently, both are defined as an unsigned long, but
should be phys_size_t. This should result in no real change,
since phys_size_t is currently an unsigned long for all the
default configs.  Also add print_lnum to cmd_bdinfo to deal
with the potentially wider memsize.

Signed-off-by: Becky Bruce <becky.bruce@freescale.com>
2008-06-12 00:54:53 +02:00
Wolfgang Denk b77cddc7b5 Merge branch 'master' of git://www.denx.de/git/u-boot-sh 2008-06-11 22:54:47 +02:00
Wolfgang Denk 1a5017601f Merge branch 'master' of git://www.denx.de/git/u-boot-mips 2008-06-11 22:48:09 +02:00
Wolfgang Denk cdeb62e20d Merge branch 'master' of git://www.denx.de/git/u-boot-fdt 2008-06-11 22:30:47 +02:00
Wolfgang Denk 1859e42fbf Merge branch 'master' of git://www.denx.de/git/u-boot-cfi-flash 2008-06-11 22:24:46 +02:00
Wolfgang Denk 776488eb88 Merge branch 'master' of git://www.denx.de/git/u-boot-nand-flash 2008-06-11 22:23:09 +02:00
Wolfgang Denk 32d4e38eeb Merge branch 'master' of git://www.denx.de/git/u-boot-net 2008-06-11 22:17:42 +02:00
Wolfgang Denk 1730edf76c Merge branch 'master' of git://www.denx.de/git/u-boot-ppc4xx 2008-06-11 22:13:07 +02:00
Wolfgang Denk 5ea67393b8 Merge branch 'master' of git://www.denx.de/git/u-boot-mpc85xx
Conflicts:

	include/asm-ppc/fsl_lbc.h

Signed-off-by: Wolfgang Denk <wd@denx.de>
2008-06-11 21:33:16 +02:00
Wolfgang Denk 2395db4886 Merge branch 'master' of git://www.denx.de/git/u-boot-mpc83xx 2008-06-11 21:27:31 +02:00
Wolfgang Denk 3c6e979a94 Merge branch 'master' of git://www.denx.de/git/u-boot-mpc86xx 2008-06-11 21:23:16 +02:00
Kumar Gala ba04f70109 FSL LAW: Add new interface to use the last free LAW
LAWs have the concept of priority so its useful to be able to allocate
the lowest (highest number) priority.  We will end up using this with the
new DDR code.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-06-11 01:53:09 -05:00
Kumar Gala 859a86a25c 85xx/86xx: Move to dynamic mgmt of LAWs
With the new LAW interface (set_next_law) we can move to letting the
system allocate which LAWs are used for what purpose.  This makes life
a bit easier going forward with the new DDR code.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: Andy Fleming <afleming@freescale.com>
Acked-by: Jon Loeliger <jdl@freescale.com>
Acked-by: Becky Bruce <becky.bruce@freescale.com>
2008-06-11 01:52:23 -05:00
Kumar Gala f060054dad FSL LAW: Keep track of LAW allocations
Make it so we keep track of which LAWs have allocated and provide
a function (set_next_law) which can allocate a LAW for us if one is
free.

In the future we will move to doing more "dynamic" LAW allocation
since the majority of users dont really care about what LAW number
they are at.

Also, add CONFIG_MPC8540 or CONFIG_MPC8560 to those boards which needed them

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-06-11 01:50:53 -05:00
Kumar Gala ddde74a159 85xx: remove dummy board_early_init_f
A number of board ports have empty version of board_early_init_f
for no reason since we control its via CONFIG_BOARD_EARLY_INIT_F.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-06-11 00:36:02 -05:00
Kumar Gala 81e56e9af0 MPC8544DS: Update config.h
* Enable flash progress
* remove CLEAR_LAW0 since we dont really use it

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-06-11 00:35:57 -05:00
Kumar Gala 978e81604c 85xx: Remove unused and unconfigured memory test code.
Remove unused and unconfigured DDR test code from FSL 85xx boards.
Besides, other common code exists.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-06-11 00:35:52 -05:00
Sergei Poselenov a23cddde1a Socrates: Added FPGA base address update in FDT.
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:30:34 -05:00
Sergei Poselenov fd51b0e0e6 Socrates: NAND support added. Changed the U-Boot base address and
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:30:29 -05:00
Sergei Poselenov 248ae5cfc8 NAND: Added support for 128-bit OOB, adapted
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:30:22 -05:00
Sergei Poselenov 31ca020861 Socrates: added missed file with UPMA configuration data.
Signed-of-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:30:14 -05:00
Sergei Poselenov 59abd15b43 Socrates: Added FPGA mapping. LAWs and TLBs cleanup.
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:30:09 -05:00
Sergei Poselenov 740280e68c Added the upmconfig() function for 85xx.
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
Signed-off-by: Andy Fleming <afleming@freescale.com>
2008-06-11 00:29:29 -05:00
Sergei Poselenov d39e68514f Socrates: config file cleanup.
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
2008-06-11 00:17:08 -05:00
Wolfgang Grandegger e8cc3f04b1 TQM85xx: Change memory map to support Flash memory > 128 MiB
Some TQM85xx boards could be equipped with up to 1 GiB (NOR) Flash
memory. The current memory map only supports up to 128 MiB Flash.
This patch adds the configuration option CONFIG_TQM_BIGFLASH. If
set, up to 1 GiB flash is supported. To achieve this, the memory
map has to be adjusted in great parts (for example the CCSRBAR is
moved from 0xE0000000 to 0xA0000000).

If you want to boot Linux with CONFIG_TQM_BIGFLASH set, the new
memory map also has to be considered in the kernel (changed
CCSRBAR address, changed PCI IO base address, ...). Please use
an appropriate Flat Device Tree blob (tqm8548.dtb).

Signed-off-by: Martin Krause <martin.krause@tqs.de>
Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
2008-06-11 00:05:14 -05:00
Wolfgang Grandegger 1c2deff22c TQM85xx: NAND support via local bus UPMB
This patch adds support for NAND FLASH on the TQM8548. It is disabled by
default and can be enabled for the TQM8548 modules. It is now based on
the re-written FSL NAND UPM driver. A patch has been posted earlier today
with the subject:

"NAND FSL UPM: driver re-write using the hwcontrol callback"

Note that the R/B pin is not supported by that module requiring to use
the specified maximum delay time.

Note: With NAND support enabled the size of the U-Boot image exceeds
256 KB and TEXT_BASE must therefore be set to 0xfff80000 in config.mk,
doubling the image size :-(.

Signed-off-by: Thomas Waehner <thomas.waehner@tqs.de>
Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
2008-06-11 00:05:08 -05:00