Commit Graph

6651 Commits

Author SHA1 Message Date
Simon Glass 9d12d5d41d Add cmd_process() to process commands in one place
We currently have the same code in hush.c and main.c. This brings the
code into one place.

As an added feature, if the command function returns CMD_RET_USAGE then
cmd_process() will print a usage message for the command before
returning the standard failure code of 1.

ARM code size increases about 32 bytes with this clean-up.

Signed-off-by: Simon Glass <sjg@chromium.org>
2012-03-06 21:09:41 +01:00
Simon Glass bdf8e34b93 Create a single cmd_call() function to handle command execution
We should aim for a single point of entry to the commands, whichever
parser is used.

Signed-off-by: Simon Glass <sjg@chromium.org>
2012-03-06 21:09:34 +01:00
Simon Glass 5307153236 Stop using builtin_run_command()
Boards can select either the 'built-in' parser or the hush parser. We
should not call builtin_run_command() if we are using the hush parser.
We use run_command() instead, since it knows how to call the correct
parser.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-03-06 21:09:26 +01:00
Simon Glass 009dde1955 Rename run_command2() to run_command()
This is a more sensible name, so rename it.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-03-06 21:09:22 +01:00
Simon Glass f47360a74e Rename run_command() to builtin_run_command()
The current run_command() is only one of the parsing options - the other
is hush. We should not call run_command() when the hush parser is being
used. So we rename this function to better explain its purpose.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-03-06 21:09:18 +01:00
Simon Glass 79714c1e26 Remove CMD_PXE's static on run_command()
It really isn't clear why this is here and there is no comment, so
drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-03-06 21:09:14 +01:00
Thomas Weber b199c6e2d7 Remove execute permissions from source files
Signed-off-by: Thomas Weber <weber@corscience.de>
2012-03-04 21:56:15 +01:00
Linus Walleij a1e47b66d9 pci: move pciauto_config_init() to pci.h
Fixing build regressions for the Integrator I get find that a few
boards try to work around the missing declaration of
pciauto_config_init() by declaring it in the local scope. This
does not make sense when the sibling functions are in <pci.h>
so move the function to the header, ridding the build error
in the Integrator and getting rid of the local declarations
here and there.

Reported-by:  Wolfgang Denk <wd@denx.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2012-03-04 21:13:33 +01:00
amartin@nvidia.com f9636e8d38 USB: move keyboard polling into kbd driver
This moves keyboard polling logic from USB HCD drivers into USB
keyboard driver.  Remove usb_event_poll() as keyboard polling was
the only user of this API.  With this patch USB keyboard works with
EHCI controllers again.  Tested on a tegra2 seaboard.

Signed-off-by: Allen Martin <amartin@nvidia.com>
2012-03-03 16:56:29 +01:00
Vincent Palatin e7e982d69c eth: remove usb-ethernet devices before re-enumerating them
Fix the crash when running several times usb_init() with a USB ethernet
device plugged.

Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Wolfgang Grandegger <wg@denx.de>
2012-03-03 16:56:04 +01:00
Marek Vasut 23faf2bc9e USB: Separate out USB hub driver
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Cc: Remy Bohmer <linux@bohmer.net>
Acked-by: Mike Frysinger <vapier@gentoo.org>
2012-03-03 16:55:24 +01:00
Wolfgang Denk e91004201c Merge branch 'master' of git://git.denx.de/u-boot-nand-flash
* 'master' of git://git.denx.de/u-boot-nand-flash:
  cmd_nand.c: Fix 'nand dump' after latest MTD resync
  mtd/nand:Fix wrong usage of is_blank() in fsl_ifc_run_command
  mtd/nand: Fix IFC driver to support 2K NAND page
  nand: reinstate lazy bad block scanning
  Revert "nand: make 1-bit software ECC configurable"
2012-03-03 15:15:07 +01:00
Scott Wood fb49454b1b nand: reinstate lazy bad block scanning
commit 2a8e0fc8b3 ("nand: Merge changes
from Linux nand driver") accidentally reverted commit
13f0fd94e3 ("NAND: Scan bad blocks
lazily.").

Reinstate the change, as amended by commit
ff49ea8977 ("NAND: Mark the BBT as scanned
prior to calling scan_bbt.").

Signed-off-by: Scott Wood <scottwood@freescale.com>
2012-02-28 14:03:39 -06:00
Scott Wood 1f7b1743d3 Revert "nand: make 1-bit software ECC configurable"
This reverts commit 4fee6c2f29.

It breaks boards that currently rely on soft-ecc, as pointed out here:
http://patchwork.ozlabs.org/patch/140872/

The reverted patch should be resubmitted with documentation, and with the
CONFIG_MTD_ECC_SOFT selected from every board that needs it.  We could
start by looking at what NAND driver the board selects, and whether
that driver ever asks for soft ECC.

Signed-off-by: Scott Wood <scottwood@freescale.com>
2012-02-28 14:03:39 -06:00
Helmut Raiger 07c80bc232 tt01: fix hush parser config, add release config
Add PREBOOT, SILENT_CONSOLE and DEVICE_NULLDEV for release
build. Fixed bug in CONFIG_SYS_HUSH_PARSER define.

Signed-off-by: Helmut Raiger <helmut.raiger@hale.at>
2012-02-27 21:19:25 +01:00
Helmut Raiger d1300f7686 tt01: add video support
The video setup for the Epson display is provided. Addtionally
some extra info is displayed next to the Linux logo.
Make get_cpu_rev() publicly available (added to sys_proto.h).

Signed-off-by: Helmut Raiger <helmut.raiger@hale.at>
2012-02-27 21:19:25 +01:00
Helmut Raiger 0b87e010f8 tt01: fix environment size
size of environment must match erasable block size in the flash.

Signed-off-by: Helmut Raiger <helmut.raiger@hale.at>
2012-02-27 21:19:25 +01:00
Troy Kisky 2bf3359ea5 i.mx6q: mx6qsabrelite: Update the network configuration
Define CONFIG_PHY_MICREL, and
minimize the tx clock delay.

There is an issue with 1000 baseTx mode on early revs
of the SabreLite boards. The center tap pin 9 of the mag RJ45
USB combo was connected to the 3.3 filtered supply. Letting
this pin float solved the problem. Symptoms of the problem
were packets with many extra zeroes tacked on the end, and random
bit flips causing a high rate of CRC errors. 10/100 baseTx worked
fine on all revs. To disable 1000 baseTx for these boards, simply
define the environment variable disable_giga. ie.

setenv disable_giga 1

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
2012-02-27 21:19:25 +01:00
Troy Kisky 8682aba7da net: phy: add support for Micrel's KSZ9021
Add the gigabit phy KSZ9021.
Also, add function ksz9021_phy_extended_write
/_read for access to the phys extended registers.
The environment variable "disable_giga"
can be used to disable 1000baseTx.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
2012-02-27 21:19:25 +01:00
Linus Walleij 7c0e483d3f integrator: update the Integrator/CP config
The Integrator/CP config file was very outdated and gives a
non functional U-Boot. So:

- Set the CONFIG_ARCH_CINTEGRATOR arch flag correctly
- Add proper core module configuration options
- Skip cluttered command lista and just include
  <config_cmd_default.h>
- Kill off #if 0 network section and insert some example
  configuration that simply just boots from the network
  using TFTP if available.
- Delete flash control registers that have no business
  in this config file. These are already moved down to
  board/armltd/integrator/integrator-sc.h

Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2012-02-27 21:19:24 +01:00
Linus Walleij 2458716a5b integrator: rewrite the AP PCI driver
The PCI support for the Integrator AP has apparently never
been finished and I strongly suspect that it has never worked,
so let's fix it. This is a list of the more or less
un-splittable changes done in this driver rewrite:

- Replace the register definitions stashed into the config
  file (!) with a copy if the register file from the Linux
  kernels arch/arm/include/asm/hardware/pci_v3.h

- Delete the unreadable gigantic macros that perform the
  config accesses and replace them with copyedited code from
  Linux arch/arm/mach-integrator/pci_v3.c

- Rewrite the rest of the setup code to use the
  v3_[read|write][lwb]() accessors.

- Enable PCI by default in the AP board configuration.

- Fix checkpatch warnings and make code more conformant.

Tested-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2012-02-27 21:19:24 +01:00
Detlev Zundel 48a4ee50e4 mcx: Enable command line editing
Signed-off-by: Detlev Zundel <dzu@denx.de>
CC: Stefano Babic <sbabic@denx.de>
2012-02-27 21:19:24 +01:00
prabhakar.csengg@gmail.com fda9c20c80 dm6467Tevm: Use a common configuration file for davinci_dm6467evm and davinci_dm6467Tevm
In commit 2d575e4685 a separate header
file was introduced for the DM6467T EVM, include/configs/davinci_dm6467Tevm.h.
The substantial difference between the davinci_dm6467evm and the
davinci_dm6467Tevm configuration is a single bit in the hardware revision
that is passed to the Linux kernel and davinci_dm6467evm has
REFCLK_FREQ = 27000000 where as davinci_dm6467Tevm.h has a
REFCLK_FREQ = 33000000.

This patch removes include/configs/davinci_dm6467Tevm.h. Instead the
include/configs/davinci_dm6467evm.h configuration is used for DM6467T EVMs and
renamed CFG_REFCLK_FREQ to CONFIG_REFCLK_FREQ and CONFIG_REFCLK_FREQ is defined
in boards.cfg.

Signed-off-by: Prabhakar Lad <prabhakar.csengg@gmail.com>
Cc: Tom Rini <trini@ti.com>
2012-02-27 21:19:24 +01:00
Thomas Weber 512dce098f OMAP3: Remove unused CONFIG_SYS_NAND_ECCSTEPS/TOTAL
Signed-off-by: Thomas Weber <weber@corscience.de>
2012-02-27 21:19:24 +01:00
Thomas Weber 5605979abe Tricorder: Switch env to generic mmc driver
Because the tricorder uses the CONFIG_OMAP_HSMMC the
initialization command is mmc rescan and not mmc init.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tom Rini <trini@ti.com>
2012-02-27 21:19:24 +01:00
Eric Nelson 913b321a1e mx6q: mx6qsabrelite: Conditionally define macros for environment in serial flash
The default settings store the persistent environment on SD card
and not serial flash (SPI NOR).

To use SPI NOR to save the environment instead of SD card, edit
include/configs/mx6qsabrelite.h and

- undefine CONFIG_ENV_IS_IN_MMC
- define   CONFIG_ENV_IS_IN_SPI_FLASH

The SPI driver can take as chip select the controller's chip selects
as well as an external GPIO. The LSB byte has the value of the internal
chip select, the highest (thought as 16-bit value) contains the GPIO
number.

The GPIO used on Sabre Lite is GP3:19 == 83.

Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
Acked-by: Jason Liu <jason.hui@linaro.org>
Tested-by: Jason Liu <jason.hui@linaro.org>
2012-02-27 21:19:23 +01:00
Eric Nelson ba54b9276a mx6q: mx6qsabrelite: Provide default serial flash bus and chip-select
Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Acked-by: Jason Liu <jason.hui@linaro.org>
Tested-by: Jason Liu <jason.hui@linaro.org>
2012-02-27 21:19:23 +01:00
Eric Nelson 373a1d8c0e mx6q: mx6qsabrelite: Add ECSPI support to the Sabrelite platform
Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
Acked-by: Stefano Babic <sbabic@denx.de>
Acked-by: Jason Liu <jason.hui@linaro.org>
Tested-by: Jason Liu <jason.hui@linaro.org>
2012-02-27 21:19:23 +01:00
Matthias Fuchs ed97abed27 mx28evk: add SPI support
This patch adds SPI support for the MX28EVK. Support for
an optionally installed SPI flash is also added. An example
configuration for redundant envrionment from SPI flash is also
added but disabled by default.

This patch has been tested on a MX28EVK Rev. D with an installed
SST25VF032B 32Mbit SPI flash.

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd.eu>
Acked-by: Fabio Estevam <fabio.estevam@freescale.com>
2012-02-27 21:19:22 +01:00
Matthias Fuchs 598aa2bbfb mx28evk: add USB support
This patch enables USB host support on the MX28EVK board.

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd.eu>
Tested-by: Fabio Estevam <fabio.estevam@freescale.com>
2012-02-27 21:19:22 +01:00
Matthias Fuchs 9588d94219 mx28evk: add RTC support
This patch adds support for the MX28 internal RTC
and enables u-boot's date command.

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd.eu>
Tested-by: Fabio Estevam <fabio.estevam@freescale.com>
2012-02-27 21:19:22 +01:00
Stephan Linz 4eb29cf043 microblaze: Enable TFTP put command
Signed-off-by: Stephan Linz <linz@li-pro.net>
2012-02-23 12:17:08 +01:00
Wolfgang Denk 2acca35ce4 Merge branch 'master' of git://git.denx.de/u-boot-mmc
* 'master' of git://git.denx.de/u-boot-mmc:
  mmc: make mmc_send_status() more reliable
  mmc: fix card busy polling
  Tegra: mmc: Fixed handling of interrupts in timeouts.
  omap_hsmmc: Wait for CMDI to be clear
2012-02-17 23:54:46 +01:00
Wolfgang Denk 7dda0c3759 Merge branch 'master' of git://git.denx.de/u-boot-mpc85xx
* 'master' of git://git.denx.de/u-boot-mpc85xx:
  powerpc/8xxx:Add MPH controller support in USB device-tree fixup
  powerpc/8xxx: Cleanup USB device-tree fixup
2012-02-17 23:54:17 +01:00
Jan Kloetzke d617c426a6 mmc: make mmc_send_status() more reliable
Align the card status polling with the Linux kernel and retry the
command at least five times. Also some cards apparently mishandle the
status bits, so make sure to check the card state too.

Signed-off-by: Jan Kloetzke <jan.kloetzke@dspg.com>
Cc: Andy Fleming <afleming@gmail.com>
2012-02-15 17:42:22 -06:00
ramneek mehresh 79f49120ba powerpc/8xxx:Add MPH controller support in USB device-tree fixup
Add support for fixing usb mode and phy type for
MPH(Multi Port Host) USB controllers in device-tree nodes.
Required for socs like P3060, P5020, etc having MPH USB controller

Signed-off-by: Ramneek Mehresh <ramneek.mehresh@freescale.com>
2012-02-15 16:50:14 -06:00
Wolfgang Denk 06576b2efc Merge branch 'master' of git://git.denx.de/u-boot-blackfin
* 'master' of git://git.denx.de/u-boot-blackfin:
  Blackfin: pata_bfin: fix printf warning
  Blackfin: bfin_nand: mark local func static
  linkage.h: move from blackfin to common includes
  Blackfin: br4: new board port
  Blackfin: add in/out le32 variants
  post: add blackfin to the post_time_ms list
  Blackfin: bf537-stamp: drop board reset workaround
  Blackfin: pr1: new board port
2012-02-13 23:13:22 +01:00
Macpaul Lin 273d11eae5 linkage.h: move from blackfin to common includes
1. Add linkage.h support from blackfin to common include,
   which is a reduced version from Linux.
2. Add architecture part support of linkage.h into blackfin
3. Fix include path of in blackfin related to linkage.h
   due to header file movement.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-02-12 15:03:26 -05:00
Dimitar Penev 051a5f30f1 Blackfin: br4: new board port
This adds support for the BR4 Appliance.  It is a quad channel ISDN BRI
board based on Blackfin BF537 CPU.

Signed-off-by: Dimitar Penev <dpn@switchfin.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-02-12 15:03:25 -05:00
Dimitar Penev 939b150ae5 Blackfin: pr1: new board port
This add support for the PR1 Appliance - Asterisk based ISDN PRI PBX.
This board is Blackfin BF537 based.  The schematics are not fully opened.

Signed-off-by: Dimitar Penev <dpn@switchfin.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-02-12 15:03:25 -05:00
Christian Riesch 9a3aae22ed arm, davinci: Add support for the Calimain board from OMICRON electronics
This patch adds support for the Calimain board from
OMICRON electronics GmbH. The board features a Texas Instruments AM1808
SoC, 128 MB DDR2 memory, and 64 MB NOR flash memory connected to CS2 and
CS3.

Signed-off-by: Christian Riesch <christian.riesch@omicron.at>
2012-02-12 10:11:33 +01:00
Sughosh Ganu 6b873dcabd Changes to move hawkboard to the new spl infrastructure
This patch moves hawkboard to the new spl infrastructure from the
older nand_spl one.

Removed the hawkboard_nand_config build option -- The spl code now
gets compiled with hawkboard_config, after building the main u-boot
image, using the CONFIG_SPL_TEXT_BASE. Modified the README.hawkboard
to reflect the same.

Signed-off-by: Sughosh Ganu <urwithsughosh@gmail.com>
Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Heiko Schocher <hs@denx.de>
Cc: Christian Riesch <christian.riesch@omicron.at>
Cc: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Cc: Tom Rini <trini@ti.com>
Acked-by: Christian Riesch <christian.riesch@omicron.at>
2012-02-12 10:11:33 +01:00
Christian Riesch b67d8816fd arm, arm926ejs: Add option CONFIG_SYS_EXCEPTION_VECTORS_HIGH
The V bit of the c1 register of CP15 should not be cleared on DA850
SoCs since they have no valid memory at 0x00000000. This patch
introduces a configuration option CONFIG_SYS_EXCEPTION_VECTORS_HIGH
that allows setting the correct value for the V bit.

Signed-off-by: Christian Riesch <christian.riesch@omicron.at>
Reported-by: Sughosh Ganu <urwithsughosh@gmail.com>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Tom Rini <trini@ti.com>
Cc: Sughosh Ganu <urwithsughosh@gmail.com>
Cc: Heiko Schocher <hs@denx.de>
2012-02-12 10:11:33 +01:00
Christian Riesch 27b66622b5 arm, arm926ejs: Do cpu critical inits only for boards that require it
This patch reverts commit ca4b55800e
"arm, arm926ejs: always do cpu critical inits" since it impacts all
arm926ejs based configurations and caused problems, e.g., with
the hawkboard.

Instead the patch removes the CONFIG_SKIP_LOWLEVEL_INIT defines
from the board configurations that need low level initialization.

Signed-off-by: Christian Riesch <christian.riesch@omicron.at>
Cc: Albert Aribaud <albert.u.boot@aribaud.net>
Cc: Tom Rini <trini@ti.com>
Cc: Heiko Schocher <hs@denx.de>
Acked-by: Heiko Schocher <hs@denx.de>
Tested-by: Heiko Schocher <hs@denx.de>
2012-02-12 10:11:33 +01:00
Hadli, Manjunath 8f5d468721 davinci: add support for printing clock frequency
add support for printing various clock frequency info found
in SOC such as ARM core frequency, DSP core frequency and DDR
frequency as part of bdinfo command.

Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Cc: Tom Rini <trini@ti.com>
2012-02-12 10:11:32 +01:00
Hadli, Manjunath 6678cebc09 davinci: remove macro CONFIG_DISPLAY_CPUINFO
remove the macro CONFIG_DISPLAY_CPUINFO as it is no longer
required. This is because clock info will be printed as part
'bdinfo' command and also remove support print_cpuinfo() as it will
no longer be called.

Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Cc: Tom Rini <trini@ti.com>
2012-02-12 10:11:32 +01:00
Ilya Yanok 4ab779cba6 mcx: support for HTKW mcx board
This patch adds support for the HTKW mcx AM3517-based board.
Serial, Ethernet, NAND, MMC, RTC, EHCI USB host and both
NAND and MMC SPLs are supported.

Signed-off-by: Ilya Yanok <yanok@emcraft.com>
Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Tom Rini <tom.rini@gmail.com>
Cc: Detlev Zundel <dzu@denx.de>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
2012-02-12 10:11:31 +01:00
Stefano Babic 1fdabedd0c ARM: omap3: Added Teejet mt_ventoux
The mt_ventoux board is a custom board using
the Technexion TAM3517 module.

The patch fixes also the mtdparts variable in the
TAM3517 common configuration file.

Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Ilya Yanok <yanok@emcraft.com>
CC: Igor Grinberg <grinberg@compulab.co.il>
CC: Tom Rini <tom.rini@gmail.com>
Cc: Detlev Zundel <dzu@denx.de>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
2012-02-12 10:11:31 +01:00
Stefano Babic 8c589d6fef OMAP3: TAM3517: update ehci interface
Changed the EHCI interface using the ulpi framework.

Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Tom Rini <tom.rini@gmail.com>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
2012-02-12 10:11:31 +01:00
Govindraj.R 49be71c475 OMAP4: ehci-omap: enable ehci-omap for panda boards
For panda initialise the mux pins for ehci usage and
enable ehci in omap4_panda config file.

Signed-off-by: Govindraj.R <govindraj.raja@ti.com>
Tested-by: Stefano Babic <sbabic@denx.de>
2012-02-12 10:11:31 +01:00