]> git.karo-electronics.de Git - karo-tx-uboot.git/log
karo-tx-uboot.git
11 years agonet: eth_write_hwaddr: Return error for invalid MACs
Benoît Thébaudeau [Fri, 10 Aug 2012 07:56:21 +0000 (07:56 +0000)]
net: eth_write_hwaddr: Return error for invalid MACs

If dev->enetaddr was supposed to be set with dev->write_hwaddr() but the MAC
address was not valid, return an error.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
11 years agoSPL: NAND: Move arch/arm/cpu/armv7/omap-common/spl_nand.c to common/spl
Tom Rini [Tue, 14 Aug 2012 21:33:02 +0000 (14:33 -0700)]
SPL: NAND: Move arch/arm/cpu/armv7/omap-common/spl_nand.c to common/spl

We move the spl_nand_load_image function to common/spl.  This will allow
for easier integration of SPL-boots-Linux code on other arches.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoSPL: Use image_get_xxx() functions to access header values
Stefan Roese [Mon, 27 Aug 2012 10:50:57 +0000 (12:50 +0200)]
SPL: Use image_get_xxx() functions to access header values

Signed-off-by: Stefan Roese <sr@denx.de>
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoSPL: do not use fix value for u-boot size
Stefano Babic [Thu, 23 Aug 2012 10:46:16 +0000 (12:46 +0200)]
SPL: do not use fix value for u-boot size

If an u-boot image is not found, SPL thinks to load a bare
u-boot.bin image with a maximum size of 200KB.
Use CONFIG_SYS_MONITOR_LEN instead.

Signed-off-by: Stefan Roese <stefan.roese@gmail.com>
Signed-off-by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoSPL: Create arch/arm/lib/spl.c for board_init_f and jump_to_image_linux
Tom Rini [Wed, 22 Aug 2012 22:31:05 +0000 (15:31 -0700)]
SPL: Create arch/arm/lib/spl.c for board_init_f and jump_to_image_linux

In SPL (CONFIG_SPL_FRAMEWORK) board_init_f must setup the stack pointer,
clear the BSS and call board_init_r.  We mark this as weak as some
platforms may need to perform additional initalization at this point.
We provide a gd that we know will be in a usable location, once the BSS
has been cleared to help with this as well.  Finally, we no longer call
relocate_code so remove that from the armv7 version.

Next, both board_init_f and jump_to_image_linux are going to be
inherently arch-specific, so move these versions to arch/arm/lib/spl.c

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoSPL: Move the omap SPL framework to common/spl
Tom Rini [Mon, 13 Aug 2012 19:03:19 +0000 (12:03 -0700)]
SPL: Move the omap SPL framework to common/spl

Add a new flag, CONFIG_SPL_FRAMEWORK to opt into the common/spl SPL
framework, enable on all of the previously using boards.  We move the
spl_ymodem.c portion to common/ and spl_mmc.c to drivers/mmc/.  We leave
the NAND one in-place as we plan to replace it later in this series.

We use common/spl to avoid linker problems with respect to merging
constant strings in objects.   Otherwise all strings in common/ will be
linked in and kept which grows SPL in size too much.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Move gpmc_init() to spl_board_init()
Tom Rini [Tue, 14 Aug 2012 19:26:08 +0000 (12:26 -0700)]
ARM: SPL: Move gpmc_init() to spl_board_init()

This is an OMAP/related-specific function, move calling it to
spl_board_init() and turn on CONFIG_SPL_BOARD_INIT on the boards that
enabled NAND and didn't enable this already.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Start hooking in the current SPI SPL support
Tom Rini [Tue, 14 Aug 2012 19:25:23 +0000 (12:25 -0700)]
ARM: SPL: Start hooking in the current SPI SPL support

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Clean up spl.c / spl_nand.c slightly
Tom Rini [Tue, 14 Aug 2012 19:06:43 +0000 (12:06 -0700)]
ARM: SPL: Clean up spl.c / spl_nand.c slightly

- Remove includes we don't need
- Switch some printf statements to puts
- Convert some printf statements to debug, introduce new puts statements
  - In most cases saying just "No mkimage signature, assuming
    u-boot.bin" or similar is sufficient.  This also means the non-DEBUG
    case doesn't need printf, in the core of SPL.
  - The other case here is that PLAIN_VERSION provided what we wanted
    already, so just use it.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Make spl_mmc.c more generic
Tom Rini [Tue, 14 Aug 2012 17:25:15 +0000 (10:25 -0700)]
ARM: SPL: Make spl_mmc.c more generic

Move the default omap/related-centric board_mmc_init to
arch/arm/cpu/armv7/omap-common/boot-common.c and move the type defines
to <asm/spl.h>.  Also use mmc->read_bl_len rather than MMCSD_SECTOR_SIZE

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Add <asm/spl.h> and <asm/arch/spl.h>
Tom Rini [Tue, 14 Aug 2012 15:50:58 +0000 (08:50 -0700)]
ARM: SPL: Add <asm/spl.h> and <asm/arch/spl.h>

Move the SPL prototypes from <asm/omap_common.h> into <asm/spl.h> and
add <asm/arch/spl.h> for arch specific portions of CONFIG_SPL_FRAMEWORK.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Only call mem_malloc_init if configured
Tom Rini [Mon, 13 Aug 2012 21:13:07 +0000 (14:13 -0700)]
ARM: SPL: Only call mem_malloc_init if configured

We can only attempt to setup a malloc pool if
CONFIG_SYS_SPL_MALLOC_START is defined, and not all boards require it.
Make the call depend on the define.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Remove NAND_MODE_HW_ECC from spl_nand.c
Tom Rini [Mon, 13 Aug 2012 21:11:06 +0000 (14:11 -0700)]
ARM: SPL: Remove NAND_MODE_HW_ECC from spl_nand.c

This detection code doesn't (and can't) do anything currently, so
remove.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Rename omap_boot_mode to spl_boot_mode()
Tom Rini [Tue, 14 Aug 2012 16:19:44 +0000 (09:19 -0700)]
ARM: SPL: Rename omap_boot_mode to spl_boot_mode()

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoARM: SPL: Rename omap_boot_device to spl_boot_device
Tom Rini [Mon, 13 Aug 2012 19:53:23 +0000 (12:53 -0700)]
ARM: SPL: Rename omap_boot_device to spl_boot_device

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoomap-common: SPL: Fix whitespace in omap-common/u-boot-spl.lds.
Pavel Machek [Thu, 30 Aug 2012 17:20:22 +0000 (19:20 +0200)]
omap-common: SPL: Fix whitespace in omap-common/u-boot-spl.lds.

Signed-off-by: Pavel Machek <pavel@denx.de>
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoomap-common: Fix typo in save_boot_params() in lowlevel_init.S
Tom Rini [Tue, 14 Aug 2012 16:20:06 +0000 (09:20 -0700)]
omap-common: Fix typo in save_boot_params() in lowlevel_init.S

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoomap-common: SPL: Add CONFIG_SPL_DISPLAY_PRINT / spl_display_print()
Tom Rini [Mon, 13 Aug 2012 18:37:56 +0000 (11:37 -0700)]
omap-common: SPL: Add CONFIG_SPL_DISPLAY_PRINT / spl_display_print()

Only omap4/5 currently have a meaningful set of display text and overo
had been adding a function to display nothing.  Change how this works to
be opt-in and only turned on for omap4/5 now.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agospl_mmc: Make FAT checks / calls guarded with CONFIG_SPL_FAT_SUPPORT
Tom Rini [Fri, 10 Aug 2012 16:27:14 +0000 (09:27 -0700)]
spl_mmc: Make FAT checks / calls guarded with CONFIG_SPL_FAT_SUPPORT

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoMakefile: Move SPL files to clobber, remove from clean
Tom Rini [Mon, 13 Aug 2012 19:18:34 +0000 (12:18 -0700)]
Makefile: Move SPL files to clobber, remove from clean

The 'clean' target has been removing all of spl but not u-boot itself.
For consistency and ease of testing, only remove SPL binaries / maps in
the clobber target, just like for full U-Boot

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoFAT: Make it possible to read from any file position
Benoît Thébaudeau [Tue, 18 Sep 2012 08:14:56 +0000 (08:14 +0000)]
FAT: Make it possible to read from any file position

When storage devices contain files larger than the embedded RAM, it is
useful to be able to read these files by chunks, e.g. for a software
update to the embedded NAND Flash from an external storage device (USB
stick, SD card, etc.).

Hence, this patch makes it possible by adding a new FAT API to read
files from a given position. This patch also adds this feature to the
fatload command.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
Signed-off-by: Tom Rini <trini@ti.com>
11 years agoenv: checkpatch clean env_fat
Igor Grinberg [Sun, 23 Sep 2012 05:25:21 +0000 (05:25 +0000)]
env: checkpatch clean env_fat

env_fat has several checkpatch warnings - clean those up.

Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
11 years agoenv: remove duplicated env_get_char_spec()
Igor Grinberg [Sun, 23 Sep 2012 04:39:16 +0000 (04:39 +0000)]
env: remove duplicated env_get_char_spec()

env_fat and env_remote have an implementation of env_get_char_spec()
function that is not different than the default.
Remove the duplicated code.

Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
11 years agoREADME.commands: Document what UNDEF_SYM does
Tom Rini [Thu, 20 Sep 2012 06:02:43 +0000 (06:02 +0000)]
README.commands: Document what UNDEF_SYM does

Changes in v2:
- Reword a bit more

Signed-off-by: Tom Rini <trini@ti.com>
11 years agopatman: Use reverse order for changelog
Otavio Salvador [Sat, 18 Aug 2012 07:46:04 +0000 (07:46 +0000)]
patman: Use reverse order for changelog

Specially when many revisions are need for a patchset, the most
interesting information is about the last set of changes so we output
the changelog in reverse order to easy identification of most recent
change set.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Acked-by: Simon Glass <sjg@chromium.org>
11 years agomalloc: remove extern declarations of malloc_bin_reloc() in board.c files
Daniel Schwierzeck [Sun, 3 Jun 2012 12:40:04 +0000 (12:40 +0000)]
malloc: remove extern declarations of malloc_bin_reloc() in board.c files

Declare malloc_bin_reloc() in malloc.h and remove all extern declarations
in various board.c files to get rid of one checkpatch.pl warning.

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Andreas Bießmann <andreas.devel@gmail.com>
Cc: Jason Jin <Jason.jin@freescale.com>
Cc: Macpaul Lin <macpaul@andestech.com>
Cc: Daniel Hellstrom <daniel@gaisler.com>
Acked-by: Andreas Bießmann <andreas.devel@gmail.com>
11 years agonet: Add driver for Zynq Gem IP
Michal Simek [Thu, 13 Sep 2012 20:23:34 +0000 (20:23 +0000)]
net: Add driver for Zynq Gem IP

Device driver for Zynq Gem IP.

Signed-off-by: Michal Simek <monstr@monstr.eu>
CC: Joe Hershberger <joe.hershberger@gmail.com>
CC: Marek Vasut <marex@denx.de>
Acked-by: Marek Vasut <marex@denx.de>
11 years agonet: asix: add AX88772B support
Lucas Stach [Wed, 22 Aug 2012 11:05:01 +0000 (11:05 +0000)]
net: asix: add AX88772B support

Add AX88772B ID together with two fixes needed to make this work.

1. The packet length check has to be adjusted, as all ASIX chips
only use 11 bits to indicate the length. AX88772B uses the other
bits to indicate unrelated things, which cause the check to fail.
This fix is based on a fix for the Linux kernel by Marek Vasut.
Linux upstream commit: bca0beb9363f8487ac902931a50eb00180a2d14a

2. AX88772B provides several bulk endpoints. Only the first
IN/OUT endpoints work in the default configuration. So stop
enumeration after we found them to avoid overwriting the
endpoint config with a non-working one.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Reviewed-by: Marek Vasut <marex@denx.de>
Acked-by: Marek Vasut <marex@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: asix: add read_mac function
Lucas Stach [Wed, 22 Aug 2012 11:05:00 +0000 (11:05 +0000)]
net: asix: add read_mac function

Initial device MAC should be read while getting info about the
device, so it's wrong to only read it in asix_init().

Add a dedicated function to read the initial MAC, which is also
able to handle devices that have their initial MAC stored in
EEPROM. Call this function inasix_eth_get_info().

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Reviewed-by: Marek Vasut <marex@denx.de>
Acked-by: Marek Vasut <marex@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: asix: add write_hwaddr function
Lucas Stach [Wed, 22 Aug 2012 11:04:59 +0000 (11:04 +0000)]
net: asix: add write_hwaddr function

All ASIX chipsets aside from AX88172 are able to set the MAC
address on the hardware level. Add a function to expose this
ability.

To differentiate between chip types we now carry flags as driver
private data. Also while touching the asix_dongles array
constify this.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: asix: split out basic reset function
Lucas Stach [Wed, 22 Aug 2012 11:04:58 +0000 (11:04 +0000)]
net: asix: split out basic reset function

The basic device reset ensures that the device is ready to
service commands and does not need to get redone before each
network operation.

Split out the basic reset from asix_init() and instead call it
from asix_eth_get_info(), so that it only gets called once.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: introduce transparent driver private in ueth_data
Lucas Stach [Wed, 22 Aug 2012 11:04:57 +0000 (11:04 +0000)]
net: introduce transparent driver private in ueth_data

Avoid clutter in ueth_data. Individual drivers should not mess
with structures belonging to the core like this.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Reviewed-by: Marek Vasut <marex@denx.de>
Acked-by: Marek Vasut <marex@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-video
Tom Rini [Tue, 25 Sep 2012 23:18:22 +0000 (16:18 -0700)]
Merge branch 'master' of git://git.denx.de/u-boot-video

11 years agocmd_part: add partition-related command
Stephen Warren [Fri, 21 Sep 2012 09:51:01 +0000 (09:51 +0000)]
cmd_part: add partition-related command

This implements the following:

part uuid mmc 0:1
  -> print partition UUID
part uuid mmc 0:1 uuid
  -> set environment variable to partition UUID
part list mmc 0
  -> list the partitions on the specified device

"part uuid" can be useful when writing a bootcmd which searches all
known devices for something bootable, and then wants the kernel to
use the same partition as the root device, e.g.:

part uuid ${devtype} ${devnum}:${rootpart} uuid
setenv bootargs root=PARTUUID=${uuid} ...

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agodisk: part_msdos: parse and store partition UUID
Stephen Warren [Fri, 21 Sep 2012 09:51:00 +0000 (09:51 +0000)]
disk: part_msdos: parse and store partition UUID

The MSDOS/MBR partition table includes a 32-bit unique ID, often referred
to as the NT disk signature. When combined with a partition number within
the table, this can form a unique ID similar in concept to EFI/GPT's
partition UUID.

This patch generates UUIDs in the format 0002dd75-01, which matches the
format expected by the Linux kernel.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agodisk: part_efi: parse and store partition UUID
Stephen Warren [Fri, 21 Sep 2012 09:50:59 +0000 (09:50 +0000)]
disk: part_efi: parse and store partition UUID

Each EFI partition table entry contains a UUID. Extend U-Boot's struct
disk_partition to be able to store this information, and modify
get_partition_info_efi() to fill it in.

The implementation of uuid_string() was derived from the Linux kernel,
tag v3.6-rc4 file lib/vsprintf.c function uuid_string().

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agodisk: part_efi: range-check partition number
Stephen Warren [Fri, 21 Sep 2012 09:50:58 +0000 (09:50 +0000)]
disk: part_efi: range-check partition number

Enhance get_partition_info_efi() to range-check the partition number.
This prevents invalid partitions being accessed, and prevents access
beyond the end of the gpt_pte[] array.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agodisk: get_device_and_partition() "auto" partition and cleanup
Stephen Warren [Fri, 21 Sep 2012 09:50:57 +0000 (09:50 +0000)]
disk: get_device_and_partition() "auto" partition and cleanup

Rework get_device_and_partition() to:
a) Implement a new partition ID of "auto", which requests that U-Boot
   search for the first "bootable" partition, and fall back to the first
   valid partition if none is found. This way, users don't need to
   specify an explicit partition in their commands.
b) Make use of get_device().
c) Add parameter to indicate whether returning a whole device is
   acceptable, or whether a partition is mandatory.
d) Make error-checking of the user's device-/partition-specification
   more complete. In particular, if strtoul() doesn't convert all
   characters, it's an error rather than just ignored.

The resultant device/partition returned by the function will be as
follows, based on whether the disk has a partition table (ptable) or not,
and whether the calling command allows the whole device to be returned
or not.

(D and P are integers, P >= 1)

D
D:
  No ptable:
    !allow_whole_dev: error
    allow_whole_dev: device D
  ptable:
    device D partition 1
D:0
  !allow_whole_dev: error
  allow_whole_dev: device D
D:P
  No ptable: error
  ptable: device D partition P
D:auto
  No ptable:
    !allow_whole_dev: error
    allow_whole_dev: device D
  ptable:
    first partition in device D with bootable flag set.
    If none, first valid paratition in device D.

Note: In order to review this patch, it's probably easiest to simply
look at the file contents post-application, rather than reading the
patch itself.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
[swarren: Rob implemented scanning for bootable partitions. I fixed a
couple of issues there, switched the syntax to ":auto", added the
error-checking rework, and ":0" syntax for the whole device]
Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agodisk: introduce get_device()
Stephen Warren [Fri, 21 Sep 2012 09:50:56 +0000 (09:50 +0000)]
disk: introduce get_device()

This patch introduces function get_device(). This looks up a
block_dev_desc_t from an interface name (e.g. mmc) and device number
(e.g. 0). This function is essentially the non-partition-specific
prefix of get_device_and_partition().

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agocmd_reiser: use common get_device_and_partition function
Rob Herring [Thu, 23 Aug 2012 11:31:50 +0000 (11:31 +0000)]
cmd_reiser: use common get_device_and_partition function

Convert reiserload and reiserls to use common device and partition parsing
function. With the common function "dev:part" can come from the
environment and a '-' can be used in that case.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agocmd_zfs: use common get_device_and_partition function
Rob Herring [Thu, 23 Aug 2012 11:31:49 +0000 (11:31 +0000)]
cmd_zfs: use common get_device_and_partition function

Convert zfsload and zfsls to use common device and partition parsing
function. With the common function "dev:part" can come from the
environment and a '-' can be used in that case.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agocmd_disk: use common get_device_and_partition function
Rob Herring [Thu, 23 Aug 2012 11:31:48 +0000 (11:31 +0000)]
cmd_disk: use common get_device_and_partition function

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agocmd_fat: use common get_device_and_partition function
Rob Herring [Thu, 23 Aug 2012 11:31:47 +0000 (11:31 +0000)]
cmd_fat: use common get_device_and_partition function

Convert fatload, fatls, and fatinfo to use common device and partition
parsing function. With the common function "dev:part" can come from the
environment and a '-' can be used in that case.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agocmd_extX: use common get_device_and_partition function
Rob Herring [Thu, 23 Aug 2012 11:31:46 +0000 (11:31 +0000)]
cmd_extX: use common get_device_and_partition function

Convert ext2/4 load, ls, and write functions to use common device and
partition parsing function. With the common function "dev:part" can come
from the environment and a '-' can be used in that case.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agoext4: remove init_fs/deinit_fs
Rob Herring [Thu, 23 Aug 2012 11:31:45 +0000 (11:31 +0000)]
ext4: remove init_fs/deinit_fs

There's no real need to expose this and it can be removed by using a static
allocation.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agodisk/part: introduce get_device_and_partition
Rob Herring [Fri, 21 Sep 2012 04:08:17 +0000 (04:08 +0000)]
disk/part: introduce get_device_and_partition

All block device related commands (scsiboot, fatload, ext2ls, etc.) have
simliar duplicated device and partition parsing and selection code. This
adds a common function to replace various implementations.

The new function has an enhancement over current versions. If no device
or partition is specified on the command line, the bootdevice env variable
will be used (scsiboot does this).

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agodisk/part: check bootable flag for DOS partitions
Rob Herring [Thu, 23 Aug 2012 11:31:43 +0000 (11:31 +0000)]
disk/part: check bootable flag for DOS partitions

Determine which partitions are bootable/active. In the partition listing,
print "Boot" for partitions with the bootable/active flag set.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agocombine block device load commands into common function
Rob Herring [Fri, 21 Sep 2012 04:02:30 +0000 (04:02 +0000)]
combine block device load commands into common function

All the raw block load commands duplicate the same code. Starting with
the ide version as it has progress updates convert ide, usb, and scsi boot
commands to all use a common version.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
11 years agodisk: make get_partition_info() always available to disk.c
Stephen Warren [Fri, 21 Sep 2012 12:46:54 +0000 (12:46 +0000)]
disk: make get_partition_info() always available to disk.c

Now that get_device_and_partition() always calls get_partition_info()
when disk.c is compiled, we must always compile the function, rather
than ifdef it away.

The implementation must be conditional based on CONFIG_CMD_* etc., since
that's what e.g. part_dos.c uses to ifdef out get_partition_info_dos();
CONFIG_DOS_PARTITION can be enabled even without those commands being
enabled.

Technically, this change is required before Rob's "disk/part: introduce
get_device_and_partition" patch. However, at least when the compiler
optimizer is turned on, it isn't required before then in practice,
since get_device_and_partition() calls get_dev(), which is stubbed out
in disk.c under exactly the same conditions that get_partition_info()
is not compiled, and hence the compiler never generates code for the
call to the missing function. However, in my later patch "disk:
get_device_and_partition() "auto" partition and cleanup", the optimizer
doesn't succeed at this, and may attempt to reference the undefined
function.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agoMAKEALL: fix per arch board lists
Allen Martin [Wed, 29 Aug 2012 11:08:59 +0000 (11:08 +0000)]
MAKEALL: fix per arch board lists

The LIST_arm rule included the Atmel boards twice (by virtue of
including both LIST_at91 and LIST_ARM9) and was missing all the
arm720t, arm946es, and arm1176 boards.  Change this list to use
boards_by_arch() which is less error prone.  After this change
"./MAKEALL arm" and "./MAKEALL -a arm" build the same boards.

Also fix up some missing and duplicate boards to arm, mips, and m68k.

Signed-off-by: Allen Martin <amartin@nvidia.com>
Acked-by: Tom Rini <trini@ti.com>
11 years agoARM: arm1176: Define arch_cpu_init() at the SoC level
Stephen Warren [Sat, 1 Sep 2012 16:27:56 +0000 (16:27 +0000)]
ARM: arm1176: Define arch_cpu_init() at the SoC level

Commit 86c6326 "ARM: arm1176: enable instruction cache in
arch_cpu_init()" defined arch_cpu_init() in a file that is shared across
all arm1176 SoCs. tnetv107x already implemented this function, which
caused linking to break. Move the new conflicting arch_cpu_init() into
arm1176/bcm2835/init.c so that it doesn't conflict; grep indicates this
function is usually defined at the SoC-level, not the CPU-level, at least
for ARM.

Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
Acked-by: Marek Vasut <marex@denx.de>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-mpc85xx
Tom Rini [Tue, 25 Sep 2012 19:23:55 +0000 (12:23 -0700)]
Merge branch 'master' of git://git.denx.de/u-boot-mpc85xx

11 years agocommon/lcd: fix build breakage for at91sam9x5ek and trats boards
Anatolij Gustschin [Sat, 22 Sep 2012 06:55:53 +0000 (06:55 +0000)]
common/lcd: fix build breakage for at91sam9x5ek and trats boards

Commit 203c37b8c5556aad1901ce4954792afd718c7d42
(common lcd: simplify core functions)

and commit bfdcc65e1163b4891643c2a670570c478b9af2a4
(common lcd: simplify lcd_display_bitmap)

caused build breakage for at91sam9x5ek board configurations
and for trats board. Fix these build errors.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
11 years agonet: Filter incoming netconsole packets by IP
Joe Hershberger [Tue, 18 Sep 2012 10:01:32 +0000 (10:01 +0000)]
net: Filter incoming netconsole packets by IP

Check the incoming packets' source IP address... if ncip isn't set to a
broadcast address, only listen to the client at ncip.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: Allow netconsole settings to change after nc_start
Joe Hershberger [Tue, 18 Sep 2012 10:01:31 +0000 (10:01 +0000)]
net: Allow netconsole settings to change after nc_start

Refresh the netconsole settings from the env before each packet instead
of only on netconsole init.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: Improve the speed of netconsole
Joe Hershberger [Fri, 3 Aug 2012 10:59:08 +0000 (10:59 +0000)]
net: Improve the speed of netconsole

Previously u-boot would initialize the network interface for every
network operation and then shut it down again.  This makes sense for
most operations where the network in not known to be needed soon after
the operation is complete.  In the case of netconsole, it will use the
network for every interaction with the shell or every printf.  This
means that the network is being reinitialized very often.  On many
devices, this intialization is very slow.

This patch checks for consecutive netconsole actions and leaves the
ethernet hardware initialized between them.  It will still behave the
same old way for all other network operations and any time another
network operation happens between netconsole operations.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Stefano Babic <sbabic@denx.de>
11 years agonet: Make the netconsole buffer size configurable
Joe Hershberger [Tue, 31 Jul 2012 06:09:17 +0000 (06:09 +0000)]
net: Make the netconsole buffer size configurable

Allow a board to configure a larger buffer for netconsole, but leave
the default.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Cc: Mike Frysinger <vapier@gentoo.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
11 years agonet: sh_eth: Add support R8A7740 of rmobile (arm core)
Nobuhiro Iwamatsu [Thu, 2 Aug 2012 22:08:40 +0000 (22:08 +0000)]
net: sh_eth: Add support R8A7740 of rmobile (arm core)

R8A7740 of rmobile has ethernet device, and this is same IP of
sh-ether. This support R8A7740 of rmobile.

Signed-off-by: Hideyuki Sano <hideyuki.sano.dn@renesas.com>
Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
11 years agodm: net: Fixup the armada100 FEC driver
Marek Vasut [Fri, 27 Jul 2012 09:50:07 +0000 (09:50 +0000)]
dm: net: Fixup the armada100 FEC driver

Apply the following questionable adjustment to silence GCC.

armada100_fec.c: In function ‘armdfec_send’:
armada100_fec.c:589:2: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Joe Hershberger <joe.hershberger@ni.com>
Acked-by: Prafulla Wadaskar <prafulla@marvell.com>
11 years agonet: emaclite: Support OF initialization
Michal Simek [Thu, 28 Jun 2012 21:37:57 +0000 (21:37 +0000)]
net: emaclite: Support OF initialization

Support new CONFIG_OF_CONTROL option where device
probing is done based on device tree description.

Signed-off-by: Michal Simek <monstr@monstr.eu>
CC: Joe Hershberger <joe.hershberger@gmail.com>
11 years agodm: net: Move IXP NPE to drivers/net/
Marek Vasut [Sat, 21 Jul 2012 05:02:26 +0000 (05:02 +0000)]
dm: net: Move IXP NPE to drivers/net/

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Bryan Hundven <bryanhundven@gmail.com>
Cc: Michael Schwingen <rincewind@discworld.dascon.de>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: U-Boot DM <u-boot-dm@lists.denx.de>
Cc: Joe Hershberger <joe.hershberger@ni.com>
11 years agonet: bugfix: NetSetTimeout assumes CONFIG_SYS_HZ=1000
Tetsuyuki Kobayashi [Mon, 25 Jun 2012 02:37:27 +0000 (02:37 +0000)]
net: bugfix: NetSetTimeout assumes CONFIG_SYS_HZ=1000

NetSetTimeout sets incorrect value to timeDelta when CONFIG_SYS_HZ != 1000.

Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
11 years agoapi: net: fix length check in eth_receive()
Michael Walle [Fri, 22 Jun 2012 11:24:28 +0000 (11:24 +0000)]
api: net: fix length check in eth_receive()

If the requested length is too small to hold the received packet,
eth_receive() will return -1 and will leave the packet in the receive
buffers. Instead of returning an error in this case, we return the first
portion of the received packet and remove it from the receive buffers.

This fixes FreeBSD's ubldr. Without this patch it will just stop receiving
packets if the NIC receives more than PKTBUFSRX too large packets.

Signed-off-by: Michael Walle <michael@walle.cc>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
Cc: Rafal Jaworowski <raj@semihalf.com>
Cc: Piotr Kruszynski <ppk@semihalf.com>
11 years agonet: Make netconsole src and dest ports configurable
Joe Hershberger [Tue, 31 Jul 2012 06:06:41 +0000 (06:06 +0000)]
net: Make netconsole src and dest ports configurable

It is desirable to use different port numbers for sending and receiving
packets with netconsole in the case where you have more than one device
on the local subnet with netconsole enabled for broadcast.  When they
use the same port for both, any output from one will look like input to
the other.  This is typlically not desirable.

This patch allows the input and output ports to be specified separately
in the environment.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Cc: Mike Frysinger <vapier@gentoo.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
11 years agomx28evk: Add missing 'setexpr' command
Otavio Salvador [Fri, 21 Sep 2012 03:02:03 +0000 (03:02 +0000)]
mx28evk: Add missing 'setexpr' command

The environment now uses expressions but we missed the setexpr command
was not being include. This patch adds it.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
11 years agoi.MX: shut down video before launch of O/S
Eric Nelson [Sun, 23 Sep 2012 07:30:55 +0000 (07:30 +0000)]
i.MX: shut down video before launch of O/S

Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
11 years agoi.MX: mxc_ipuv3_fb: add ipuv3_fb_shutdown() routine to stop IPU frame buffer
Eric Nelson [Sun, 23 Sep 2012 07:30:54 +0000 (07:30 +0000)]
i.MX: mxc_ipuv3_fb: add ipuv3_fb_shutdown() routine to stop IPU frame buffer

Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
Tested-by: Fabio Estevam <fabio.estevam@freescale.com>
11 years agomx28evk: Remove fecmxc_mii_postcall()
Fabio Estevam [Fri, 21 Sep 2012 10:00:53 +0000 (10:00 +0000)]
mx28evk: Remove fecmxc_mii_postcall()

fecmxc_mii_postcall() is specific to the KSZ9021 PHY on m28evk and
should not be used on mx28evk, which has LAN8270 instead.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Marek Vasut <marex@denx.de>
11 years agoKARO TX25: Fix NAND Flash R/W cycle times
Benoît Thébaudeau [Wed, 8 Aug 2012 03:55:32 +0000 (03:55 +0000)]
KARO TX25: Fix NAND Flash R/W cycle times

The NAND Flash of the KARO TX25 board is a Samsung K9F1G08U0B with 25-ns R/W
cycle times. However, the NFC clock for this board was set to 66.5 MHz, so using
the NFC driver in symmetric mode (i.e. 1 NFC clock cycle = 1 NF R/W cycle)
resulted in NF R/W cycle times of 15 ns, hence corrupted NF accesses.

This patch fixes this issue by setting the NFC clock to the highest frequency
complying to the 25-ns NF R/W cycle times specification, i.e. 33.25 MHz.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: John Rigby <jcrigby@gmail.com>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Daniel Gachet <Daniel.Gachet@hefr.ch>
Acked-by: Stefano Babic <sbabic@denx.de>
11 years agomx51evk: Add CONFIG_REVISION_TAG
Benoît Thébaudeau [Tue, 18 Sep 2012 04:48:42 +0000 (04:48 +0000)]
mx51evk: Add CONFIG_REVISION_TAG

FSL 2.6.35 kernel assumes that the bootloader passes the CONFIG_REVISION_TAG
information.

If this data is not present, the kernel misconfigures the TZIC, which results in
the timer interrupt handler never being called, so the kernel deadlocks while
calibrating its delay.

Suggested-by: Greg Topmiller <Greg.Topmiller@jdsu.com>
Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Fabio Estevam <festevam@gmail.com>
Acked-by: Fabio Estevam <fabio.estevam@freescale.com>
11 years agoPrepare v2012.10-rc1 v2012.10-rc1
Tom Rini [Sat, 22 Sep 2012 00:18:28 +0000 (17:18 -0700)]
Prepare v2012.10-rc1

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoMerge branch 'agust@denx.de' of git://git.denx.de/u-boot-staging
Tom Rini [Fri, 21 Sep 2012 23:22:18 +0000 (16:22 -0700)]
Merge branch 'agust@denx.de' of git://git.denx.de/u-boot-staging

11 years agopci: fix some warnings related to assumptions about
Kumar Gala [Wed, 19 Sep 2012 04:47:36 +0000 (04:47 +0000)]
pci: fix some warnings related to assumptions about

The following commit introduced some warnings associated with using
pci_addr_t instead of a proper 32-bit data type.

commit af778c6d9e2b945ee03cbc53bb976238a3374f33
Author: Andrew Sharp <andywyse6@gmail.com>
Date:   Wed Aug 1 12:27:16 2012 +0000

    pci: fix errant data types and corresponding access functions

On some platforms pci_addr_t is defined as a 64-bit data type so its not
proper to use with pci_{read,write}_config_dword.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-arm
Tom Rini [Fri, 21 Sep 2012 21:53:13 +0000 (14:53 -0700)]
Merge branch 'master' of git://git.denx.de/u-boot-arm

11 years agovideo/powerpc: don't touch DIU registers that we don't need
Timur Tabi [Mon, 17 Sep 2012 11:12:42 +0000 (11:12 +0000)]
video/powerpc: don't touch DIU registers that we don't need

Several DIU registers were being initialized either unnecessarily or to
wrong values.

1) All interrupts were enabled even though there's no interrupt handler.
   Interrupts were left enabled when booting Linux.

2) Don't configure a dummy area descriptor, since we don't support ADs
   in U-Boot.

3) Don't configure any write-back buffer registers, since we don't use
   that mode.

4) The default values for the THRESHOLDS, SYN_POL, and PLUT registers
   should be used, so don't touch those registers either.

Signed-off-by: Timur Tabi <timur@freescale.com>
11 years agocommon/lcd: add protection from null bmp pointer
Nikita Kiryanov [Sun, 19 Aug 2012 19:32:30 +0000 (19:32 +0000)]
common/lcd: add protection from null bmp pointer

If the bmp pointer is null then U-Boot will get stuck when trying
to load the image.
What's worse, it will get stuck before the U-Boot shell becomes
available to the user, thus making it difficult to correct the
situation.

To protect from the above scenario, check if the pointer is valid.

Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
11 years agofdt: Add header guard to fdtdec.h
Simon Glass [Thu, 12 Jul 2012 05:25:02 +0000 (05:25 +0000)]
fdt: Add header guard to fdtdec.h

This makes it easier to include this header from other headers.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
11 years agofdt: Tidy debugging, add to fdtdec_get_int/addr()
Simon Glass [Thu, 12 Jul 2012 05:25:01 +0000 (05:25 +0000)]
fdt: Tidy debugging, add to fdtdec_get_int/addr()

The new debugging shows the value of integers and addresses read
from the device tree and tidy up GPIO output.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoAdd gpio_request() to asm-generic header
Simon Glass [Wed, 13 Jun 2012 06:19:37 +0000 (06:19 +0000)]
Add gpio_request() to asm-generic header

This function should also be part of the GPIO API, so add it.

Signed-off-by: Simon Glass <sjg@chromium.org>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-usb
Tom Rini [Fri, 21 Sep 2012 16:29:38 +0000 (09:29 -0700)]
Merge branch 'master' of git://git.denx.de/u-boot-usb

11 years agoRevert "memsize: Fix for bug in memory sizing code"
Tom Rini [Fri, 21 Sep 2012 15:14:05 +0000 (08:14 -0700)]
Revert "memsize: Fix for bug in memory sizing code"

After further investigation this change is not correct and results in
get_ram_size returning incorrectly large values.  Reported first by
Gerlando Falauto.

This reverts commit b8496cced856ff411f1eb2e4eff20f5abe7080b0.

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoMerge remote-tracking branch 'u-boot-imx/master'
Albert ARIBAUD [Thu, 20 Sep 2012 22:26:19 +0000 (00:26 +0200)]
Merge remote-tracking branch 'u-boot-imx/master'

11 years agousb: do explicit unaligned accesses
Lucas Stach [Thu, 6 Sep 2012 06:00:13 +0000 (08:00 +0200)]
usb: do explicit unaligned accesses

usb_hub_descriptor has to be packed as it's used for
communication with the device. Member wHubCharacteristics
violates the natural alignment rules.

Use explicit unaligned access functions for this member.
Fixes ARMv7 traping while using USB.

v2: fix typo found by Thomas Langer

v3: rebased on top of u-boot-usb/master

Signed-off-by: Lucas Stach <dev@lynxeye.de>
11 years agodfu:usb:fix: Read the "filesize" environment variable only when file read
Łukasz Majewski [Thu, 23 Aug 2012 23:33:56 +0000 (23:33 +0000)]
dfu:usb:fix: Read the "filesize" environment variable only when file read

The "filesize" environment variable shall be read only when relevant
file is read.

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Reviewed-by: Marek Vasut <marex@denx.de>
11 years agodfu:usb: Support for ext4
Łukasz Majewski [Thu, 23 Aug 2012 23:33:55 +0000 (23:33 +0000)]
dfu:usb: Support for ext4

Support for ext4 file system handling at DFU.

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Reviewed-by: Marek Vasut <marex@denx.de>
11 years agoMerge branch 'ext4'
Tom Rini [Thu, 20 Sep 2012 18:27:35 +0000 (11:27 -0700)]
Merge branch 'ext4'

Update Makefile change for LIBS -> LIBS-y change.

Conflicts:
Makefile

Signed-off-by: Tom Rini <trini@ti.com>
11 years agoext4: cache-align buffers so the invalidation works
Stephen Warren [Tue, 18 Sep 2012 08:05:28 +0000 (08:05 +0000)]
ext4: cache-align buffers so the invalidation works

DMA buffer cache invalidation requires that buffers have cache-aligned
buffer locations and sizes. Use memalign() and ALLOC_CACHE_ALIGN_BUFFER()
to ensure this.

On Tegra at least, without this fix, the following fail commands fail in
u-boot-master/ext4, but succeeded at the branch's branch point in
u-boot/master. With this fix, the commands work again:

ext2ls mmc 0:1 /
ext2load mmc 0:1 /boot/zImage

Cc: Uma Shankar <uma.shankar@samsung.com>
Cc: Manjunatha C Achar <a.manjunatha@samsung.com>
Cc: Iqbal Shareef <iqbal.ams@samsung.com>
Cc: Hakgoo Lee <goodguy.lee@samsung.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Tom Rini <trini@ti.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
11 years agoFlex bus definition update for Coldfire 5253.
Jason Jin [Thu, 20 Sep 2012 06:17:46 +0000 (14:17 +0800)]
Flex bus definition update for Coldfire 5253.

originally work by Jate Sujjavanich <jsujjavanich@syntech-fuelmaster.com>
----
The defines in arch/m68k/include/coldfire/flexbus.h are not compatible with
the 5235 processor. The registers in struct fbcs are different sizes from
those in the 5235. Also, the defines are a little different.

This is what I have so far. Comments?
----

Reformat the patch manually by Jason Jin

Signed-off-by: Jate Sujjavanich <jsujjavanich@syntech-fuelmaster.com>
Signed-off-by: Jason Jin <Jason.jin@freescale.com>
11 years agoColdFire: Queued SPI driver
Richard Retanubun [Thu, 24 Mar 2011 08:58:11 +0000 (08:58 +0000)]
ColdFire: Queued SPI driver

This patch adds a driver for Freescale Colfire Queued SPI bus.
Coded to work with 8 bits per transfer to use with SPI flash.
CPOL, CPHA, and CS_ACTIVE_HIGH can be configured.

Tested with MCF5270 which have 4 chip selects.

Activate by #define CONFIG_CF_QSPI in board config.

Signed-off-by: Richard Retanubun <richardretanubun@ruggedcom.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF54451 and MCF54455
Alison Wang [Mon, 26 Mar 2012 21:49:08 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF54451 and MCF54455

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF547x and MCF548x
Alison Wang [Mon, 26 Mar 2012 21:49:07 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF547x and MCF548x

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF523x
Alison Wang [Mon, 26 Mar 2012 21:49:06 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF523x

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF532x/MCF537x/MCF5301x
Alison Wang [Mon, 26 Mar 2012 21:49:05 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF532x/MCF537x/MCF5301x

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF52x2
Alison Wang [Mon, 26 Mar 2012 21:49:04 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF52x2

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Clean up checkpatch warnings for MCF5227x
Alison Wang [Mon, 26 Mar 2012 21:49:03 +0000 (21:49 +0000)]
ColdFire: Clean up checkpatch warnings for MCF5227x

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Add clear and set bits macros for ColdFire platform
Alison Wang [Mon, 26 Mar 2012 21:49:02 +0000 (21:49 +0000)]
ColdFire: Add clear and set bits macros for ColdFire platform

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Update the bitops for ColdFire platform
Alison Wang [Sun, 25 Mar 2012 19:18:49 +0000 (19:18 +0000)]
ColdFire: Update the bitops for ColdFire platform

This patch uses the general ffs definition to replace the
platform ffs definition.

This patch also fixes the build error by adding hweightN
definition for m5329evb and m5373evb.

Signed-off-by: Jason Jin <Jason.jin@freescale.com>
Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoColdFire: Rename NANDFLASH_SIZE into CONFIG_NANDFLASH_SIZE for MCF537x
Alison Wang [Sun, 25 Mar 2012 19:18:14 +0000 (19:18 +0000)]
ColdFire: Rename NANDFLASH_SIZE into CONFIG_NANDFLASH_SIZE for MCF537x

This patch fixes the build error for MCF537x. As the NANDFLASH_SIZE is
redefined in boards.cfg, it is needed to rename NANDFLASH_SIZE into
CONFIG_NANDFLASH_SIZE in include/configs/M5373EVB.h.

Signed-off-by: Alison Wang <b18965@freescale.com>
11 years agoMerge branch 'master' of git://git.denx.de/u-boot-mpc83xx
Tom Rini [Tue, 18 Sep 2012 21:56:31 +0000 (14:56 -0700)]
Merge branch 'master' of git://git.denx.de/u-boot-mpc83xx

11 years agompc8308rdb: add support for eSDHC MMC controller
Ira W. Snyder [Wed, 12 Sep 2012 21:17:35 +0000 (14:17 -0700)]
mpc8308rdb: add support for eSDHC MMC controller

Add support for the onboard eSDHC MMC controller. The hardware on the
MPC8308RDB has the following errata:

- ESDHC111: manual asynchronous CMD12 is broken
- DMA is broken (PIO works)

Signed-off-by: Ira W. Snyder <iws@ovro.caltech.edu>
[added include fsl_esdhc header to prevent implicit declarations of
fsl_esdhc_mmc_init() and fdt_fixup_esdhc()]

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>