This patch reflects real naming of SPI by Freescale.
We have two ECSPI channels and one CSPI.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Among other things the power initialization also turns on power
for the ethernet phy, so register the fec after power init.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Add a check to verify if /barebox.BIP0 exists, and if so,
unlock the protection area, flash barebox, and reprotect the
area.
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
To speed-up linux kernel loading, switch the PXA cpu to the
maximum allowed frequency (520 MHz). This improves the load
time from several seconds to less than a second from the
MTD.
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
In order for barebox to be functional, the docg3 DPS1 has to
protect barebox from writes, and have its embedded IPL coded
to load barebox (as barebox is the SPL).
Add a raw DPS1, which :
- protects the area from block 6 to block 123
This is DPS1 + barebox + barebox-logo
- encodes the 2048 bytes IPL
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Make the autoboot work :
- if no USB cuable is plugged, continue directly to
autoboot
- if an USB cable is plugged, wait for 3 seconds for
any input on the USB serial gadget, and if none
happens, continue to autoboot linux kernel
- else interrupt autoboot and interact on barebox
console
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Recent evolutions of linux kernel's drivers for docg3 chip,
ie. it's renaming for mtdparts option, is handled by this
patch.
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
To avoid unnecessary preset initial state chipselect lines for SPI, set it to
inactive state when adding devices to the system.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
The mc13xxx driver correctly bails out on failure, but leaves
mc_dev initialized, so a later mc13xxx_get won't fail but returns
an invalid pointer. Fix this. While at it, remove some superfluous
code from mc13xxx_get.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This got broken while updating the iomux definitions from the
kernel. Since then the PMIC did not work anymore.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Writing big files takes longer and longer because of the chunk list
By storing a pointer of the recent used chunk in the inode, access times are
improved.
Testet on with tftp 10M:
OMAP4 chunk size 4096: 12244ms 8192: 4239ms
patched 2647ms 2785ms
i.MX35 chunk size 8192: 7225ms
patched 2691ms
No impact on much smaller files seen
Signed-off-by: Jan Weitzel <j.weitzel@phytec.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
When invoked from a skript it's useful to know which file is edited. Also
Add information how to exit the editor to the status line.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
resolv() uses getenv_ip() which in turn calls resolv(). Fix
this inifinite loop by not using getenv_ip directly.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Currently magicvar fails on variables containing a '.' because we can't
use these as C names. Overcome this by adding a new macro which allows
to specify a name seperately.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
The value already is set by calling gpio_direction_output.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This got lost in:
commit 6188685091
Author: Sascha Hauer <s.hauer@pengutronix.de>
Date: Sun May 13 12:43:58 2012 +0200
Make errno a positive value
Normally errno contains a positive error value. A certain unnamed developer
mixed this up while implementing U-Boot-v2. Also, normally errno is never
set to zero by any library function.
This patch fixes this.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This causes allocation of a free id and avoids conflicts if multiple
identical SPI devices are attached.
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Ok, I assume this should go into separate series. It fits both S5PV210 and S3C6410.
This adds support for S3C and S5P architectures (all of my knowledge) to the
serial driver. Since the only difference between them is in clock handling,
this is moved to an arch-dependent separate function.
Most modern architectures should define S3C_UART_HAS_UBRDIVSLOT and S3C_UART_HAS_UINTM.
This adds support for most
Signed-off-by: Alexey Galakhov <agalakhov@gmail.com>
Signed-off-by: Juergen Beisewrt <kernel@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Actually ISP1504 ULPI chip are installed on PCM970 development board.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
We currently use the environment variable 'bootargs' to get the
Linux bootargs. This patch allows for a more flexible bootargs
generation using global variables. With it the Linux bootargs
are concatenated from multiple variables. This allows to replace
parts of the bootargs string without having to reconstruct it
completely.
With this bootargs can be constructed like:
global linux.bootargs.base="console=ttyS0,115200"
global linux.bootargs.ip="ip=dhcp"
global linux.mtdparts="physmap-flash.0:512K(nor0.barebox),-(root)"
This will then automatically be combined into a kernel bootargs
string during boot.
If the 'linux.bootargs.' variables are all empty the old standard
'bootargs' way will be used.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This implements global shell variable support. This is done by registering
a new device named 'global', so global variables are just plain device
parameters.
Global variables are useful for storing the global state in the environment.
Currently we do this by sourcing scripts instead of executing them which is
quite limiting.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This patch adds readonly NFS support. Currently no links are supported.
This is based on the previous U-Boot/NetBSD based code and some Kernel
bits.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Normally errno contains a positive error value. A certain unnamed developer
mixed this up while implementing U-Boot-v2. Also, normally errno is never
set to zero by any library function.
This patch fixes this.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Add this definition in preparation for the introduction of the
mpc85xx support.
Signed-off-by: Renaud Barbier <renaud.barbier@ge.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Currently we return NULL for unset parameters. As we can't set them
back to NULL once set this is not very consistent. Return an empty
string instead.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Some devices need to be moved to the PCM970 source file later, because
in fact these devices are not installed on the main unit PCM038.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Power and frequency should be setup before initialize other devices.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>