Commit Graph

17544 Commits

Author SHA1 Message Date
Joe Hershberger
7f51898c1b 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>
2012-09-24 13:17:24 -05:00
Tom Rini
ee1f4caaa2 Prepare v2012.10-rc1
Signed-off-by: Tom Rini <trini@ti.com>
2012-09-21 17:18:28 -07:00
Tom Rini
9fe2cfb43a Merge branch 'agust@denx.de' of git://git.denx.de/u-boot-staging 2012-09-21 16:22:18 -07:00
Kumar Gala
cf5787f2a4 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 af778c6d9e
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>
2012-09-22 00:24:34 +02:00
Tom Rini
495dbd72dd Merge branch 'master' of git://git.denx.de/u-boot-arm 2012-09-21 14:53:13 -07:00
Simon Glass
5bfa78db4f 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>
2012-09-21 22:02:36 +02:00
Simon Glass
1cb2323b8a 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>
2012-09-21 22:01:13 +02:00
Simon Glass
1bbd28d215 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>
2012-09-21 21:11:25 +02:00
Tom Rini
50d924b459 Merge branch 'master' of git://git.denx.de/u-boot-usb 2012-09-21 09:29:38 -07:00
Tom Rini
3ab270d5df 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 b8496cced8.

Signed-off-by: Tom Rini <trini@ti.com>
2012-09-21 08:14:05 -07:00
Albert ARIBAUD
d193c1b6eb Merge remote-tracking branch 'u-boot-imx/master' 2012-09-21 00:26:19 +02:00
Lucas Stach
93ad908c43 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>
2012-09-21 00:05:00 +02:00
Łukasz Majewski
81c1d7b605 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>
2012-09-21 00:05:00 +02:00
Łukasz Majewski
43e6627259 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>
2012-09-21 00:04:59 +02:00
Tom Rini
5fb29f3c48 Merge branch 'ext4'
Update Makefile change for LIBS -> LIBS-y change.

Conflicts:
	Makefile

Signed-off-by: Tom Rini <trini@ti.com>
2012-09-20 11:27:35 -07:00
Stephen Warren
55b523b7d4 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>
2012-09-20 11:07:26 -07:00
Jason Jin
30a3f3881e 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>
2012-09-20 20:39:41 +08:00
Richard Retanubun
59d0612252 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>
2012-09-20 20:39:27 +08:00
Alison Wang
198cafbf2c ColdFire: Clean up checkpatch warnings for MCF54451 and MCF54455
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:27 +08:00
Alison Wang
a4110eecf2 ColdFire: Clean up checkpatch warnings for MCF547x and MCF548x
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:27 +08:00
Alison Wang
c6d8863015 ColdFire: Clean up checkpatch warnings for MCF523x
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:27 +08:00
Alison Wang
aa0d99fc28 ColdFire: Clean up checkpatch warnings for MCF532x/MCF537x/MCF5301x
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:27 +08:00
Alison Wang
32dbaafa5a ColdFire: Clean up checkpatch warnings for MCF52x2
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:26 +08:00
Alison Wang
849fc42471 ColdFire: Clean up checkpatch warnings for MCF5227x
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:26 +08:00
Alison Wang
33d4411931 ColdFire: Add clear and set bits macros for ColdFire platform
Signed-off-by: Alison Wang <b18965@freescale.com>
2012-09-20 20:39:26 +08:00
Alison Wang
f7799a1175 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>
2012-09-20 20:37:40 +08:00
Alison Wang
2ee03c6e23 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>
2012-09-20 20:37:34 +08:00
Tom Rini
49b3962d20 Merge branch 'master' of git://git.denx.de/u-boot-mpc83xx 2012-09-18 14:56:31 -07:00
Ira W. Snyder
db1fc7d28e 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>
2012-09-18 16:16:45 -05:00
Ira W. Snyder
40775e9676 mpc8308rdb: add support for FIT images
This is very useful on a modern system.

Signed-off-by: Ira W. Snyder <iws@ovro.caltech.edu>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
2012-09-18 16:16:44 -05:00
Ira W. Snyder
ea1ea54e35 mpc8308rdb: add support for Spansion SPI flash on header J8
The SPI pins are routed to header J8 for testing SPI functionality. A
Spansion flash has been wired up and tested on this header.

This patch breaks support for the second TSEC interface, since the GPIO
pin used as a chip select is pinmuxed with some of the TSEC pins.

Signed-off-by: Ira W. Snyder <iws@ovro.caltech.edu>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
2012-09-18 16:16:44 -05:00
Ira W. Snyder
f138ca1373 mpc8xxx_spi: fix SPI support on MPC8308RDB
The MPC8308RDB Reference Manual states that no bits in the SPMODE
register are allowed to change while the enable (EN) bit is set.

This driver changes the character length bits (LEN) while the enable
(EN) bit is set. Clearing the EN bit while changing the LEN bits makes
the driver work correctly on MPC8308RDB.

Signed-off-by: Ira W. Snyder <iws@ovro.caltech.edu>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
2012-09-18 16:16:44 -05:00
Benoît Thébaudeau
7ee46cebcb FAT: Fix file contents listed as directory
With:
fatls mmc 0 /dir/file
dir: regular directory
file: regular file

The previous code read the contents of file as if it were directory entries to
list. This patch refuses to list file contents as if it were a folder.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-18 12:01:53 -07:00
Gerlando Falauto
d5370febbc env: delete selected vars not present in imported env
When variables explicitly specified on the command line are not present
in the imported env, delete them from the running env.
If the variable is also missing from the running env, issue a warning.

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
b64b7c3df7 env: make "env default" selective, check and apply
Change the syntax (user API) for "env default":
  -f: override write-once variables
  var... : accept individual variable(s)
  -a: all (resetting the whole env is NOT the default behavior)

Enable variable checking and make changes effective by
enabling do_apply argument to himport_r().

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
152874b65b env: check and apply changes on delete/destroy
Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
c5983592e9 env: add check/apply logic to himport_r()
Change hashtable so that a callback function will decide whether a
variable can be overwritten, and possibly apply the changes.

So add a new field to struct hsearch_data:

 o "apply" callback function to check whether a variable can be
    overwritten, and possibly immediately apply the changes;
    when NULL, no check is performed.

And a new argument to himport_r():
 o "do_apply": whether to call the apply callback function

NOTE: This patch does not change the current behavior.

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
348b1f1c60 env: make himport_r() selective on variables
Add 2 new arguments to himport_r():

 o "nvars", "vars": number and list of variables to take into account
   (0 means ALL)

NOTE: This patch does not change the current behaviour.

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
c3f6525854 env: unify logic to check and apply changes
The logic of checking special parameters (e.g. baudrate, stdin, stdout,
for a valid value and/or whether can be overwritten) and applying the
new value to the running system is now all within a single function
env_check_apply() which can be called whenever changes are made
to the environment, no matter if by set, default or import.

With this patch env_check_apply() is only called by "env set",
retaining previous behavior.

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Gerlando Falauto
c2ba2ff511 env: cosmetic: drop assignment i = iomux_doenv()
iomux_doenv() can only return 0 or 1.
So there is no need to save its return value in variable i, as checking
its truth value within an if statement is enough.

Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2012-09-18 12:01:52 -07:00
Benoît Thébaudeau
8ae51ae172 fw_env: Add env vars describing U-Boot target board
Commit 5e724ca did the same thing for env_common and env_embedded, but forgot
fw_env.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-18 12:01:51 -07:00
Benoît Thébaudeau
84209afb87 env_common: Add missing ethprime
The ethprime env var was missing from env_common.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-18 12:01:51 -07:00
Benoît Thébaudeau
4796bc4bbc env import/export: Remove from help if disabled
Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-09-18 12:01:51 -07:00
Iwo Mergler
b8496cced8 memsize: Fix for bug in memory sizing code
The original memory sizing code in get_ram_size clobbers the word
at the base address, but forgets to restore it.

Signed-off-by: Iwo Mergler <Iwo.Mergler@netcommwireless.com>
2012-09-18 12:01:51 -07:00
Stephen Warren
78b2de802f env_nand: fix incorrect size parameter to ALLOC_CACHE_ALIGN_BUFFER
The third parameter to ALLOC_CACHE_ALIGN_BUFFER is not size (as named),
but rather count (number of elements of the type to allocate). The
current code ends up allocating one copy of env_t for each byte in its
size, which quite possibly ends up overflowing RAM.

This fixes a bug in commit 3801a15 "env_nand: align NAND buffers".

Reported-by: Prabhakar Lad <prabhakar.csengg@gmail.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Reported-by: Prabhakar Lad <prabhakar.lad@ti.com>
2012-09-18 12:01:51 -07:00
Marek Vasut
535c74f80c ARM: Remove apollon board
This board is the only board that still sticks to OneNAND IPL.
Remove this board, since we have SPL around for a while and
OneNAND is well supported in the SPL framework. The board can
be revived if necessary.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Tom Rini <trini@ti.com>
2012-09-18 12:01:51 -07:00
Marek Vasut
e4a189acfe IPL: Remove remains of OneNAND IPL
After removing the Apollon board, remove the OneNAND IPL too.
There are no users for it any more.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Minkyu Kang <promsoft@gmail.com>
Cc: Tom Rini <trini@ti.com>
Acked-by: Minkyu Kang <mk7.kang@samsung.com>
2012-09-18 12:01:51 -07:00
Tyler Olmstead
be7e41efda spl: remove forced linking of commands into SPL
Remove linker command line options from the SPL makefile
that force the inclusion of unreferenced command code from
linked object files. As commands are not used in the SPL,
these options resulted in an unnecessary increase in the
image size, in addition to introducing the possibility of
tricky link errors in the case where the command code
contained symbols that were not resolved by linking in the
limited objects compiled in the SPL build.

Signed-off-by: Tyler Olmstead <tyler.j.olmstead@gmail.com>
Acked-by: Tom Rini <trini@ti.com>
2012-09-18 12:01:50 -07:00
Marek Vasut
b2f2760006 dm: sparc: Fixup the compile warnings in sparc code
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Hellstrom <daniel@gaisler.com>
Cc: u-boot-dm@lists.denx.de
2012-09-18 12:01:50 -07:00
Marek Vasut
d97f01a64f dm: sparc: common: Fixup cmd_bdinfo warnings
cmd_bdinfo.c: In function ‘do_bdinfo’:
cmd_bdinfo.c:220:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘int’ [-Wformat]
cmd_bdinfo.c:222:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘int’ [-Wformat]
cmd_bdinfo.c:224:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘int’ [-Wformat]
cmd_bdinfo.c:226:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘int’ [-Wformat]
cmd_bdinfo.c:228:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘int’ [-Wformat]

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Daniel Hellstrom <daniel@gaisler.com>
Cc: u-boot-dm@lists.denx.de
2012-09-18 12:01:50 -07:00