Commit Graph

20298 Commits

Author SHA1 Message Date
Albert ARIBAUD c1b43ac769 Revert wrong removal of nand_init and nand_deselect
The manual resolution in commit ec7023db wrongly removed functions
nand_init and nand_deselect from file drivers/mtd/nand/mxc_nand_spl.c.
Revert this removal.

Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Acked-by: Stefano Babic <sbabic@denx.de>
2013-05-11 22:23:04 +02:00
Albert ARIBAUD ec7023db8d Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'
Conflicts:
	drivers/mtd/nand/mxc_nand_spl.c
	include/configs/m28evk.h
2013-05-11 09:25:36 +02:00
Albert ARIBAUD e825b100d2 Merge branch 'u-boot-pxa/master' into 'u-boot-arm/master' 2013-05-11 00:06:03 +02:00
Marek Vasut d782c1fe72 arm: mxs: video: Enable MXS LCDIF on M28EVK
Enable LCD output support on M28EVK.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Anatolij Gustschin <agust@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Anatolij Gustschin <agust@denx.de>
2013-05-06 17:40:23 +02:00
Marek Vasut fb8ddc2452 arm: mxs: Add MXS LCDIF driver
Add basic LCD driver for i.MX233 and i.MX28. This driver allows framebuffer
console and framebuffer logo.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Anatolij Gustschin <agust@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Anatolij Gustschin <agust@denx.de>
2013-05-06 17:40:22 +02:00
Marek Vasut 38e8ce4189 arm: mxs: Add LCDIF registers for i.MX233
Extend the regs-lcdif.h with registers for i.MX233.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
2013-05-06 17:40:22 +02:00
Marek Vasut 7411cdf0e2 arm: mxs: Add LCDIF clock configuration function
This function turns on the LCDIF clock and configures it's frequency. The
dividers settings are calculated within the function and the current
implementation should be fast and accurate.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
2013-05-06 17:40:22 +02:00
Benoît Thébaudeau 68088ceed7 imx: mx35pdk: Fix MUX2_CTR GPIO
MUX2_CTR is on GPIO1[5], not GPIO2[5], and it needs to be set high in order to
connect the FEC.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-06 15:21:59 +02:00
Michal Simek b03b25caea fpga: Remove all CONFIG_SYS_* fpga related options
All these macros are completely unused by any code.
CONFIG_FPGA is not a bitfield anymore.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:30 +02:00
Michal Simek 6631db4773 fpga: Check device name against bitstream name
Ensure that wrong bitstream won't be loaded
to current device.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:25 +02:00
Michal Simek d5dae85f23 fpga: zynq: Add support for loading bitstream
Devcfg device requires to load bitstream in binary format.
But u-boot also has an option for loading bitstream in bit
format. Let's handle both cases by zynqpl driver.
Also add suport for loading partial bitstreams.

The first driver version was done by:
Joe Hershberger <joe.hershberger@ni.com>

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:24 +02:00
Michal Simek 5bd0bd7cef cmd: fpga: Do not include net.h
There is no reason to include net.h header in fpga code.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:21 +02:00
Michal Simek 23f4bd756d fpga: Change the first parameter in fpga_loadbitstream
All fpga functions use devnum as int. Only fpga_loadbitstream
is using it as unsinged long dev.
This patch synchronize it.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:20 +02:00
Michal Simek 52c2064476 cmd: fpga: Move fpga_loadbitstream to fpga.c
In bitstream decoding you can directly check device
which you want to load and in fpga.c are fpga_validate
and fpga_dev_info functions which should be used for it.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:19 +02:00
Michal Simek fc598412ce cmd: fpga: Clean coding style
No functional changes.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:18 +02:00
Michal Simek ee976c1b03 fpga: Fix debug message compilation error
CONFIG_FPGA in past was a bitfield where bits
were use for vendor identification.

This fix should be the part of this commit:
"Improve configuration of FPGA subsystem"
(sha1: 0133502e39)

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:41:17 +02:00
Michal Simek f6555d90c1 fpga: Clean coding style
No functional changes.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@ti.com>
2013-05-06 10:40:53 +02:00
Marek Vasut 714dc001fc arm: mxs: Preprocess u-boot.bd so they contain full path
The u-boot-imx23.bd and u-boot-imx28.bd need to be preprocessed, otherwise
they have issues with out-of-tree build where elftosb tool couldn't sometimes
find the u-boot.bin and spl/u-boot-spl.bin .

Preprocess these .bd files with sed and insert full path to u-boot.bin and
spl/u-boot-spl.bin to prevent this issue. Moreover, to avoid adding more
churn into main Makefile, move all this preprocessing and u-boot.sb generation
into CPU directory instead.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Otavio Salvador <otavio@ossystems.com.br>
2013-05-06 10:37:36 +02:00
Marek Vasut dd3ecf020e arm: mx23: Fix VDDMEM misconfiguration
The VDDMEM ramped up in very weird way as it was horribly misconfigured.
Instead of setting up VDDMEM in one swipe, let it rise slowly the same
way as VDDD and VDDA in spl_power_init.c and then only clear ILIMIT before
memory gets inited. This makes sure the VDDMEM rises sanely, not jumps up
and down as it did till now.

The VDDMEM prior to this change did this:
     2V0____   .--------2V5
       |    `--'
 0V____|

The VDDMEM now does this:
    2V0_____,-----------2V5
      /
 0V__|

Moreover, VDDIO on MX23 uses 25mV steps while MX28 uses 50mV steps,
fix this difference too.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
2013-05-06 10:20:33 +02:00
Fabio Estevam 286a88cf34 mxs: Explain why some mx23 DDR registers are not configured
Put an explanation in the source code as to why some DDR registers do not
need to be configured.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
2013-05-06 09:55:52 +02:00
Fabio Estevam 0b323439a5 mx23_olinuxino: Do not set voltage selection bit for SSP pads
mx23 SSP pad registers do not contain voltage selection bit, so just remove it.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
2013-05-06 09:55:52 +02:00
Fabio Estevam 3d11444c42 mx23evk: Do not set voltage selection bit for SSP pads
mx23 SSP pad registers do not contain voltage selection bit, so just remove it.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
2013-05-06 09:55:51 +02:00
Fabio Estevam 26be20fac0 mx23: Operate DDR voltage supply at 2.5V
After the recent fixes in the mx23 DDR setup, it is safe to operate DDR voltage
at the recommended 2.5V voltage level again.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
2013-05-06 09:55:51 +02:00
Łukasz Dałek 66a62ce0dc h2200: Add board reset support
Use Samsung S3CA410X01 companion chip to reset PDA.

Signed-off-by: Lukasz Dalek <luk0104@gmail.com>
2013-05-05 23:47:05 +02:00
Łukasz Dałek 2ac2bb7ad2 pxa: Add weak attribute to reset_cpu() function
This commit allows pxa2xx based boards to reimplement reset_cpu()
function with board specific reset sequence.

Signed-off-by: Lukasz Dalek <luk0104@gmail.com>
2013-05-05 23:47:05 +02:00
Mike Dunn 956b03e180 mtd: nand: add driver for diskonchip g4 nand flash
This patch adds a driver for the diskonchip G4 nand flash device.  It is based
on the driver from the linux kernel.

This also includes a separate SPL driver.  A separate SPL driver is used because
the device operates in a different mode (reliable mode) when loading a boot
image, and also because the storage format of the boot image is different from
normal data (pages are stored redundantly).  The SPL driver basically mimics how
a typical IPL reads data from the device.  The special operating mode and
storage format are used to compensate for the fact that the IPL does not contain
the BCH ecc decoding algorithm (due to size constraints).  Although the u-boot
SPL *could* use ecc, it operates like an IPL for the sake of simplicity and
uniformity, since the IPL and SPL share the task of loading the u-boot image.
As a side benefit, the SPL driver is very small.

[port from linux kernel 3.4 commit 570469f3bde7f71cc1ece07a18d54a05b6a8775d]

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
2013-05-05 23:47:05 +02:00
Mike Dunn e0e89e236f pxa27x_udc: remove call to unimplemented set_GPIO_mode()
If CONFIG_USB_DEV_PULLUP_GPIO is defined, a link error occurs because the
set_GPIO_mode() helper function is not implemented.  This function doesn't do
much except make the code a little more readable, so I just manually coded its
equivalent and removed the prototype from the header file.  It is invoked no
where else in the code.

While I was at it, I noticed that two other function prototypes in the same
header file are also neither implemented nor invoked anywhere, so I removed them
as well.

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
2013-05-05 23:47:05 +02:00
Mike Dunn 86e929e825 pxa_lcd: make lcd_enable() a weak pointer
Make lcd_init() a weak pointer so that boards can overload it if necessary.  The
palmtreo680 board needs to wiggle some gpios and configure the pwm controller in
order to get the lcd and its backlight working.

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
2013-05-05 23:47:05 +02:00
Mike Dunn 98eda33858 pxa_lcd: add the ACX544AKN lcd device
This adds the definitions required to support the LCD device on the Palm Treo
680.

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
2013-05-05 23:47:05 +02:00
Mike Dunn 0dd9c7a924 lib: import bitrev library from the linux kernel
This patch adds the bitrev library from the linux kernel.  This is a simple
algorithm that uses an 8 bit look-up table to reverse the bits in data types of
8, 16, or 32 bit widths.  The docg4 nand flash driver uses it.

[port from linux kernel v3.9 commit 7ee32a6d30d1c8a3b7a07a6269da8f0a08662927]
[originally added: v2.6.20 by commit a5cfc1ec58a07074dacb6aa8c79eff864c966d12]

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
2013-05-05 23:47:04 +02:00
Benoît Thébaudeau ba5dfc11ba imx: mx5: Remove legacy iomux support
Legacy iomux support is no longer needed now that all boards have been converted
to iomux-v3.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Reviewed-by: Marek Vasut <marex@denx.de>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 3fec2c677e imx: m53evk: Convert to iomux-v3
There is no change of behavior, except for the folloing line that has been
removed because the iomux mode was not set accordingly and the pad used for OTG
OC is not this one:
	mxc_iomux_set_input(MX53_USBOH3_IPP_IND_OTG_OC_SELECT_INPUT, 1);

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 544544a060 imx: mx53smd: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 721d0b0026 imx: mx53loco: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 58f0764658 imx: mx53evk: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 5053b59300 imx: mx53ard: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 48f0108df9 imx: ima3-mx53: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:05 +02:00
Benoît Thébaudeau 3d53fc9450 imx: iomux-v3: Add iomux-mx53.h
Allow usage of the imx-common/iomux-v3.h framework by including pad settings for
the i.MX53. The content of the file is taken from Freescale's Linux kernel at
commit 4ab3715, plus the required changes to make it work in U-Boot.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau 6ea4217fd0 imx: vision2: Convert to iomux-v3
There is no change of behavior, except for older silicon revisions for which
support is removed.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau 3426a62a16 imx: mx51_efikamx/sb: Convert to iomux-v3
There is no change of behavior, except for older silicon revisions for which
support is removed.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Tested-by: Matt Sealey <matt@genesi-usa.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau 4d15d36c08 imx: mx51evk: Convert to iomux-v3
There is no change of behavior, except for older silicon revisions for which
support is removed.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau f54326d17d imx: iomux-v3: Add missing definitions to iomux-mx51.h
Add missing definitions that are required by future changes.

By the way, make some cosmetic cleanup.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau f49d92a35b imx: iomux-mx51: Fix MX51_PAD_EIM_CS2__GPIO2_27
In ALT1 mode, EIM_CS2 is GPIO2[27], not ESDHC1.CD. Hence, rename
MX51_PAD_EIM_CS2__SD1_CD to MX51_PAD_EIM_CS2__GPIO2_27.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau e2003c16c0 imx: mx35: Remove legacy iomux support
Legacy iomux support is no longer needed now that all boards have been converted
to iomux-v3.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau 8342cc37aa imx: woodburn: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:04 +02:00
Benoît Thébaudeau 105c9eaf9b imx: mx35pdk: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:03 +02:00
Benoît Thébaudeau 0f6829e111 imx: mx35pdk: Fix WDOG_RST iomux function
The signal connected from this pin to the PMIC is WDOG_B, i.e. ALT0 mode, not
ALT1 (which even corresponds to nothing).

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:03 +02:00
Benoît Thébaudeau 686e14488e imx: flea3: Convert to iomux-v3
There is no change of behavior.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:03 +02:00
Benoît Thébaudeau 52b9d3cfd3 imx: iomux-v3: Add iomux-mx35.h
Allow usage of the imx-common/iomux-v3.h framework by including pad settings for
the i.MX35. The content of the file is taken from Linux kernel at commit
267dd34, plus the required changes to make it work in U-Boot.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:03 +02:00
Benoît Thébaudeau 9e933b43f3 imx: mx25: Remove legacy iomux support
Legacy iomux support is no longer needed now that all boards have been converted
to iomux-v3.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-05-05 17:55:03 +02:00