esw@bus-elektronik.de [Mon, 16 Jan 2012 00:22:02 +0000 (00:22 +0000)]
add new board vl_ma2sc
* add support for board VL+MA2SC
* adds vl_ma2sc_config for standard NOR boot configuration
* adds vl_ma2sc_ram_config for RAM load configuration
Signed-off-by: Jens Scharsig <esw@bus-elektronik.de>
Stefan Roese [Thu, 2 Feb 2012 12:25:45 +0000 (13:25 +0100)]
MTD: SPEAr SMI: Add write support for length < 4 bytes
Needed for redundant environment for example.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Stefan Roese [Fri, 20 Jan 2012 10:52:33 +0000 (11:52 +0100)]
i2c: designware_i2c.c: Add support for the "i2c probe" command
i2c_probe() is changed to reinit the i2c bus upon read failure.
This is naturally the case upon i2c bus probing.
Also, some printf messages upon read failure are removed. As they
would interfere with the "i2c probe" command.
Additionally, i2c_set_bus_speed() now returns 0, so that the
"i2c speed" command can be used.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Stefan Roese [Fri, 20 Jan 2012 10:47:47 +0000 (11:47 +0100)]
rtc/m41t62: Add support for M41T82 with HT (Halt Update)
Add support for the M41T82 RTC to the m41t62 driver. The only
difference that needs to be handled by this driver, is to
clear the HT (Halt Update) bit upon reset. This bit is not
used on the M41T62, so its save to clear this bit always.
The M41T82 support will be used by the X600 (SPEAr600)
board support.
Signed-off-by: Stefan Roese <sr@denx.de>
Stefan Roese [Tue, 3 Jan 2012 15:49:01 +0000 (16:49 +0100)]
SPL: ARM: spear: Add SPL support for SPEAr600 platform
This patch adds SPL support for SPEAr600. Currently only SNOR
(Serial NOR) flash support is included. Other boot devices
(NAND, MMC, USB ...) may be added with later patches.
Tested on the STM SPEAr600 evaluation and x600 SPEAr600 boards.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Stefan Roese [Thu, 5 Jan 2012 10:19:50 +0000 (11:19 +0100)]
Makefile: Add u-boot.spr build target (SPEAr)
On x600 (SPEAr600) U-Boot is appended to U-Boot SPL. Both images are
created using mkimage (crc etc), so that the ROM bootloader can check
its integrity. Padding needs to be done to the SPL image (with
mkimage header) and not the binary. Otherwise the resulting image
which is loaded/copied by the ROM bootloader to SRAM doesn't fit.
The resulting image containing both U-Boot images is called u-boot.spr.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Stefan Roese [Thu, 5 Jan 2012 10:23:45 +0000 (11:23 +0100)]
SPL: ARM: spear: Remove some objects from SPL build
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Stefan Roese [Thu, 5 Jan 2012 09:57:20 +0000 (10:57 +0100)]
SPL: lib/Makefile: Add crc32.c to SPL build
This is needed for the SPEAr SPL support, as SPEAr uses the mkimage
header to wrap and validate the images (SPL & U-Boot).
Signed-off-by: Stefan Roese <sr@denx.de>
Stefan Roese [Thu, 5 Jan 2012 09:53:09 +0000 (10:53 +0100)]
SPL: common/Makefile: Add image.c to SPL build
This is needed for the SPEAr SPL support, as SPEAr uses the mkimage
header to wrap and validate the images (SPL & U-Boot).
Signed-off-by: Stefan Roese <sr@denx.de>
Simon Glass [Sat, 3 Mar 2012 20:33:15 +0000 (12:33 -0800)]
arm: Don't use printf() in SPL builds
raise() likes to call printf() if it is available, but in SPL builds it
either is not available, or adds a large chunk to the resulting image
size.
So don't call it even if it is available.
This change reduces SPL size from 10KB to 6.3KB on hawkboard, for
example, using generic relocation.
Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Stefan Roese <sr@denx.de>
Stefan Roese [Tue, 14 Feb 2012 13:01:36 +0000 (14:01 +0100)]
GPIO: Add SPEAr GPIO driver
Tested on x600 (SPEAr600).
Signed-off-by: Stefan Roese <sr@denx.de>
Stefan Roese [Mon, 7 May 2012 10:04:25 +0000 (12:04 +0200)]
net: Multiple updates/enhancements to designware.c
This patch adds the following changes to designware ethernet driver
found on the ST SPEAr SoC:
- Don't init MAC & PHY upon startup. This causes a delay, waiting for
the auto negotiation to complete. And we don't want this delay to
always happen. Especially not on platforms where ethernet is not
used at all (e.g. booting via flash).
Instead postpone the MAC / PHY configuration to the stage, where
ethernet is first used.
- Add possibility for board specific PHY init code. This is needed
for example on the X600 board, where the Vitesse PHY needs to be
configured for GMII mode.
This board specific PHY init is done via the function
designware_board_phy_init(). And this driver now adds a weak default
which can be overridden by board code.
- Use common functions miiphy_speed() & miiphy_duplex() to read
link status from PHY.
- Print status and progress of auto negotiation.
- Print link status (speed, dupex) upon first usage.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Amit Virdi <amit.virdi@st.com>
Cc: Vipin Kumar <vipin.kumar@st.com>
Cc: Joe Hershberger <joe.hershberger@gmail.com>
Acked-by: Joe Hershberger <joe.hershberger@gmail.com>
Amit Virdi [Mon, 7 May 2012 07:37:02 +0000 (13:07 +0530)]
cleanup/SPEAr: Define configuration flags more elegantly
In SPEAr, some of the configuration flags eg. CONFIG_SPEAR_EMI, were given value
"1", which isn't required. Define the flags without assigning any value
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:37:01 +0000 (13:07 +0530)]
cleanup/SPEAr: Remove unnecessary parenthesis
In SPEAr configuration files, unnecessary paranthesis are used in some
\#defines. Remove them as they serve no purpose
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Shiraz Hashim [Mon, 7 May 2012 07:37:00 +0000 (13:07 +0530)]
SPEAr: Correct SoC ID offset in misc configuration space
SoC Core ID offset is 0x30 in miscellaneous configuration address
space. It was wrongly mentioned as periph2 clk enable.
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Shiraz Hashim [Mon, 7 May 2012 07:36:59 +0000 (13:06 +0530)]
SPEAr: explicitly select clk src for UART
UART in u-boot intends to run on 48MHz clock supplied by USB PLL.
Explicitly select the intended clock source.
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:36:58 +0000 (13:06 +0530)]
SPEAr: Remove CONFIG_MTD_NAND_VERIFY_WRITE to speed up NAND access
When CONFIG_MTD_NAND_VERIFY_WRITE is defined, nand driver read back the data
everytime it writes. This process unnecessarily slows down the nand access.
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:36:57 +0000 (13:06 +0530)]
SPEAr: Enable ONFI nand flash detection for spear3xx and 6xx and evb
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:36:56 +0000 (13:06 +0530)]
SPEAr: Enable CONFIG_SYS_FLASH_EMPTY_INFO macro
Enable CONFIG_SYS_FLASH_EMPTY_INFO macro to enable reporting of empty sector
information through flinfo command.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:36:55 +0000 (13:06 +0530)]
SPEAr: Correct the definition of CONFIG_SYS_MONITOR_BASE
The below text is copy pasted from README
- CONFIG_SYS_MONITOR_BASE:
Physical start address of boot monitor code (set by
make config files to be same as the text base address
(TEXT_BASE) used when linking) - same as
CONFIG_SYS_FLASH_BASE when booting from flash.
This patch corrects the definition of CONFIG_SYS_MONITOR_BASE and sets it to
TEXT_BASE
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:36:54 +0000 (13:06 +0530)]
SPEAr: Enable CONFIG_SYS_FLASH_PROTECTION
This patch enables flash protection(lock/unlock) for CFI devices.
This is necessary because the Parallel NOR flash connected on the spear
boards, M28W64, can be locked/unlocked on a sector basis. Moreover, all its
sectors are in locked state at reset and these have to be unlocked explicitly
before being erased or written.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Shiraz Hashim [Mon, 7 May 2012 07:36:53 +0000 (13:06 +0530)]
SPEAr: Enable dcache for fast file transfer
Enable data cache with 1:1 mapping of DDR to enable fast file
transfer over tty which was doing lot of copy.
This feature is enabled only for flashing operation i.e. when
CONFIG_SPEAR_USBTTY is enabled.
This has been tested on SPEAr320, SPEAr600 and SPEAr900 evaluation
boards.
Following figures show an estimate on the performance improvements. The
test setup was a Linux host (not Windows) and involved measurement of
only binary transfer time, through kermit. The flash erase and flash
copy time would be unaffected by these patches.
Another thing is this that the timings remained more or less same across
ARM9 and Cortex based devices, hence reporting only one of the cases.
Before Enhancements
===================
$ time ukermit.small -p /dev/ttyACM0 -f spear320_uImage.img
Downloading file: 100.00% completed(2014080/2014080 bytes)
real 0m41.228s
user 0m0.002s
sys 0m0.064s
After Enhancements
==================
$ time ukermit.large -p /dev/ttyACM0 -f spear320_uImage.img
Downloading file: 100.00% completed(2014080/2014080 bytes)
real 0m5.441s
user 0m0.001s
sys 0m0.001s
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Shiraz Hashim [Mon, 7 May 2012 07:36:52 +0000 (13:06 +0530)]
SPEAr: Enable autoneg for ethernet
Enabling autoneg avoids situation on few phys with fixed configuration. For
example, in one situation, nfs boot timed out when phy configuration is 100Mbps.
In another situtation, when traffic is directed to SPEAr, either thru
cross-cable or thru switch, the TFTP or DHCP command in u-boot starts to timeout
very often.
When Autoneg is ON, same phys started working perfectly.
Reported-by: Deepak Sikri <deepak.sikri@st.com>
Reported-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:51 +0000 (13:06 +0530)]
SPEAr: Enable udc and usb-console support only for usbtty configuration
This patch enables the UDC and usb-console support only for usbtty
configurations
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:50 +0000 (13:06 +0530)]
SPEAr: Enable usb device high speed support
This patch enables the support for usb high speed device for spear platform SOCs
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:36:49 +0000 (13:06 +0530)]
SPEAr: Initialize SNOR in early_board_init_f
flash reading is required earlier than flash_init is called since the env_init
is called before flash_init. This makes the smi_init necessary before env_init
being called.
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:48 +0000 (13:06 +0530)]
SPEAr: Change the default environment variables
This patch modifies the default environment variables as:
1. Default bootargs:
- console=ttyAMA0,115200
- For environment present in NOR flash
root=/dev/mtdblock3
- For environment present in NAND flash
root=/dev/mtdblock7
- Removes "mem=" option
2. Introduces CONFIG_EXTRA_ENV_USBTTY as default usbtty env var even when usbtty
is not selected
3. Add default definitions for nfsboot and ramboot
4. Add a new default environment variable(CONFIG_EXTRA_ENV_UNLOCK) for SPEAr310
and SPEAr320
Signifacance of CONFIG_EXTRA_ENV_USBTTY:
This environment variable is important for flashing utility to work. So if
somebody accidently erases the env sector then also this variable must be
preserved so that flashing utility functions properly.
Signifacance of CONFIG_EXTRA_ENV_UNLOCK:
This env variable is read by the cfi driver to unlock all flash sectors. This
is necessary because the Parallel NOR flash connected on the spear310 and
spear320 boards, M28W64, has all its sectors in locked state at reset and these
have to be unlocked explicitly before being erased or written.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:47 +0000 (13:06 +0530)]
SPEAr: Remove unused flag (CONFIG_SYS_HZ_CLOCK)
SPEAr doesn't need CONFIG_SYS_HZ_CLOCK. This commit removes it.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:46 +0000 (13:06 +0530)]
SPEAr: Add configuration options for spear3xx and spear6xx boards
This patch adds options for all the below mentioned configurations and
subsequently renames the include/configs/spearxxx.h files to spear3xx_evb.h,
spear6xx_evb.h etc to depict evaluation board configuration.
SPEAr3xx and SPEAr6xx boards can be compiled in following configurations
1. Environment placed in NAND
2. Console on usb device
3. Console on usb device with environment placed in NAND
4. SPEAr310 and SPEAr320 support environment variables in parallel
NOR flash.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:45 +0000 (13:06 +0530)]
SPEAr: Add basic arch related support for SPEAr SoCs
Earlier, architecture specific init code was mixed with board initialization
code in board/spear/... This patch updates architecture support for SPEAr in
latest u-boot and prints the SoC information.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:36:44 +0000 (13:06 +0530)]
SPEAr: Add interface information in initialization
Few Designware peripheral registers need to be modified based on the
ethernet interface selected by the board. This patch supports interface
information in ethernet driver
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:43 +0000 (13:06 +0530)]
SPEAr: Add macb driver support for spear310 and spear320
SPEAr310 and SPEAr320 SoCs have an extra ethernet controller. The
driver for this device is already supported by u-boot, so configuring
board configuration file and defining base addresses etc to make use
of the common driver
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:42 +0000 (13:06 +0530)]
SPEAr: Configure network support for spear SoCs
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:36:41 +0000 (13:06 +0530)]
SPEAr: Place ethaddr write and read within CONFIG_CMD_NET
ethaddr can be optionally read from i2c memory. So, chip_config command supports
reading/writing hw mac id into i2c memory. Placing this code within
CONFIG_CMD_NET as this would only be needed when network interface is configured
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:36:40 +0000 (13:06 +0530)]
SPEAr: Eliminate dependency on Xloader table
Xloader table was used primarily to inform u-boot about the DDR size. However,
now the ddr size is calculated at runtime which eliminates any need for the
Xloader table. So removing this unnecessary code.
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:36:39 +0000 (13:06 +0530)]
SPEAr: Fix ARM relocation support
While the u-boot code is running from the flash, it is essential that no access
is made to the bss segment. This is due to the fact that .rel.dyn and .bss areas
overlap and former contains information used in relocation. In SPEAr, this was
not taken into consideration. As a result, while the relocation wasn't complete,
dram_init populated an uninitialized global variable resulting in corruption of
.rel.dyn area, which resulted in u-boot crash.
This commit fixes this problem by removing code that accesses bss segment
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Armando Visconti [Mon, 7 May 2012 07:30:30 +0000 (13:00 +0530)]
st_smi: Fixed page size for Winbond W25Q128FV flash
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:30:29 +0000 (13:00 +0530)]
st_smi: Change timeout loop implementation
There are two problems in the current timeout loop implementation:
1. In case initial test failing, there will always be a delay of 1 ms
2. The delay duration is not tunable
The new implementation addresses both these limitations.
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Armando Visconti [Mon, 7 May 2012 07:30:28 +0000 (13:00 +0530)]
st_smi: Fix bug in flash_print_info()
If the flash size was smaller than 1MB then flash_print_info()
was erroneously reporting 0 MB.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Armando Visconti [Mon, 7 May 2012 07:30:27 +0000 (13:00 +0530)]
st_smi: Change the flash probing method
THis patch introduces a new methodology for flash probing
in which flash_devices[] table, looked-up thru the dev_id, is
used to locate the flash geometry and information.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Armando Visconti [Mon, 7 May 2012 07:30:26 +0000 (13:00 +0530)]
st_smi: Removed no needed dependency on ST_M25Pxx_ID
Since the smi erase code is very generic and works for any kind
of flash, there is no need to test for ST_M25Pxx_ID flash types
like m25p40 flashes).
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin Kumar [Mon, 7 May 2012 07:30:25 +0000 (13:00 +0530)]
st_smi: Fix smi read status
smi_read_sr fails sometimes because of TFF not getting set within assumed time.
This condition may arise because of, for example, smi memory being in a erase
mode.
This fix is to enable reading the status register until timeout.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Shiraz Hashim [Mon, 7 May 2012 07:30:24 +0000 (13:00 +0530)]
st_smi: Move status register read before modifying ctrl register
Signed-off-by: Shiraz Hashim <shiraz.hashim@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:30:23 +0000 (13:00 +0530)]
st_smi: Read status until timeout happens
SMI driver read status fails because the control register could not be
overwritten. Instead, the read status should be tried until timeout.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:30:22 +0000 (13:00 +0530)]
st_smi: Enhance the error handling
This commit does the following:
- Reports error if SNOR flash is not found on the board
- Changes smi_read_sr to return error using which a retry mechanism is
implemented for reading flash status
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:30:21 +0000 (13:00 +0530)]
st_smi: Change SMI timeout values
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Amit Virdi [Mon, 7 May 2012 07:30:20 +0000 (13:00 +0530)]
st_smi: Return error in case TFF is not set
Curently the code makes wrong assumption that the Transfer finished flag shall
be set within the stipulated time. However, there may occur a scenario in which
the TFF flag is not set. Return error in that case.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Mon, 7 May 2012 07:30:19 +0000 (13:00 +0530)]
st_smi: Add support for SPEAr SMI driver
SMI is the serial memory interface controller provided by ST.
Earlier, a driver exists in the u-boot source code for the SMI IP. However, it
was specific to spear platforms. This commit converts the same driver to a more
generic driver. As a result, the driver files are renamed to st_smi.c and
st_smi.h and moved into drivers/mtd folder for reusability by other platforms
using smi controller peripheral.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Vipin KUMAR [Tue, 22 May 2012 00:15:56 +0000 (00:15 +0000)]
mtd/NAND: Remove obsolete SPEAr specific NAND drivers
Since, SPEAr platform uses generic FSMC driver now, so spear specific files
drivers/mtd/nand/spr_nand.c, arch/arm/include/asm/arch-spear/spr_nand.h are
removed
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Acked-by: Scott Wood <scottwood@freescale.com>
Vipin KUMAR [Tue, 22 May 2012 00:15:55 +0000 (00:15 +0000)]
SPEAr: Configure FSMC driver for NAND interface
Since FSMC is a standard IP and it supports different memory interfaces, it
is supported independent of spear platform and spear is configured to use that
driver for interfacing with the NAND device
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Acked-by: Scott Wood <scottwood@freescale.com>
Vipin KUMAR [Tue, 22 May 2012 00:15:54 +0000 (00:15 +0000)]
mtd/NAND: Add FSMC driver support
Flexible static memory controller is a peripheral provided by ST,
which controls the access to NAND chips along with many other
memory device chips eg NOR, SRAM.
This patch adds the driver support for FSMC controller interfacing
with NAND memory.
Signed-off-by: Vipin Kumar <vipin.kumar@st.com>
Signed-off-by: Amit Virdi <amit.virdi@st.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Acked-by: Scott Wood <scottwood@freescale.com>
Holger Brunck [Thu, 5 Jul 2012 05:05:11 +0000 (05:05 +0000)]
arm/km: remove calls to kw_gpio_* in board_early_init_f
These functions tried to access two static tables before relocation
(board_early_init_f is executed before relocation). But these static
tables lie in the bss section which is not valid before relocation.
These accesses then overwrote some parts of u-boot binary before it was
relocated. For the kmnusa build, this results in a corrupted important
env variable (bootcmd) but it may be that some other parts of the u-boot
binary are corrupted.
This patch solves this problem by moving all the kw_gpio_* calls to
board_init, which should be early enough in the boot sequence. The only
calls that could not be moved is the one for the SOFT (bitbang) I2C, and
they have been replaced by a direct access to the GPIO dataout Control
register to set the two GPIOs as output.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Thomas Herzmann [Thu, 5 Jul 2012 05:05:10 +0000 (05:05 +0000)]
arm/km: add implementation for read_dip_switch
Add a function to read the dip_switch on kmcoge5un. If the
switch is set the actual_bank is set to 0 and this SW is
booted.
Signed-off-by: Thomas Herzmann <thomas.herzmann@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Valentin Longchamp [Thu, 5 Jul 2012 05:05:09 +0000 (05:05 +0000)]
arm/km: support the 2 PCIe fpga resets
The PCIe FPGAs now have to support 2 resets: one for the non traffic
affecting part (PCIe) and one for the traffic affecting part.
When the FPGA is not reconfigured, we only reset the PCIe part.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Valentin Longchamp [Thu, 5 Jul 2012 05:05:08 +0000 (05:05 +0000)]
arm/km: skip FPGA config when already configured
In order to be able to perform board resets without interrupting the
traffic, the configuration of an already properly configured FPGA is
skipped.
This is because some PCIe FPGAs embed some other function that must
continue to work over reset.
It is then the responsibility of the application to trigger a
reconfiguration when needed. This is done by lowering the FPGA_INIT_B
pin for delaying the configuration to u-boot @ next reboot, and then
lower the FPGA_PROGRAM_B signal.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Valentin Longchamp [Thu, 5 Jul 2012 05:05:07 +0000 (05:05 +0000)]
arm/km: redefine piggy 4 reg names to avoid conflicts
Some very similar #defines for reg addresses are used in a later patch
(managed_switch support for km_arm).
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Thu, 5 Jul 2012 05:05:06 +0000 (05:05 +0000)]
arm/km: cleanup km_kirkwood boards
Remove config options from boards.cfg and simply add one switch
per board and differ afterwards in km_kirkwood.h between the features.
More boards are upcoming and therefore it's easier to have this
at one place.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Thu, 5 Jul 2012 05:05:05 +0000 (05:05 +0000)]
arm/km: enable BOCO2 FPGA download support
This adds a first support of the FPGA download for a PCIe FPGA based
on the BOCO2 CPLD.
This takes place in 3 steps, all done accessing the SPICTRL reg of the
BOCO2:
1) start the FPGA config with an access to the FPGA_PROG bit
2) later in the boot sequence, wait for the FPGA_DONE bit to toggle to 1
for the end of the FPGA configuration (with a timeout)
3) reset the FPGA
4) finally remove the access to its config EEPROM from the FPGA so that
the CPU can update the FPGA configuration when the kernel is running
The boards with a PCIe FPGA but without BOCO2 still are supported.
The config option name is CONFIG_KM_FPGA_CONFIG
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Thu, 5 Jul 2012 05:05:04 +0000 (05:05 +0000)]
arm/km: remove portl2.h and use km_kirkwood instead
The additional headerfile is unneeded here, we can use the generic
km_kirkwood.h instead. And we can use the better config option
KM_PIGGY4_88E6061 for the specific features for boards with this
design in km_arm.c.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Thu, 5 Jul 2012 05:05:03 +0000 (05:05 +0000)]
arm/km: convert mgcoge3un target to km_kirkwood
Use the generic header km_kirkwood.h and get rid of the
board specific header.
changes for v2: rebased because of changes in other patches
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Thu, 5 Jul 2012 05:05:02 +0000 (05:05 +0000)]
arm/km: add kmcoge5un board support
For u-boot this board is similar to mgcoge3un. But some differences
are present. We have a different SDRAM on it and therefore a new
SDRAM config file. Additionaly this board has a direct MAC/MAC
connection from the kirkwood to a marvell simple switch without a
phy inbetween, this needs a new configuration for the mvgbe driver.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Thu, 5 Jul 2012 05:37:46 +0000 (05:37 +0000)]
arm/km: add kmnusa board support
This board is similar to portl2, but it has the u-boot environment
in a SPI NOR flash and not in an i2c eeprom like portl2 have.
Some other details:
- IVM EEPROM is at adress: pca9547:70:9
- PCI is enabled
- PIGGY4 is connected via MV88E6352 simple switch. There is no phy
between the simple switch and the kirkwood.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Tetsuyuki Kobayashi [Thu, 28 Jun 2012 23:36:21 +0000 (23:36 +0000)]
arm: bugfix: save_boot_params_default accesses uninitalized stack when -O0
save_boot_params_default() in cpu.c accesses uninitialized stack area
when it compiled with -O0 (not optimized).
Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
Acked-by: Tom Rini <trini@ti.com>
Nikita Kiryanov [Mon, 2 Jul 2012 02:27:59 +0000 (02:27 +0000)]
cm-t35: fix incorrect NAND_ECC layout selection
The current configuration selects an incorrect NAND ECC layout,
which causes u-boot to write HW ECC data incorrectly.
This patch selects the right layout.
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
SRICHARAN R [Tue, 12 Jun 2012 19:53:33 +0000 (19:53 +0000)]
ARM: OMAP4/5: Do not configure non essential pads, clocks, dplls.
Currently on OMAP4/5 platforms, many kernel drivers are dependent
upon the bootloaders for mux, dpll and clock configurations.
This should not be the case and bootloaders should set only the
minimum required for the uboot functionality and kernel boot.
Note that this is going to break the kernel drivers. But this
is the only way to get things fixed in the kernel.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
SRICHARAN R [Tue, 12 Jun 2012 19:53:32 +0000 (19:53 +0000)]
ARM: OMAP4/5: Move USB pads to essential list.
USB module pads are getting enabled under non-essential
group. These will be required for fastboot, tftp support.
So move this to essential list to have them working when
non-essential pads are no more muxed.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
SRICHARAN R [Tue, 12 Jun 2012 19:53:31 +0000 (19:53 +0000)]
ARM: OMAP4/5: Move USB clocks to essential group.
USB clocks will be required for fastboot, tftp
related functionalities. Move these clocks to
essential group inorder to have the functionality
working when non-essential clocks are not enabled.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
SRICHARAN R [Tue, 12 Jun 2012 19:53:30 +0000 (19:53 +0000)]
ARM: OMAP4/5: Move gpmc clocks to essential group.
GPMC clocks are currently getting enabled as a part
non-essential clocks. This will be required during
NOR boot. Move this to essential group to keep the
functionality, when non-essential clocks are not
enabled.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
SRICHARAN R [Mon, 4 Jun 2012 03:40:23 +0000 (03:40 +0000)]
ARM: OMAP4+: Move external phy initialisations to arch specific place.
The external phy is present in the case OMAP5 soc is currently
configured in emif-common.c. This results in having dummy structures
for those Socs which do not have a external phy. So by having a weak
function in emif-common and overriding it in OMAP5, avoids the use
of dummy structures.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
Sebastien Jan [Wed, 13 Jun 2012 05:16:40 +0000 (05:16 +0000)]
omap4: Use a smaller M,N couple for IVA DPLL
This reduced M,N couple corresponds to the advised value from
TI HW team.
Tested on 4460 Pandaboard, it also provides peripheral clocks
closer to the advised values.
Signed-off-by: Sebastien Jan <s-jan@ti.com>
Rajashekhara, Sudhakar [Thu, 7 Jun 2012 00:27:44 +0000 (00:27 +0000)]
da850/omap-l138: Enable auto negotiation in RMII mode
On DA850/OMAP-L138 it was observed that in RMII mode,
auto negotiation was not performed. This patch enables
auto negotiation in RMII mode. Without this patch, EMAC
initialization takes more time and sometimes tftp fails
in RMII mode.
Signed-off-by: Rajashekhara, Sudhakar <sudhakar.raj@ti.com>
Signed-off-by: Lad, Prabhakar <prabhakar.lad@ti.com>
Signed-off-by: Hadli, Manjunath <manjunath.hadli@ti.com>
Steve Sakoman [Wed, 30 May 2012 07:46:00 +0000 (07:46 +0000)]
omap: am33xx: accomodate input clocks other than 24 Mhz
The PLL setup values currently assume a 24 Mhz input clock.
This patch uses V_OSCK from the board config file to support boards
with different input clock rates.
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Steve Sakoman [Wed, 30 May 2012 07:38:08 +0000 (07:38 +0000)]
omap: emif: fix bug in manufacturer code test
Code currently tests for <= 0xff. Micron manufacturer code is 0xff, so
Micron memory will not be detected!
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Steve Sakoman [Wed, 30 May 2012 07:38:07 +0000 (07:38 +0000)]
omap: emif: deal with rams that return duplicate mr data on all byte lanes
Some rams (Micron for example) return duplicate mr data on all byte lanes.
Users of the get_mr function currently don't deal with this duplicated
data gracefully. This patch detects the duplicated data and returns only
the expected 8 bit mr data.
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Lokesh Vutla [Tue, 29 May 2012 19:26:43 +0000 (19:26 +0000)]
OMAP4+: Force DDR in self-refresh after warm reset
Errata ID:i727
Description: The refresh rate is programmed in the EMIF_SDRAM_REF_CTRL[15:0]
REG_REFRESH_RATE parameter taking into account frequency of the device.
When a warm reset is applied on the system, the OMAP processor restarts
with another OPP and so frequency is not the same. Due to this frequency
change, the refresh rate will be too low and could result in an unexpected
behavior on the memory side.
Workaround:
The workaround is to force self-refresh when coming back from the warm reset
with the following sequence:
• Set EMIF_PWR_MGMT_CTRL[10:8] REG_LP_MODE to 0x2
• Set EMIF_PWR_MGMT_CTRL[7:4] REG_SR_TIM to 0x0
• Do a dummy read (loads automatically new value of sr_tim)
This will reduce the risk of memory content corruption, but memory content
can't be guaranteed after a warm reset.
This errata is impacted on
OMAP4430: 1.0, 2.0, 2.1, 2.2, 2.3
OMAP4460: 1.0, 1.1
OMAP4470: 1.0
OMAP5430: 1.0
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: R Sricharan <r.sricharan@ti.com>
Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
Lokesh Vutla [Tue, 29 May 2012 19:26:42 +0000 (19:26 +0000)]
OMAP4+: Handle sdram init after warm reset
EMIF and DDR device state are preserved in warmreset. Redoing the full
initialisation would cause unexpected behaviour. Do only partial
initialisation to account for frequency change.
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: R Sricharan <r.sricharan@ti.com>
Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
Lokesh Vutla [Tue, 29 May 2012 19:26:41 +0000 (19:26 +0000)]
ARM: OMAP3+: Detect reset type
Certain modules are not affected by means of
a warm reset and need not be configured again.
Adding an API to detect the reset reason warm/cold.
This will be used to skip the module configurations
that are retained across a warm reset.
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: R Sricharan <r.sricharan@ti.com>
Tetsuyuki Kobayashi [Mon, 25 Jun 2012 02:40:57 +0000 (02:40 +0000)]
arm: bugfix: Move vector table before jumping relocated code
Interrupts and exceptions doesn't work in relocated code.
It badly use IRQ_STACK_START_IN in rom area as interrupt stack.
It is because the vecotr table is not moved to ram area.
This patch moves vector table before jumping relocated code.
Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
Tested-by: Tom Rini <trini@ti.com>
Marek Vasut [Tue, 3 Jul 2012 03:02:20 +0000 (03:02 +0000)]
Kirkwood: Add support for Ka-Ro TK71
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Prafulla Wadaskar <prafulla@marvell.com>
Cc: Wolfgang Denk <wd@denx.de>
Valentin Longchamp [Wed, 13 Jun 2012 03:01:03 +0000 (03:01 +0000)]
arm/km: use spi claim bus to switch between SPI and NAND
We overwrite these weak functions from the kirkwood spi code to
use our own method to be able to switch between the SPI NOR and
the NAND flash. This is needed e.g. to update the u-boot. The former
command do_spi_toggle can therefore be removed. And the usage of
this command is removed from the u-boot update command in the
u-boot environment.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Signed-off-by: Prafulla Wadaskar <prafulla@marvell.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Wed, 13 Jun 2012 03:03:52 +0000 (03:03 +0000)]
arm/kirkwood: protect the ENV_SPI #defines
So that they can be redefined by some boards specific values.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Simon Guinot [Tue, 5 Jun 2012 13:16:00 +0000 (13:16 +0000)]
ARM: don't probe PHY address for LaCie boards
The command miiphy_read(name, 0xEE, 0xEE, (u16 *) &devadr) always
returns 8 for the PHY address. It is the reset value for the PHY
Address Register. Obviously, this default value could be incorrect.
Moreover, as the PHY address is well known, there is no need to
auto-detect it.
Now, the PHY address must given as a parameter to the PHY initialization
function. Additionally this patch also fixes some aesthetic issues.
Signed-off-by: Simon Guinot <simon.guinot@sequanux.org>
Simon Guinot [Tue, 5 Jun 2012 13:15:59 +0000 (13:15 +0000)]
lacie_kw: fix CONFIG_SYS_KWD_CONFIG for inetspace_v2
Signed-off-by: Simon Guinot <simon.guinot@sequanux.org>
Simon Guinot [Tue, 5 Jun 2012 13:15:58 +0000 (13:15 +0000)]
lacie_kw: fix SDRAM banks number for net2big_v2
Signed-off-by: Simon Guinot <simon.guinot@sequanux.org>
Michael Walle [Tue, 5 Jun 2012 11:33:17 +0000 (11:33 +0000)]
Kirkwood: add lschlv2 and lsxhl board support
This patch adds support for both the Linkstation Live (LS-CHLv2) and
Linkstation Pro (LS-XHL) by Buffalo.
Signed-off-by: Michael Walle <michael@walle.cc>
Cc: Prafulla Wadaskar <prafulla@marvell.com>
Michael Walle [Tue, 5 Jun 2012 11:33:16 +0000 (11:33 +0000)]
net: add helper to generate random mac address
Add new function eth_random_enetaddr() to generate a locally administered
ethernet address.
Signed-off-by: Michael Walle <michael@walle.cc>
Acked-by: Joe Hershberger <joe.hershberger@gmail.com>
Michael Walle [Tue, 5 Jun 2012 11:33:15 +0000 (11:33 +0000)]
net: use common rand()/srand() functions
Replace rand() with the functions from lib/. The link-local network code
stores its own seed, derived from the MAC address. Thus making it
independent from calls to srand() in other modules.
Signed-off-by: Michael Walle <michael@walle.cc>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Michael Walle [Tue, 5 Jun 2012 11:33:14 +0000 (11:33 +0000)]
lib: add rand() function
It's a PRNG using the simple and fast xorshift method.
Signed-off-by: Michael Walle <michael@walle.cc>
Cc: Wolfgang Denk <wd@denx.de>
Luka Perkov [Sun, 27 May 2012 11:44:51 +0000 (11:44 +0000)]
kwboot: boot kirkwood SoCs over a serial link
The kwboot program boots boards based on Marvell's Kirkwood platform
via Xmodem over their integrated UART.
Signed-off-by: Daniel Stodden <daniel.stodden@googlemail.com>
Acked-by: Luka Perkov <uboot@lukaperkov.net>
Tested-By: Holger Brunck <holger.brunck@keymile.com>
Tested-By: David Purdy <david.c.purdy@gmail.com>
Tested-by: Simon Guinot <simon.guinot@sequanux.org>
Valentin Longchamp [Fri, 1 Jun 2012 01:31:03 +0000 (01:31 +0000)]
kw_spi: add weak functions board_spi_claim/release_bus
This allows a final, board specific, step in the claim/relase_bus
function for the SPI controller, which may be needed for some hardware
designs.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 1 Jun 2012 01:31:02 +0000 (01:31 +0000)]
kw_spi: support spi_claim/release_bus functions
These two function nows ensure that the MPP is configured correctly for
the SPI controller before any SPI access, and restore the initial
configuration when the access is over.
Since the used pins for the SPI controller can differ (2 possibilities
for each signal), the used pins are configured with CONFIG_SYS_KW_SPI_MPP.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 1 Jun 2012 01:31:01 +0000 (01:31 +0000)]
kw_spi: backup and reset the MPP of the chosen CS pin
This was not done before, and in the case of a shared pin (for MPP0
between NF_IO[2] and CSn) this could lead to problems.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 1 Jun 2012 01:31:00 +0000 (01:31 +0000)]
kirkwood: fix calls to kirkwood_mpp_conf
With the new second save argument introduced by the previous patch, all
the calls to the function had to be fixed.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 1 Jun 2012 01:30:59 +0000 (01:30 +0000)]
kirkwood: add save functionality kirkwood_mpp_conf function
If a second non NULL argument is given to the kirkwood_mpp_conf
function, it will be used to store the current configuration of the MPP
registers. mpp_save must be a preallocated table of the same size as
mpp_list and it must be zero terminated as well.
A later call to kirkwood_mpp_conf function with this saved list as first
(mpp_conf) argment will set the configuration back.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 25 May 2012 01:57:21 +0000 (01:57 +0000)]
km_arm: use filesize for erase in update command
We used to have an arbitrary value, which can be a problem if we have a
u-boot image that is bigger than this value.
This patch is dependant on the whole km/arm series and will be included
in the v3 of the series if there is one.
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Valentin Longchamp [Fri, 25 May 2012 01:57:20 +0000 (01:57 +0000)]
arm/km: enable mii cmd
This is useful to debug the switch initialization
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Fri, 25 May 2012 01:57:19 +0000 (01:57 +0000)]
arm/km: remove CONFIG_RESET_PHY_R
This is already defined in the generic kirkwood header.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Fri, 25 May 2012 01:57:18 +0000 (01:57 +0000)]
arm/km: change maintainer for mgcoge3un
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Acked-By: Heiko Schocher <hs@denx.de>
cc: Prafulla Wadaskar <prafulla@marvell.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
Holger Brunck [Fri, 25 May 2012 01:57:17 +0000 (01:57 +0000)]
arm/km: fix wrong comment in SDRAM config for mgcoge3un
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Holger Brunck [Fri, 25 May 2012 01:57:16 +0000 (01:57 +0000)]
arm/km: use ARRAY_SIZE macro
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Gerlando Falauto <gerlando.falauto@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>