]> git.sur5r.net Git - u-boot/log
u-boot
10 years agomtd: nand: omap: fix sw->hw->sw ecc switch
Nikita Kiryanov [Mon, 16 Dec 2013 17:19:01 +0000 (19:19 +0200)]
mtd: nand: omap: fix sw->hw->sw ecc switch

When switching ecc mode, omap_select_ecc_scheme() assigns the appropriate values
into the current nand chip's ecc.layout struct. This is done under the
assumption that the struct exists only to store values, so it is OK to overwrite
it, but there is at least one situation where this assumption is incorrect:

When switching to 1 bit hamming code sw ecc, the job of assigning layout data
is outsourced to nand_scan_tail(), which simply assigns into ecc.layout a
pointer to an existing struct prefilled with the appropriate values. This struct
doubles as both data and layout definition, and therefore shouldn't be
overwritten, but on the next switch to hardware ecc, this is exactly what's
going to happen. The next time the user switches to software ecc, they're
going to get a messed up ecc layout.

Prevent this and possible similar bugs by explicitly using the
private-to-omap_gpmc.c omap_ecclayout struct when switching ecc mode.

Cc: Scott Wood <scottwood@freescale.com>
Cc: Pekon Gupta <pekon@ti.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
10 years agonand_util.c: Use '%zd' for length in nand_unlock debug print
Tom Rini [Mon, 16 Dec 2013 14:59:34 +0000 (09:59 -0500)]
nand_util.c: Use '%zd' for length in nand_unlock debug print

length is size_t so needs to be '%zd' not '%d' to avoid warnings.

Cc: Scott Wood <scottwood@freescale.com>
Signed-off-by: Tom Rini <trini@ti.com>
10 years agomtd: nand: omap: fix HAM1_SW ecc using default value for ecc.size
Nikita Kiryanov [Thu, 12 Dec 2013 13:19:31 +0000 (15:19 +0200)]
mtd: nand: omap: fix HAM1_SW ecc using default value for ecc.size

Commit "mtd: nand: omap: enable BCH ECC scheme using ELM for generic
platform" (d016dc42cedbf6102e100fa9ecb58462edfb14f8) changed the way
software ECC is configured, both during boot, and during ecc switch, in a way
that is not backwards compatible with older systems:

Older version of omap_gpmc.c always assigned ecc.size = 0 when configuring
for software ecc, relying on nand_scan_tail() to select a default for ecc.size
(256), while the new version of omap_gpmc.c assigns ecc.size = pagesize,
which is likely to not be 256.

Since 1 bit hamming sw ecc is only meant to be used by legacy devices, revert
to the original behavior.

Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@ti.com>
Cc: Scott Wood <scottwood@freescale.com>
Cc: Pekon Gupta <pekon@ti.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Acked-by: Pekon Gupta <pekon@ti.com>
10 years agomtd: nand: omap_gpmc: cosmetic: Fix indentation
Stefan Roese [Thu, 5 Dec 2013 06:58:06 +0000 (07:58 +0100)]
mtd: nand: omap_gpmc: cosmetic: Fix indentation

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Pekon Gupta <pekon@ti.com>
Cc: Scott Wood <scottwood@freescale.com>
[scottwood@freescale.com: wrap some long lines]
Signed-off-by: Scott Wood <scottwood@freescale.com>
10 years agomtd: nand: omap: fix ecc-layout for HAM1 ecc-scheme
pekon gupta [Thu, 5 Dec 2013 12:24:21 +0000 (17:54 +0530)]
mtd: nand: omap: fix ecc-layout for HAM1 ecc-scheme

As per OMAP3530 TRM referenced below [1]

For large-page NAND, ROM code expects following ecc-layout for HAM1 ecc-scheme
 - OOB[1] (offset of 1 *byte* from start of OOB) for x8 NAND device
 - OOB[2] (offset of 1 *word* from start of OOB) for x16 NAND device

Thus ecc-layout expected by ROM code for HAM1 ecc-scheme is:
 *for x8 NAND Device*
 +--------+---------+---------+---------+---------+---------+---------+
 | xxxx   | ECC[A0] | ECC[A1] | ECC[A2] | ECC[B0] | ECC[B1] | ECC[B2] | ...
 +--------+---------+---------+---------+---------+---------+---------+

 *for x16 NAND Device*
 +--------+--------+---------+---------+---------+---------+---------+---------+
 | xxxxx  | xxxxx  | ECC[A0] | ECC[A1] | ECC[A2] | ECC[B0] | ECC[B1] | ECC[B2] |
 +--------+--------+---------+---------+---------+---------+---------+---------+

This patch fixes ecc-layout *only* for HAM1, as required by ROM-code
For other ecc-schemes like (BCH8) ecc-layout is same for x8 or x16 devices.

[1] OMAP3530: http://www.ti.com/product/omap3530
    TRM: http://www.ti.com/litv/pdf/spruf98x
Chapter-25: Initialization Sub-topic: Memory Booting
Section: 25.4.7.4 NAND
Figure 25-19. ECC Locations in NAND Spare Areas

Reported-by: Stefan Roese <sr@denx.de>
Signed-off-by: Pekon Gupta <pekon@ti.com>
Tested-by: Stefan Roese <sr@denx.de>
10 years agoPrepare v2014.01-rc2 v2014.01-rc2
Tom Rini [Mon, 16 Dec 2013 18:07:05 +0000 (13:07 -0500)]
Prepare v2014.01-rc2

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoMerge branch 'master' of git://git.denx.de/u-boot-video
Tom Rini [Mon, 16 Dec 2013 14:30:52 +0000 (09:30 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-video

10 years agoMerge branch 'master' of git://git.denx.de/u-boot-blackfin
Tom Rini [Mon, 16 Dec 2013 14:13:25 +0000 (09:13 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-blackfin

10 years agoMakefile, .gitignore: Cleanup non-existing binaries
Masahiro Yamada [Fri, 6 Dec 2013 07:34:10 +0000 (16:34 +0900)]
Makefile, .gitignore: Cleanup non-existing binaries

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoexamples: x86: delete 82559_eeprom
Masahiro Yamada [Fri, 6 Dec 2013 07:34:09 +0000 (16:34 +0900)]
examples: x86: delete 82559_eeprom

Commit fea25720 renamed arch/i386 to arch/x86.
But it missed to modify examples/standalone/Makefile.

Since then, examples/standalone/82559_eeprom has
never compiled and nobody has noticed that.

After some discussion on ML, we agreed to delete this example.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: Select objects by CONFIG_ rather than $(ARCH) or $(CPU)
Masahiro Yamada [Thu, 28 Nov 2013 03:09:59 +0000 (12:09 +0900)]
Makefile: Select objects by CONFIG_ rather than $(ARCH) or $(CPU)

Convert like follows:

 CPU mpc83xx  -> CONFIG_MPC83xx
 CPU mpc85xx  -> CONFIG_MPC85xx
 CPU mpc86xx  -> CONFIG_MPC86xx
 CPU mpc5xxx  -> CONFIG_MPC5xxx
 CPU mpc8xx   -> CONFIG_8xx
 CPU mpc8260  -> CONFIG_8260
 CPU ppc4xx   -> CONFIG_4xx
 CPU x86      -> CONFIG_X86
 ARCH x86     -> CONFIG_X86
 ARCH powerpc -> CONFIG_PPC

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: delete unnecessary lines
Masahiro Yamada [Fri, 29 Nov 2013 00:43:57 +0000 (09:43 +0900)]
Makefile: delete unnecessary lines

REMOTE_BUILD is not used any more.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoREADME.vxworks: add a document describing the new VxWorks boot interface
Miao Yan [Thu, 28 Nov 2013 09:51:40 +0000 (17:51 +0800)]
README.vxworks: add a document describing the new VxWorks boot interface

Signed-off-by: Miao Yan <miao.yan@windriver.com>
10 years agocommon/fdt_support.c: avoid unintended return from fdt_fixup_memory_banks()
Miao Yan [Thu, 28 Nov 2013 09:51:39 +0000 (17:51 +0800)]
common/fdt_support.c: avoid unintended return from fdt_fixup_memory_banks()

fdt_fixup_memory_banks() will add and update /memory node in
device tree blob. In the case that /memory node doesn't exist,
after adding a new one, this function returns error.

The correct behavior should be continuing to update its properties.

Signed-off-by: Miao Yan <miao.yan@windriver.com>
10 years agocommon/cmd_bootm: extend do_bootm_vxworks to support the new VxWorks boot interface.
Miao Yan [Thu, 28 Nov 2013 09:51:38 +0000 (17:51 +0800)]
common/cmd_bootm: extend do_bootm_vxworks to support the new VxWorks boot interface.

The next version VxWorks adopts device tree (for PowerPC and ARM) as its hardware
description mechanism. For PowerPC, the boot interface conforms to
the ePAPR standard, which is:

   void (*kernel_entry)(ulong fdt_addr,
          ulong r4 /* 0 */,
          ulong r5 /* 0 */,
          ulong r6 /* EPAPR_MAGIC */, ulong r7 /* IMA size */,
          ulong r8 /* 0 */, ulong r9 /* 0 */)

For ARM, the boot interface is:

   void (*kernel_entry)(void *fdt_addr)

Signed-off-by: Miao Yan <miao.yan@windriver.com>
[trini: Fix build error when !CONFIG_OF_FDT is set, typo on PowerPC,
missing extern ft_fixup_num_cores]
Signed-off-by: Tom Rini <trini@ti.com>
10 years agoblackfin: remove build warning
Sonic Zhang [Mon, 9 Dec 2013 06:55:21 +0000 (14:55 +0800)]
blackfin: remove build warning

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: fixing warning by including proper headers
Sonic Zhang [Mon, 9 Dec 2013 04:56:27 +0000 (12:56 +0800)]
blackfin: fixing warning by including proper headers

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: fix building error by enlarging the memory size
Sonic Zhang [Mon, 9 Dec 2013 04:45:29 +0000 (12:45 +0800)]
blackfin: fix building error by enlarging the memory size

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: Disable commands to reduce l1 ram requirement
Sonic Zhang [Mon, 9 Dec 2013 04:38:56 +0000 (12:38 +0800)]
blackfin: Disable commands to reduce l1 ram requirement

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: fix building error by adding macro CONFIG_SYS_I2C
Sonic Zhang [Mon, 9 Dec 2013 04:21:07 +0000 (12:21 +0800)]
blackfin: fix building error by adding macro CONFIG_SYS_I2C

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: fix build error by adding CONFIG_BFIN_SERIAL
Sonic Zhang [Mon, 9 Dec 2013 04:19:38 +0000 (12:19 +0800)]
blackfin: fix build error by adding CONFIG_BFIN_SERIAL

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agocommon/config_defaults.h: make CONFIG_BOOTM_VXWORKS default configuration
Miao Yan [Thu, 28 Nov 2013 09:51:37 +0000 (17:51 +0800)]
common/config_defaults.h: make CONFIG_BOOTM_VXWORKS default configuration

Signed-off-by: Miao Yan <miao.yan@windriver.com>
10 years agocommon/cmd_bootm.c: seperate do_bootm_vxworks related code from CONFIG_CMD_ELF.
Miao Yan [Thu, 28 Nov 2013 09:51:36 +0000 (17:51 +0800)]
common/cmd_bootm.c: seperate do_bootm_vxworks related code from CONFIG_CMD_ELF.

do_bootm_vxworks now is available under the configuration option
CONFIG_BOOTM_VXWORKS, thus aligned with other operating systems
that supported by bootm command. The bootvx command still depneds
on CONFIG_CMD_ELF.

Signed-off-by: Miao Yan <miao.yan@windriver.com>
10 years agoMakefile: delete unnecessary CPPFLAGS settings
Masahiro Yamada [Thu, 28 Nov 2013 09:31:59 +0000 (18:31 +0900)]
Makefile: delete unnecessary CPPFLAGS settings

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: Move some scripts imported from Linux
Masahiro Yamada [Thu, 28 Nov 2013 07:29:23 +0000 (16:29 +0900)]
Makefile: Move some scripts imported from Linux

We have some scripts imported from Linux Kernel:
setlocalversion, checkstack.pl, checkpatch.pl, cleanpatch

They are located under tools/ directory in U-Boot now.
But they were originally located under scripts/ directory
in Linux Kernel.

This commit moves them to the original location.

It is true that binutils-version.sh and dtc-version.sh
do not originate in Linux Kernel, but they should
be moved by analogy to gcc-version.sh.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agodrivers/mtd: descend into sub directories only when it is necessary
Masahiro Yamada [Thu, 28 Nov 2013 03:22:17 +0000 (12:22 +0900)]
drivers/mtd: descend into sub directories only when it is necessary

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agodrivers/usb/gadget: select objects by obj-$(CONFIG-...)
Masahiro Yamada [Thu, 28 Nov 2013 03:20:14 +0000 (12:20 +0900)]
drivers/usb/gadget: select objects by obj-$(CONFIG-...)

Before switching to the real Kbuild, drivers/usb/gadget/Makefile
must be fixed.
If none of CONFIG_USB_GADGET, CONFIG_USB_ETHER, CONFIG_USB_DEVICE
is defined, both obj- and obj-y get empty.

We need non-empty obj- or obj-y on each Makefile
to generate built-in.o on the real Kbuild.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agopost: descend only when CONFIG_HAS_POST is defined
Masahiro Yamada [Thu, 28 Nov 2013 03:09:58 +0000 (12:09 +0900)]
post: descend only when CONFIG_HAS_POST is defined

All objects under post/ directory are enabled by CONFIG_HAS_POST.
(post/tests.o is enabled by CONFIG_POST_STD_LIST.
But CONFIG_POST_STD_LIST depends on CONFIG_HAS_POST.)

We can move CONFIG_HAS_POST switch to the top Makefile.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: delete a make rule of $(LDSCRIPT)
Masahiro Yamada [Thu, 28 Nov 2013 02:06:03 +0000 (11:06 +0900)]
Makefile: delete a make rule of $(LDSCRIPT)

$(LDSCRIPT) is a source file, not a generated file.
We do not need a make rule of $(LDSCRIPT).

And one more trivial fix:
$(obj)/u-boot should not dierectly depend on $(LDSCRIPTS).

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoboard_f: explicitly disable console on early boot
Alexey Brodkin [Wed, 27 Nov 2013 18:32:40 +0000 (22:32 +0400)]
board_f: explicitly disable console on early boot

If U-Boot build with DEBUG enabled/defined the first call of "debug"
function (that dumps data to any available console) will happen before
zeroing of initial "gd" in init call "zero_global_data" in
"init_sequence_f".

And if stack was not filled with zeros chances are high that
"gd->have_console" won't be 0. In its turn it will cause attempt to
output things to non-initialized yet serial console.

So for safety and predictability we set "gd->have_console = 0".

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Mischa Jonker <mjonker@synopsys.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Acked-by: Simon Glass <sjg@chromium.org>
10 years agoCorrect vxWorks elf boot to load at correct address
Stany MARCEL [Wed, 27 Nov 2013 13:48:43 +0000 (14:48 +0100)]
Correct vxWorks elf boot to load at correct address

argv[0] contains bootvx (command name) not the load address, if called with
argv < 2 use load_addr, else use address argument given to the command.

Signed-off-by: Stany MARCEL <smarcel@novasys-ingenierie.com>
10 years ago.gitignore: ignore spl/ and tpl/ directories except spl/Makefile
Masahiro Yamada [Tue, 26 Nov 2013 09:05:45 +0000 (18:05 +0900)]
.gitignore: ignore spl/ and tpl/ directories except spl/Makefile

Before this commit, output files under tpl/ directry
were not ignored.
This commit fixes this problem.

And we have only one source file under spl/ directory:
 spl/Makefile

So, we can describe .gitignore more simply.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoPowerPC: merge commonly-defined flags
Masahiro Yamada [Tue, 26 Nov 2013 01:53:58 +0000 (10:53 +0900)]
PowerPC: merge commonly-defined flags

PLATFORM_RELFLAGS += -meabi
PLATFORM_CPPFLAGS += -ffixed-r2
were defined in all arch/powerpc/${CPU}/config.mk.

This commit moves them to arch/powerpc/config.mk.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agonetbsd:fix documentation typo.
Kees Jongenburger [Thu, 12 Dec 2013 15:18:35 +0000 (16:18 +0100)]
netbsd:fix documentation typo.

The documentation suggested the arguments where passed over r3-r6
while the code below simply does that over r0-r3.

Cc: Kumar Gala <galak@kernel.crashing.org>
10 years agospl/Makefile: merge LIBS-y += arch/$(ARCH)/imx-common
Masahiro Yamada [Wed, 11 Dec 2013 01:00:08 +0000 (10:00 +0900)]
spl/Makefile: merge LIBS-y += arch/$(ARCH)/imx-common

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoyaffs2: Use lldiv for 64bit division
Tom Rini [Thu, 5 Dec 2013 19:48:39 +0000 (14:48 -0500)]
yaffs2: Use lldiv for 64bit division

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoJFFS2: Correct jffs2_1pass_build_lists to use lldiv
Tom Rini [Thu, 5 Dec 2013 19:48:38 +0000 (14:48 -0500)]
JFFS2: Correct jffs2_1pass_build_lists to use lldiv

Since part_info size became 64bit we need to use lldiv here.

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoARM:PXA: Correct tick_to_time / us_to_tick to use lldiv
Tom Rini [Thu, 5 Dec 2013 19:48:37 +0000 (14:48 -0500)]
ARM:PXA: Correct tick_to_time / us_to_tick to use lldiv

Cc: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Tom Rini <trini@ti.com>
Acked-by: Marek Vasut <marex@denx.de>
10 years agoARM:zynq: Correct __udelay to use lldiv
Tom Rini [Thu, 5 Dec 2013 19:48:36 +0000 (14:48 -0500)]
ARM:zynq: Correct __udelay to use lldiv

Cc: Michal Simek <monstr@monstr.eu>
Signed-off-by: Tom Rini <trini@ti.com>
10 years agotime: fix usec_to_tick()
Stephen Warren [Thu, 5 Dec 2013 19:08:09 +0000 (12:08 -0700)]
time: fix usec_to_tick()

Commit 8dfafdde88eb ("Introduce common timer functions") created a
common definition of usec_to_tick() which had a couple problems:

static unsigned long long usec_to_tick(unsigned long usec)
{
       uint64_t tick = usec * get_tbclk();

That likely overflows.

       usec *= get_tbclk();

That was an attempt to fix it by performing the multiply after the
promotion of usec to 64-bit, but was applied to the wrong variable,
which was never used.

This patch fixes these issues. A user-visible symptom of the problem was
the e.g. "dhcp zImage" using an ASIX USB Ethernet dongle would print:

Waiting for Ethernet connection... unable to connect.

... with no delay before "unable to connect". There are likely other
symptoms.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Rob Herring <rob.herring@calxeda.com>
10 years agoMakefile: correct dependencies of asm-offsets.[hs]
Masahiro Yamada [Thu, 5 Dec 2013 06:30:18 +0000 (15:30 +0900)]
Makefile: correct dependencies of asm-offsets.[hs]

These four generated files depends on neither {spl,tpl}-autoconf.mk
nor autoconf.mk.dep.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: use two double-quotations as a pair
Masahiro Yamada [Thu, 5 Dec 2013 06:08:31 +0000 (15:08 +0900)]
Makefile: use two double-quotations as a pair

Some editors such as Emacs can highlight source files.
But their parser algorithm is not perfect.

If you use one double-quotation alone, some editor cannot
handle it nicely and mark source lines as a string by mistake.

It is preferable to use two double-quotations as a pair.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agoMakefile: Do not create empty autoconf.mk on error
Masahiro Yamada [Mon, 2 Dec 2013 05:57:29 +0000 (14:57 +0900)]
Makefile: Do not create empty autoconf.mk on error

The build rules of
  - include/autoconf.mk.dep
  - include/autoconf.mk
  - include/spl-autoconf.mk
  - include/tpl-autoconf.mk
were not nice.

They created empty files (which are never updated)
if an error occurs during preprocessing.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
10 years agosandbox: dumpimage: Test dumpimage
Guilherme Maciel Ferreira [Sun, 1 Dec 2013 19:43:12 +0000 (12:43 -0700)]
sandbox: dumpimage: Test dumpimage

Add a test for dumpimage.

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agoAdd dumpimage, a tool to extract data from U-Boot images
Guilherme Maciel Ferreira [Sun, 1 Dec 2013 19:43:11 +0000 (12:43 -0700)]
Add dumpimage, a tool to extract data from U-Boot images

Given a multi-file image created through the mkimage's -d option:

  $ mkimage -A x86 -O linux -T multi -n x86 -d vmlinuz:initrd.img:System.map \
  multi.img

  Image Name:   x86
  Created:      Thu Jul 25 10:29:13 2013
  Image Type:   Intel x86 Linux Multi-File Image (gzip compressed)
  Data Size:    13722956 Bytes = 13401.32 kB = 13.09 MB
  Load Address: 00000000
  Entry Point:  00000000
  Contents:
     Image 0: 4040128 Bytes = 3945.44 kB = 3.85 MB
     Image 1: 7991719 Bytes = 7804.41 kB = 7.62 MB
     Image 2: 1691092 Bytes = 1651.46 kB = 1.61 MB

It is possible to perform the innverse operation -- extracting any file from
the image -- by using the dumpimage's -i option:

  $ dumpimage -i multi.img -p 2 System.map

Although it's feasible to retrieve "data files" from image through scripting,
the requirement to embed tools such 'dd', 'awk' and 'sed' for this sole purpose
is cumbersome and unreliable -- once you must keep track of file sizes inside
the image. Furthermore, extracting data files using "dumpimage" tool is faster
than through scripting.

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agotools: moved code common to all image tools to a separated module.
Guilherme Maciel Ferreira [Sun, 1 Dec 2013 19:43:10 +0000 (12:43 -0700)]
tools: moved code common to all image tools to a separated module.

In order to avoid duplicating code and keep only one point of modification,
the functions, structs and defines useful for "dumpimage" were moved from
"mkimage" to a common module called "imagetool".

This modification also weakens the coupling between image types (FIT, IMX, MXS,
and so on) and image tools (mkimage and dumpimage). Any tool may initialize the
"imagetool" through register_image_tool() function, while the image types
register themselves within an image tool using the register_image_type()
function:

                                                      +---------------+
                                               +------|   fit_image   |
 +--------------+          +-----------+       |      +---------------+
 |    mkimage   |--------> |           | <-----+
 +--------------+          |           |              +---------------+
                           | imagetool | <------------|    imximage   |
 +--------------+          |           |              +---------------+
 |  dumpimage   |--------> |           | <-----+
 +--------------+          +-----------+       |      +---------------+
                                               +------| default_image |
                                                      +---------------+

          register_image_tool()           register_image_type()

Also, the struct "mkimage_params" was renamed to "image_tool_params" to make
clear its general purpose.

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agomkimage: added 'static' specifier to match function's prototype.
Guilherme Maciel Ferreira [Sun, 1 Dec 2013 19:43:09 +0000 (12:43 -0700)]
mkimage: added 'static' specifier to match function's prototype.

This function should be declared static.

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agokgdb: configs: remove obsolete CONFIG_KGDB_SER_INDEX
Vladimir Zapolskiy [Sun, 1 Dec 2013 18:07:28 +0000 (20:07 +0200)]
kgdb: configs: remove obsolete CONFIG_KGDB_SER_INDEX

The last users of CONFIG_KGDB_SER_INDEX were removed more than 3 years
ago in commits 550650ddd0 and bf16500f79, either kgdb subsystem should
care about this parameter or it should be gone completely.

Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
10 years agoserial: lpc32xx: send CR before LF
Vladimir Zapolskiy [Sat, 30 Nov 2013 14:47:01 +0000 (16:47 +0200)]
serial: lpc32xx: send CR before LF

For LPC32XX high-speed UART it is required to send a carriage return
symbol along with line feed. The problem was introduced in e503f90a
commit.

Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
Cc: Marek Vasut <marex@denx.de>
Acked-by: Marek Vasut <marex@denx.de>
10 years agopowerpc/mpc85xx: Update CONFIG_SYS_FSL_TBCLK_DIV for T1040
Prabhakar Kushwaha [Wed, 11 Dec 2013 07:19:13 +0000 (12:49 +0530)]
powerpc/mpc85xx: Update CONFIG_SYS_FSL_TBCLK_DIV for T1040

The default value of CONFIG_SYS_FSL_TBCLK_DIV is 16.

So, update its value as default.

Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com>
Acked-by: York Sun <yorksun@freescale.com>
10 years agopowerpc/p1_p2_rdb_pc: Fix warnings for __iomem pointers
Claudiu Manoil [Tue, 10 Dec 2013 09:22:22 +0000 (11:22 +0200)]
powerpc/p1_p2_rdb_pc: Fix warnings for __iomem pointers

Add the __iomem address space marker for the tsec pointers
to struct tsec_mii_mng memory mapped register regions.
This solves the sparse warnings for mixig normal pointers with
__iomem pointers for tsec.

p1_p2_rdb_pc.c:373:24: warning: incorrect type in assignment (different
address spaces)
p1_p2_rdb_pc.c:373:24:    expected struct tsec_mii_mng [noderef]
<asn:2>*regs
p1_p2_rdb_pc.c:373:24:    got struct tsec_mii_mng *<noident>

Use TSEC_GET_MDIO_REGS_BASE() for the remaining mdio 'regs'
initializations to remove the __iomem warnings and for consistency.

Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com>
Acked-by: York Sun <yorksun@freescale.com>
10 years agonet/fman: add ft_fixup_xgec to support 3rd and 4th 10GEC
Shengzhou Liu [Mon, 2 Dec 2013 02:23:11 +0000 (10:23 +0800)]
net/fman: add ft_fixup_xgec to support 3rd and 4th 10GEC

As mEMAC1 and mEMAC2 are dual-role MACs, which are used as 1G or 10G MAC.
So we update dynamically 'cell-index' to '2' and '3' for 10GEC3 and 10GEC4.
Also change 'fsl,fman-port-1g-rx' to 'fsl,fman-port-10g-rx', ditto for Tx.

Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com>
Acked-by: York Sun <yorksun@freescale.com>
10 years agopowerpc/t4240: Add a frequency setting case for fman1
Shaohui Xie [Thu, 28 Nov 2013 05:52:51 +0000 (13:52 +0800)]
powerpc/t4240: Add a frequency setting case for fman1

A new valid setting case added for fman1, it uses platform frequency.

Signed-off-by: Shaohui Xie <Shaohui.Xie@freescale.com>
Acked-by: York Sun <yorksun@freescale.com>
10 years agoMerge branch 'master' of git://git.denx.de/u-boot-arm
Tom Rini [Tue, 10 Dec 2013 22:15:18 +0000 (17:15 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-arm

Conflicts:
board/samsung/trats2/trats2.c
include/configs/exynos5250-dt.h

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoMerge branch 'u-boot/master' into 'u-boot-arm/master'
Albert ARIBAUD [Tue, 10 Dec 2013 13:31:56 +0000 (14:31 +0100)]
Merge branch 'u-boot/master' into 'u-boot-arm/master'

Conflicts:
arch/arm/cpu/armv7/rmobile/Makefile
doc/README.scrapyard

Needed manual fix:
arch/arm/cpu/armv7/omap-common/Makefile
board/compulab/cm_t335/u-boot.lds

10 years agoMerge branch 'spi' of git://git.denx.de/u-boot-x86
Tom Rini [Tue, 10 Dec 2013 14:36:23 +0000 (09:36 -0500)]
Merge branch 'spi' of git://git.denx.de/u-boot-x86

10 years agoMerge branch 'master' of git://git.denx.de/u-boot-mmc
Tom Rini [Tue, 10 Dec 2013 14:33:13 +0000 (09:33 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-mmc

10 years agoMerge branch 'master' of git://git.denx.de/u-boot-i2c
Tom Rini [Tue, 10 Dec 2013 14:29:45 +0000 (09:29 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-i2c

10 years agovexpress: use correct timer address on extended memory map systems
Ian Campbell [Sun, 17 Nov 2013 15:17:42 +0000 (15:17 +0000)]
vexpress: use correct timer address on extended memory map systems

Signed-off-by: Ian Campbell <ijc@hellion.org.uk>
Cc: albert.u.boot@aribaud.net
10 years agoserial: zynq: Remove unused #defines
Soren Brinkmann [Wed, 30 Oct 2013 14:49:32 +0000 (15:49 +0100)]
serial: zynq: Remove unused #defines

Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
10 years agosandbox: spi: Enable new spi/sf layers
Mike Frysinger [Tue, 3 Dec 2013 23:43:28 +0000 (16:43 -0700)]
sandbox: spi: Enable new spi/sf layers

We want to test SPI flash code in the sandbox, so enable the new drivers and
the 'sf test' command.

This command is used to validate the sandbox SPI / SPI flash implementation,
so enable it.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agosandbox: spi: Add new SPI flash driver
Mike Frysinger [Tue, 3 Dec 2013 23:43:27 +0000 (16:43 -0700)]
sandbox: spi: Add new SPI flash driver

This adds a SPI flash driver which simulates SPI flash clients.
Currently supports the bare min that U-Boot requires: you can
probe, read, erase, and write.  Should be easy to extend to make
it behave more exactly like a real SPI flash, but this is good
enough to merge now.

sjg@chromium.org added a README and tidied up code a little.
Added a required map_sysmem() for sandbox.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agosandbox: spi: Add SPI emulation bus
Mike Frysinger [Tue, 3 Dec 2013 23:43:26 +0000 (16:43 -0700)]
sandbox: spi: Add SPI emulation bus

This adds a SPI framework for people to hook up simulated SPI clients.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agospi: Add device tree binding for SPI bus
Simon Glass [Tue, 3 Dec 2013 23:43:25 +0000 (16:43 -0700)]
spi: Add device tree binding for SPI bus

This was obtained from Linux 3.12 commit 5e01dc7b26.

Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agospi_flash: Add spi_flash_probe_fdt() to locate SPI by FDT node
Simon Glass [Tue, 3 Dec 2013 23:43:24 +0000 (16:43 -0700)]
spi_flash: Add spi_flash_probe_fdt() to locate SPI by FDT node

This allows us to put the SPI flash chip inside the SPI interface node,
with U-Boot finding the correct bus and chip select automatically.

Signed-off-by: Simon Glass <sjg@chromium.org>
10 years agosandbox: Rename sb_cmdline_option to sandbox_cmdline_option
Simon Glass [Tue, 3 Dec 2013 23:43:23 +0000 (16:43 -0700)]
sandbox: Rename sb_cmdline_option to sandbox_cmdline_option

The new name is longer but more clearly related to sandbox.

This is in a separate patch within the same series since some comments on the
SPI series rely on it.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Hung-ying Tyan <tyanh@chromium.org>
10 years agoarm: at91: support for the Calao USB-A9263 board (based on AT91SAM9263)
Mateusz Kulikowski [Mon, 2 Dec 2013 22:30:58 +0000 (23:30 +0100)]
arm: at91: support for the Calao USB-A9263 board (based on AT91SAM9263)

Add support for USB-A9263 board manufactured by Calao Systems
(http://www.calao-systems.com/).
Code is based on old U-Boot sources (2010.09) released by Calao.

Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com>
Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
10 years agoarm, at91: add siemens corvus board
Heiko Schocher [Mon, 2 Dec 2013 06:47:23 +0000 (07:47 +0100)]
arm, at91: add siemens corvus board

enable support for the siemens AT91SAM9G20 based board corvus.

Signed-off-by: Boris Schmidt <boris.schmidt@siemens.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
Cc: Andreas Bießmann <andreas.devel@googlemail.com>
Cc: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
10 years agoarm, at91: add Siemens board taurus and axm
Heiko Schocher [Mon, 2 Dec 2013 06:47:22 +0000 (07:47 +0100)]
arm, at91: add Siemens board taurus and axm

enable support for the siemens AT91SAM9G20 based boards taurus
and axm.

Signed-off-by: Roger Meier <r.meier@siemens.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
Cc: Andreas Bießmann <andreas.devel@googlemail.com>
Cc: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
10 years agoat91: switch coloured LED to gpio API
Andreas Bießmann [Fri, 29 Nov 2013 11:13:46 +0000 (12:13 +0100)]
at91: switch coloured LED to gpio API

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
10 years agoat91: nand: switch atmel_nand to generic GPIO API
Andreas Bießmann [Fri, 29 Nov 2013 11:13:45 +0000 (12:13 +0100)]
at91: nand: switch atmel_nand to generic GPIO API

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
Acked-by: Jens Scharsig (BuS Elektronik)<esw@bus-elektronik.de>
Tested-by: Jens Scharsig (BuS Elektronik)<esw@bus-elektronik.de>
Acked-by: Scott Wood <scottwood@freescale.com>
10 years agoat91: redefine legacy GPIO PIN_BASE
Andreas Bießmann [Fri, 29 Nov 2013 11:13:44 +0000 (12:13 +0100)]
at91: redefine legacy GPIO PIN_BASE

In order to get the very same value for legacy pin definitions and new gpio
definitions set the legacy PIN_BASE to 0.

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
10 years agoat91: add new gpio pin definitions
Andreas Bießmann [Fri, 29 Nov 2013 11:13:43 +0000 (12:13 +0100)]
at91: add new gpio pin definitions

This patch define new names for GPIO pins on at91 devices. Follow up patches
will convert the whole infrastructure to use these new definitions.

Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
Tested-by: Bo Shen <voice.shen@atmel.com>
10 years agommc: add Faraday FTSDC021 SDHCI controller support
Kuo-Jung Su [Mon, 25 Nov 2013 02:51:41 +0000 (10:51 +0800)]
mmc: add Faraday FTSDC021 SDHCI controller support

Faraday FTSDC021 is a controller which is compliant with
SDHCI v3.0, SDIO v2.0 and MMC v4.3.

However this driver is only verified with SD memory cards.

Signed-off-by: Kuo-Jung Su <dantesu@faraday-tech.com>
Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
CC: Andy Fleming <afleming@gmail.com>
10 years agopowerpc: mmc: Add corenet devices support in esdhc spl
Priyanka Jain [Thu, 28 Nov 2013 04:42:16 +0000 (10:12 +0530)]
powerpc: mmc: Add corenet devices support in esdhc spl

Existing eSDHC SPL framework assumes booting from sd-image
with boot_format header which contains final u-boot Image
offset and size. No such header is present in case of
corenet devices like T1040 as corenet deivces use PBI-RCW
based intialization.

So, for corenet deives, SPL bootloader use values provided
at compilation time. These values can be defined in board
specific config file.

Signed-off-by: Priyanka Jain <Priyanka.Jain@freescale.com>
Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
10 years agommc/dwmmc: modify FIFO threshold only if value explicitly set
Alexey Brodkin [Wed, 27 Nov 2013 13:00:52 +0000 (17:00 +0400)]
mmc/dwmmc: modify FIFO threshold only if value explicitly set

If platform provides "host->fifoth_val" it will be used for
initialization of DWMCI_FIFOTH register. Otherwise default value will be
used.

This implementation allows:
 * escape unclear and recursive calculations that are currently in use
 * use whatever custom value for DWMCI_FIFOTH initialization if any
particular SoC requires it

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Mischa Jonker <mjonker@synopsys.com>
Cc: Alim Akhtar <alim.akhtar@samsung.com>
Cc: Rajeshwari Shinde <rajeshwari.s@samsung.com>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
Cc: Amar <amarendra.xt@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Minkyu Kang <mk7.kang@samsung.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Pantelis Antoniou <panto@antoniou-consulting.com>
Cc: Andy Fleming <afleming@freescale.com>
Acked-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
10 years agommc: dw_mmc: remove the exynos specific code in dw-mmc.c
Jaehoon Chung [Fri, 29 Nov 2013 11:08:57 +0000 (20:08 +0900)]
mmc: dw_mmc: remove the exynos specific code in dw-mmc.c

dw-mmc.c is the general driver file.
So, remove the exynos specific code at dw-mmc.c.
Instead, exynos specific cod can be move into exynos-dw_mmc.c.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Acked-by: Minkyu Kang <mk7.kang@samsung.com>
10 years agoarm: keep all sections in ELF file
Albert ARIBAUD [Thu, 7 Nov 2013 13:21:46 +0000 (14:21 +0100)]
arm: keep all sections in ELF file

Current LDS files /DISCARD/ a lot of sections when linking ELF
files, causing diagnostic tools such as readelf or objdump to
produce partial output. Keep all section at link stage, filter
only at objcopy time so that .bin remains minimal.

Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Reviewed-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
10 years agoARM: align MVBAR on 32 byte boundary
Masahiro Yamada [Mon, 7 Oct 2013 02:46:56 +0000 (11:46 +0900)]
ARM: align MVBAR on 32 byte boundary

The lower 5 bit of MVBAR is UNK/SBZP.
So, Monitor Vector Base Address must be 32-byte aligned.
On the other hand, the secure monitor handler does not need
32-byte alignment.

This commit moves ".algin 5" directive to the correct place.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Andre Przywara <andre.przywara@linaro.org>
Acked-by: Andre Przywara <andre.przywara@linaro.org>
10 years agoMerge branch 'u-boot-samsung/master' into 'u-boot-arm/master'
Albert ARIBAUD [Fri, 6 Dec 2013 15:54:42 +0000 (16:54 +0100)]
Merge branch 'u-boot-samsung/master' into 'u-boot-arm/master'

10 years agoMerge branch 'u-boot-ti/master' into 'u-boot-arm/master'
Albert ARIBAUD [Fri, 6 Dec 2013 13:26:51 +0000 (14:26 +0100)]
Merge branch 'u-boot-ti/master' into 'u-boot-arm/master'

10 years agoMerge branch 'master' of git://git.denx.de/u-boot-blackfin
Tom Rini [Fri, 6 Dec 2013 12:19:09 +0000 (07:19 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-blackfin

10 years agoAM3517 EVM: Enable ethernet
Tom Rini [Tue, 6 Dec 2011 15:49:41 +0000 (08:49 -0700)]
AM3517 EVM: Enable ethernet

Signed-off-by: Tom Rini <trini@ti.com>
10 years agoomap4_panda: Don't use ulpi_reset
Roger Quadros [Mon, 2 Dec 2013 13:47:45 +0000 (15:47 +0200)]
omap4_panda: Don't use ulpi_reset

Fixes this error message when USB is started.
"ULPI: ulpi_reset: failed writing reset bit"

It is pointless to manually reset the ULPI as the USB Host
Reset and PHY RESET line should take care of that.

Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Roger Quadros <rogerq@ti.com>
10 years agoomap3_beagle: Don't use ulpi_reset
Roger Quadros [Mon, 2 Dec 2013 13:47:44 +0000 (15:47 +0200)]
omap3_beagle: Don't use ulpi_reset

Fixes this error message when USB is started.
"ULPI: ulpi_reset: failed writing reset bit"

It is pointless to manually reset the ULPI as the USB Host
Reset and PHY RESET line should take care of that.

Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Roger Quadros <rogerq@ti.com>
10 years agousb: ehci-omap: Reset the USB Host OMAP module
Roger Quadros [Mon, 2 Dec 2013 13:47:43 +0000 (15:47 +0200)]
usb: ehci-omap: Reset the USB Host OMAP module

In commit bb1f327 we removed the UHH reset to fix NFS root (over usb
ethernet) problems with Beagleboard (3530 ES1.0). However, this
seems to cause USB detection problems for Pandaboard, about (3/8).

On further investigation, it seems that doing the UHH reset is not
the cause of the original Beagleboard problem, but in the way the reset
was done.

This patch adds proper UHH RESET mechanism for OMAP3 and OMAP4/5 based
on the UHH_REVISION register. This should fix the Beagleboard NFS
problem as well as the Pandaboard USB detection problem.

Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
CC: Stefan Roese <sr@denx.de>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Roger Quadros <rogerq@ti.com>
10 years agoarm: omap3: Enable clocks for peripherals only if they are used
Michael Trimarchi [Sat, 30 Nov 2013 06:59:58 +0000 (07:59 +0100)]
arm: omap3: Enable clocks for peripherals only if they are used

This patch change the per_clocks_enable() function used in OMAP3
code to enable peripherals clocks. Only required clock should be
activated. So if the board use the uart(x) as a console we need
to activate it. The Board's config should include define to enable
every subsystem that the board use. For a complete list
of affected peripherals, registers CM_FCLKEN_PER and CM_ICLKEN_PER
should be checked.
Right now the bootloader can enable and disable clocks for:
uart(x) using CONFIG_SYS_NS16550
gpio bank (x) using CONFIG_OMAP3_GPIO_X with X = { 2, 3, 4, 5, 6 }
i2c bus using CONFIG_DRIVER_OMAP34XX_I2C.

Not required gptimer(x) and mcbsp(x) for booting are disabled by default and
are not supported by any define.
Their activation need to included in the per_clocks_enable if the
peripheral is included. Not booting board should enable the peripheral
clock connected to their driver

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Cc: Tom Rini <trini@ti.com>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
10 years agoarm: arndale: disable spi boot
Minkyu Kang [Fri, 6 Dec 2013 10:18:13 +0000 (19:18 +0900)]
arm: arndale: disable spi boot

arndale board is booted from mmc

Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
Cc: Inderpal Singh <inderpal.singh@linaro.org>
10 years agoarm: exynos: adds ifdef for spi boot
Minkyu Kang [Fri, 6 Dec 2013 10:04:03 +0000 (19:04 +0900)]
arm: exynos: adds ifdef for spi boot

This patch fix following errors and warnings

spl_boot.c: In function 'exynos_spi_copy':
spl_boot.c:111:49: error: 'CONFIG_ENV_SPI_BASE' undeclared (first use in this function)
spl_boot.c:111:49: note: each undeclared identifier is reported only once for each function it appears in
spl_boot.c:142:2: error: 'SPI_FLASH_UBOOT_POS' undeclared (first use in this function)
spl_boot.c: In function 'copy_uboot_to_ram':
spl_boot.c:189:28: warning: unused variable 'param' [-Wunused-variable]
spl_boot.c: At top level:
spl_boot.c:107:13: warning: 'exynos_spi_copy' defined but not used [-Wunused-function]

Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
10 years agoMerge branch 'u-boot-sh/rmobile' into 'u-boot-arm/master'
Albert ARIBAUD [Fri, 6 Dec 2013 09:41:49 +0000 (10:41 +0100)]
Merge branch 'u-boot-sh/rmobile' into 'u-boot-arm/master'

10 years agoblackfin: Do not generate unused header bootrom-asm-offsets.h
Masahiro Yamada [Fri, 29 Nov 2013 06:34:16 +0000 (15:34 +0900)]
blackfin: Do not generate unused header bootrom-asm-offsets.h

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agospi: bfin_spi6xx: Remove unnecessary test for bus and pins[bus]
Axel Lin [Mon, 2 Dec 2013 04:57:44 +0000 (12:57 +0800)]
spi: bfin_spi6xx: Remove unnecessary test for bus and pins[bus]

For invalid bus number, current code returns NULL in the default case of
switch-case statements. In additional, pins[bus] is always not NULL because
it is the address of specific row of the two-dimensional array.
Thus this patch removes these unnecessary test.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Scott Jiang <scott.jiang.linux@gmail.com>
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agospi: bfin_spi: Remove unnecessary test for bus and pins[bus]
Axel Lin [Mon, 2 Dec 2013 04:57:33 +0000 (12:57 +0800)]
spi: bfin_spi: Remove unnecessary test for bus and pins[bus]

For invalid bus number, current code returns NULL in the default case of
switch-case statements. In additional, pins[bus] is always not NULL because
it is the address of specific row of the two-dimensional array.
Thus this patch removes these unnecessary test.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Scott Jiang <scott.jiang.linux@gmail.com>
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: soft-i2c: No need to define blackfin specific soft i2c operations
Sonic Zhang [Mon, 18 Nov 2013 10:59:18 +0000 (18:59 +0800)]
blackfin: soft-i2c: No need to define blackfin specific soft i2c operations

Use default GPIO operations.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Acked-by: Heiko Schocher <hs@denx.de>
10 years agoblackfin: Add missing macro CONFIG_BFIN_SERIAL
Sonic Zhang [Mon, 18 Nov 2013 06:50:19 +0000 (14:50 +0800)]
blackfin: Add missing macro CONFIG_BFIN_SERIAL

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: If none ADI_GPIOX macro is defined, use ADI_GPIO1 as default
Sonic Zhang [Mon, 18 Nov 2013 06:12:39 +0000 (14:12 +0800)]
blackfin: If none ADI_GPIOX macro is defined, use ADI_GPIO1 as default

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoblackfin: Use ADI_GPIO2 driver other than the default ADI_GPIO1
Sonic Zhang [Mon, 18 Nov 2013 06:01:38 +0000 (14:01 +0800)]
blackfin: Use ADI_GPIO2 driver other than the default ADI_GPIO1

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
10 years agoi2c: samsung: register i2c busses for Exynso5420 and Exynos5250
Naveen Krishna Ch [Fri, 6 Dec 2013 06:42:38 +0000 (12:12 +0530)]
i2c: samsung: register i2c busses for Exynso5420 and Exynos5250

This patch adds the U_BOOT_I2C_ADAP_COMPLETE defines for channels
on Exynos5420 and Exynos5250 and also adds support for init function
for hsi2c channels

Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
10 years agoarm: omap: i2c: don't zero cnt in i2c_write
Nikita Kiryanov [Thu, 28 Nov 2013 16:04:42 +0000 (18:04 +0200)]
arm: omap: i2c: don't zero cnt in i2c_write

Writing zero into I2Ci.I2C_CNT register causes random I2C failures in OMAP3
based devices. This seems to be related to the following advisory which
apears in multiple erratas for OMAP3 SoCs (OMAP35xx, DM37xx), as well as
OMAP4430 TRM:

Advisory:
I2C Module Does Not Allow 0-Byte Data Requests
Details:
When configured as the master, the I2C module does not allow 0-byte data
transfers. Note: Programming I2Ci.I2C_CNT[15:0]: DCOUNT = 0 will cause
undefined behavior.
Workaround(s):
No workaround. Do not use 0-byte data requests.

The writes in question are unnecessary from a functional point of view.
Most of them are done after I/O has finished, and the only one that preceds
I/O (in i2c_probe()) is also unnecessary because a stop bit is sent before
actual data transmission takes place.

Therefore, remove all writes that zero the cnt register.

Cc: Heiko Schocher <hs@denx.de>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Tom Rini <trini@ti.com>
Cc: Lubomir Popov <lpopov@mm-sol.com>
Cc: Enric Balletbo Serra <eballetbo@gmail.com>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Tested-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tested-by: Lubomir Popov <lpopov@mm-sol.com>
10 years agocmd_eeprom: bug fix for i2c read/write
Kuo-Jung Su [Mon, 2 Dec 2013 08:02:59 +0000 (16:02 +0800)]
cmd_eeprom: bug fix for i2c read/write

The local pointer of address (i.e., addr) only gets
referenced under SPI mode, and it won't be appropriate
to pass only 1-byte addr[1] to i2c_read/i2c_write while
CONFIG_SYS_I2C_EEPROM_ADDR_LEN > 1.

1. In U-boot's I2C model, the address would be re-assembled
   to a byte string in MSB order inside I2C controller drivers.

2. The 'CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW' option which could
   be found at soft_i2c.c is always turned on in cmd_eeprom.c,
   the addr[0] always contains the device address with overflowed
   MSB address bits.

Signed-off-by: Kuo-Jung Su <dantesu@faraday-tech.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
cc: Peter Tyser <ptyser@xes-inc.com>
Cc: Heiko Schocher <hs@denx.de>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Cc: Mischa Jonker <mjonker@synopsys.com>