summaryrefslogtreecommitdiff
path: root/arch
AgeCommit message (Collapse)Author
2014-07-24colibri_vf: disable automatic boot when using recovery modeColibri_VF_LinuxImageV2.3Beta1_20140804Apalis_iMX6_LinuxImageV2.3Beta1_20140804Stefan Agner
Since we use the same UART to download U-Boot and get the U-Boot prompt, it is quite hard to switch between the download program and the terminal emulator within the boot delay. This patch disables the automatic boot by setting the bootdelay to -1 when using the recovery mode (serial downloader).
2014-07-24vf610: improve CPU type detectionStefan Agner
Detect VF5xx CPU's by reading the CPU count register. Also we can guess the second number of the CPU type (VF6x0) which indicates the presence of a L2 cache.
2014-07-23colibri vf50/61: detect bad blocks in U-Boot areaStefan Agner
The boot ROM was not able to detect bad blocks in the U-Boot area due to disabled "bad block marking swap" functionality. The description of this field is a bit unclear, but tests show that skipping bad blocks in U-Boot area only work if this field is set to 0.
2014-07-17vf610: enable external 32KHz oscillatorStefan Agner
Enable the SCSC (Slow Clock Source Controller) and select the external 32KHz oscillator. This improves accuracy of the RTC.
2014-04-24colibri_vf: add detection for Colibri VF50Stefan Agner
Detect Colibri VF50 modules by read L2 cache configuration of the running CPU. Colibri VF50 modules come without L2 cache. Configure CPU clock accordingly.
2014-04-24arm: vf610: initial integration for Colibri VF61Stefan Agner
This adds initial support for Colibri VF61 based on Freescale Vybrid Tower System TWR-VF65GS10: - New Machine ID - Default UART_A on SCI0 - FEC1 - Enabled command line editing - PLL5 based RMII clocking (e.g. no external crystal) - UART_A and UART_C I/O muxing - Boot from OCRAM gfxRAM Tested on Colibri VF61 V1.1 booting using serial loader over UART.
2014-04-24imx: add u-boot-nand.imx targetStefan Agner
Add an additional target which prepends the u-boot.imx image with 0x400 padding bytes. On Vybrid, this is required for NAND boot devices. The configuration CONFIG_IMX_NAND enables this image for a board.
2014-04-23imx: add writebcb commandStefan Agner
Add writebcb command which creates a NAND Boot Configuration Block at the beginning of the active flash device. The offset of the boot firmware are specified using arguments, at least one location is mandatory. Currently only the FCB (Firmware Configuration Block) is supported, the DBBT (Discovered Bad Block Table) is optional and is not used currently. The firmware, e.g. U-Boot (along with the IVT header and a 0x400 long prefix) need to be written to NAND seperatly.
2014-04-23arm: vf610: add NFC pin muxStefan Agner
Add pin mux for NAND Flash Controller.
2014-04-23arm: vf610: add NFC clock supportStefan Agner
Add NFC (NAND Flash Controller) clock support and enable them at board initialization time.
2014-04-23arm: vf610: add DDR_SEL_PAD_CONTR registerStefan Agner
Set DDR_SEL_PAD_CONTR register explicitly to DDR3 which solves DDR3 issues with newer silicon (1.1). This register was added in revision 4 of the Vybrid Reference Manual.
2014-04-08Merge branch 'u-boot/master' into 'u-boot-arm/master'Albert ARIBAUD
Conflicts: arch/arm/cpu/arm926ejs/mxs/Makefile include/configs/trats.h include/configs/trats2.h include/mmc.h
2014-04-08arm64 patch: gicv3 supportDavid Feng
This patch add gicv3 support to uboot armv8 platform. Changes for v2: - rename arm/cpu/armv8/gic.S with arm/lib/gic_64.S - move smp_kick_all_cpus() from gic.S to start.S, it would be implementation dependent. - Each core initialize it's own ReDistributor instead of master initializeing all ReDistributors. This is advised by arnab.basu <arnab.basu@freescale.com>. Signed-off-by: David Feng <fenghua@phytium.com.cn>
2014-04-07bootstage: arm: fix fdt stashing codeMela Custodio
The conditional is using a variable that is not defined. Signed-off-by: Rommel G Custodio <sessyargc+u-boot@gmail.com>
2014-04-07ARMv8: fix bug for flush data cache by set/wayLeo Yan
When flush the d$ with set/way instruction, it need calculate the way's offset = log2(Associativity); but in current uboot's code, it use below formula to calculate the offset: log2(Associativity * 2 - 1), so finally it cannot flush data cache properly. Signed-off-by: Leo Yan <leoy@marvell.com>
2014-04-07armv8: Flush dcache before switching to EL2York Sun
For ARMv8, U-boot has been running at EL3 with cache and MMU enabled. Without proper setup for EL2, cache and MMU are both disabled (out of reset). Before switching, we need to flush the dcache to make sure the data is in the main memory. Signed-off-by: York Sun <yorksun@freescale.com> Acked-by: David.Feng <fenghua@phytium.com.cn>
2014-04-07arm: vf610: add enet1 supportMarcel Ziswiler
This patch contains several changes required for second Ethernet (enet1/RMII1) port on vf610 - ANADIG PLL5 control definitions required for Ethernet RMII1 clock - Secondary Ethernet (enet1) MAC RMII1 base address definition - RMII1 iomux definitions - VF610_PAD_PTA6__RMII0_CLKOUT iomux definition required for internal (e.g. crystal-less) Ethernet clocking. Signed-off-by: Marcel Ziswiler <marcel@ziswiler.com> [stefan@agner.ch: regrouped patch] Signed-off-by: Stefan Agner <stefan@agner.ch>
2014-04-07arm: vf610: add uart0 clock/iomux definitionsMarcel Ziswiler
Add CCM_CCGR0_UART0_CTRL_MASK clock definition and add TX/RX iomux definitions for UART0 (aka. SCI0). Signed-off-by: Marcel Ziswiler <marcel@ziswiler.com> [stefan@agner.ch: regrouped patch] Signed-off-by: Stefan Agner <stefan@agner.ch>
2014-04-07arm: vf610: fix anadig register structMarcel Ziswiler
The anadig_reg structure started at the wrong offset (fixed by adding reserved_0x000[4]), was missing some reserved field required for alignment purpose (reserved_0x094[3] between pll4_denom and pll6_ctrl) and further contained a too short reserved field causing further miss- alignment (reserved_0x0C4[7]). Also, rename all the reserved fields and using a memory offset based scheme for. Discovered and tested by temporarily putting the following debug instrumentation into board_init(): struct anadig_reg *anadig = (struct anadig_reg *)ANADIG_BASE_ADDR; printf("&anadig->pll3_ctrl=0x%p\n", &anadig->pll3_ctrl); printf("&anadig->pll5_ctrl=0x%p\n", &anadig->pll5_ctrl); Signed-off-by: Marcel Ziswiler <marcel@ziswiler.com> [stefan@agner.ch: regrouped patch] Signed-off-by: Stefan Agner <stefan@agner.ch>
2014-04-07build:arm: Remove setting of CROSS_COMPILE environment variableŁukasz Majewski
After Kbuild introduction, the CROSS_COMPILE environment variable has been set to some default value (prefix arm-linux-). This shall be removed since it breaks building u-boot for native arm target (like qemu ARM). Moreover not all compilers have arm-linux- prefix. Additionally the u-boot cross compiles with CROSS_COMPILE= set explicitly- e.g.: CROSS_COMPILE=/ .... /arm-v7a-linux-gnueabi- make Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Cc: Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
2014-04-07Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'Albert ARIBAUD
2014-04-07ARM: Add workaround for Cortex-A9 errata 761320Nitin Garg
Full cache line writes to the same memory region from at least two processors might deadlock the processor. Exists on r1, r2, r3 revisions. Signed-off-by: Nitin Garg <nitin.garg@freescale.com> Acked-by: Fabio Estevam <fabio.estevam@freescale.com>
2014-04-07ARM: Add workaround for Cortex-A9 errata 794072Nitin Garg
A short loop including a DMB instruction might cause a denial of service on another processor which executes a CP15 broadcast operation. Exists on r1, r2, r3, r4 revisions. Signed-off-by: Nitin Garg <nitin.garg@freescale.com> Acked-by: Dirk Behme <dirk.behme@de.bosch.com>
2014-04-07armv8/cache: Change cache invalidate and flush functionYork Sun
When SoC first boots up, we should invalidate the cache but not flush it. We can use the same function for invalid and flush mostly, with a wrapper. Invalidating large cache can ben slow on emulator, so we postpone doing so until I-cache is enabled, and before enabling D-cache. Signed-off-by: York Sun <yorksun@freescale.com> CC: David Feng <fenghua@phytium.com.cn>
2014-04-07armv8/cache: Flush D-cache, invalidate I-cache for relocationYork Sun
If D-cache is enabled, we need to flush it, and invalidate i-cache before jumping to the new location. This should be done right after relocation. Signed-off-by: York Sun <yorksun@freescale.com> CC: David Feng <fenghua@phytium.com.cn>
2014-04-07armv8/cache: Consolidate setting for MAIR and TCRYork Sun
Move setting for MAIR and TCR to cache_v8.c, to avoid conflict with sub-architecture. Signed-off-by: York Sun <yorksun@freescale.com> CC: David Feng <fenghua@phytium.com.cn>
2014-04-07arm: Handle .gnu.hash section in ldscriptsAndreas Färber
Avoids "could not find output section .gnu.hash" ld.bfd errors on openSUSE. Cc: Albert Aribaud <albert.u.boot@aribaud.net> Cc: Tom Rini <trini@ti.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
2014-04-07socfpga: Adding Clock Manager driverChin Liang See
Clock Manager driver will be called to reconfigure all the clocks setting based on user input. The input are passed to Preloader through handoff files Signed-off-by: Chin Liang See <clsee@altera.com> Cc: Albert Aribaud <albert.u.boot@aribaud.net> Cc: Tom Rini <trini@ti.com> Cc: Wolfgang Denk <wd@denx.de> CC: Pavel Machek <pavel@denx.de> Cc: Dinh Nguyen <dinguyen@altera.com> Acked-by: Pavel Machek <pavel@denx.de>
2014-04-04arm: mxs: Add support for generating signed BootStreamMarek Vasut
This patch adds the groundwork for generating signed BootStream, which can be used by the HAB library in i.MX28. We are adding a new target, u-boot-signed.sb , since the process for generating regular non-signed BootStream is much easier. Moreover, the signed bootstream depends on external _proprietary_ _binary-only_ tool from Freescale called 'cst', which is available only under NDA. To make things even uglier, the CST or HAB mandates a kind-of circular dependency. The problem is, unlike the regular IVT, which is generated by mxsimage, the IVT for signed boot must be generated by hand here due to special demands of the CST. The U-Boot binary (or SPL binary) and IVT are then signed by the CST as a one block. But here is the problem. The size of the entire image (U-Boot, IVT, CST blocks) must be appended at the end of IVT. But the size of the entire image is not known until the CST has finished signing the U-Boot and IVT. We solve this by expecting the CST block to be always 3904B (which it is in case two files, U-Boot and the hand-made IVT, are signed in the CST block). Signed-off-by: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
2014-04-04Merge branch 'master' of git://git.denx.de/u-boot-arm into masterStefano Babic
Conflicts: arch/arm/cpu/arm926ejs/mxs/mxsimage.mx23.cfg arch/arm/cpu/arm926ejs/mxs/mxsimage.mx28.cfg Signed-off-by: Stefano Babic <sbabic@denx.de>
2014-04-04Revert "arm: mxs: Add support for generating signed BootStream"Stefano Babic
This reverts commit 53e6b14e037c9f72e6d03244c32d8d597e2e0234. Patch does not merge anymore with u-boot-arm and must be rebased. Signed-off-by: Stefano Babic <sbabic@denx.de>
2014-04-02mmc:eSDHC: Workaround for data timeout issue on Txxx SoCHaijun.Zhang
1. The Data timeout counter value in eSDHC_SYSCTL register is not working as it should be, so add quirks to enable this workaround to fix it to the max value 0xE. 2. Add CONFIG_SYS_FSL_ERRATUM_ESDHC111 to enable its workaround. * Update of patch for change mmc interface by Pantelis Antoniou <panto@antoniou-consulting.com> Signed-off-by: Haijun Zhang <Haijun.Zhang@freescale.com> Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2014-04-02mx6: add example DTB for mx6qsabreautoStefano Babic
Signed-off-by: Stefano Babic <sbabic@denx.de> CC: Fabio Estevam <fabio.estevam@freescale.com>
2014-04-02imx: add rules for U-Boot DTB supportStefano Babic
Signed-off-by: Stefano Babic <sbabic@denx.de>
2014-04-02mxs: fix warning in SPL with console supportStefano Babic
Signed-off-by: Stefano Babic <sbabic@denx.de>
2014-04-01arm: mxs: Add serial console support into SPLMarek Vasut
Add support for serial console into the i.MX23/i.MX28 SPL. A full, uncrippled serial console support comes very helpful when debugging various spectacular hardware bringup issues early in the process. Because we do not use SPL framework, but have our own minimalistic SPL, which is compatible with the i.MX23/i.MX28 BootROM, we do not use preloader_console_init(), but instead use a similar function to start the console. Nonetheless, to avoid blowing up the size of the SPL binary, this support is enabled only if CONFIG_SPL_SERIAL_SUPPORT is defined, which is disabled by default. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
2014-04-01arm: mxs: Properly set GD pointer in SPLMarek Vasut
Set the GD pointer in the SPL to a defined symbol so various functions from U-Boot can be used without adverse side effects. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
2014-03-31arm: mxs: Add support for generating signed BootStreamMarek Vasut
This patch adds the groundwork for generating signed BootStream, which can be used by the HAB library in i.MX28. We are adding a new target, u-boot-signed.sb , since the process for generating regular non-signed BootStream is much easier. Moreover, the signed bootstream depends on external _proprietary_ _binary-only_ tool from Freescale called 'cst', which is available only under NDA. To make things even uglier, the CST or HAB mandates a kind-of circular dependency. The problem is, unlike the regular IVT, which is generated by mxsimage, the IVT for signed boot must be generated by hand here due to special demands of the CST. The U-Boot binary (or SPL binary) and IVT are then signed by the CST as a one block. But here is the problem. The size of the entire image (U-Boot, IVT, CST blocks) must be appended at the end of IVT. But the size of the entire image is not known until the CST has finished signing the U-Boot and IVT. We solve this by expecting the CST block to be always 3904B (which it is in case two files, U-Boot and the hand-made IVT, are signed in the CST block). Signed-off-by: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
2014-03-31arm: mxs: Adjust the load address of U-Boot and SPL for HABMarek Vasut
When using HAB, there are additional special requirements on the placement of U-Boot and the U-Boot SPL in memory. To fullfill these, this patch moves the U-Boot binary a little further from the begining of the DRAM, so the HAB CST and IVT can be placed in front of the U-Boot binary. This is necessary, since both the U-Boot and the IVT must be contained in single CST signature. To make things worse, the IVT must be concatenated with one more entry at it's end, that is the length of the entire CST signature, IVT and U-Boot binary in memory. By placing the blocks in this order -- CST, IVT, U-Boot, we can easily align them all and then produce the length field as needed. As for the SPL, on i.MX23/i.MX28, the SPL size is limited to 32 KiB, thus we place the IVT at 0x8000 offset, CST right past IVT and claim the size is correct. The HAB library accepts this setup. Finally, to make sure the vectoring in SPL still works even after moving the SPL from 0x0 to 0x1000, we add a small function which copies the vectoring code and tables to 0x0. This is fine, since the vectoring code is position independent. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
2014-03-31tegra: fix Makefile to pass per-file CFLAGSMasahiro Yamada
Since Kbuild was introduced, warmboot_avp.o has been compiled without -march=armv4t. Makefile should be adjusted to pass a per-file option. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Stephen Warren <swarren@nvidia.com> Cc: Tom Warren <twarren@nvidia.com>
2014-03-28cpu: exynos4: add ace sha base addressPrzemyslaw Marczak
Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com> Cc: Minkyu Kang <mk7.kang@samsung.com>
2014-03-28spl: Fix guardian macros in spl.hMarek Vasut
Fix the macros guarding the spl.h header for various platforms. Due to a typo and a propagation of it, the macros went out-of-sync with their ifdef check, so fix this. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Tom Rini <trini@ti.com>
2014-03-28kbuild: move asm-offsets.c from SoC directory to arch/$(ARCH)/libMasahiro Yamada
U-Boot has supported two kinds of asm-offsets.h. One is generic for all architectures and its source is located at ./lib/asm-offsets.c. The other is SoC specific and its source is under SoC directory. The problem here is that only boards with SoC directory can use the asm-offsets infrastructure. Putting asm-offsets.c right under CPU directory does not work. Now a new demand is coming. PowerPC folks want to use asm-offsets. But no PowerPC boards have SoC directory. It seems inconsistent that some boards add asm-offsets.c to SoC directoreis and some to CPU directories. It looks more reasonable to put asm-offsets.c under arch/$(ARCH)/lib. This commit merges asm-offsets.c under SoC directories into arch/$(ARCH)/lib/asm-offsets.c. By the way, I doubt the necessity of some entries in asm-offsets.c. I am leaving refactoring to the board maintainers. Please check "TODO" in the comment blocks in arch/{arm,nds32}/lib/asm-offsets.c. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Yuantian Tang <Yuantian.Tang@freescale.com>
2014-03-28kbuild: Rename UIMAGE to MKIMAGEMarek Vasut
U-Boot uses the 'mkimage' tool to produce various image types, not only uImage image type. Rename the invocation name from UIMAGE to MKIMAGE. The following command was used to do the replacement: git grep 'quiet_cmd_mkimage.* = UIMAGE' | cut -d : -f 1 | \ xargs -i sed -i "s@\(quiet_cmd_mkimage\)\(.*\) = UIMAGE @\1\2 = MKIMAGE@" {} Signed-off-by: Marek Vasut <marex@denx.de> Cc: Tom Rini <trini@ti.com> Cc: Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
2014-03-25Merge branch 'u-boot/master' into 'u-boot-arm/master'Albert ARIBAUD
Trivial merge conflict, needed to manually remove local_info as per commit 41364f0f. Conflicts: board/samsung/common/board.c
2014-03-24mmc: Split mmc struct, rework mmc initialization (v2)Pantelis Antoniou
The way that struct mmc was implemented was a bit of a mess; configuration and internal state all jumbled up in a single structure. On top of that the way initialization is done with mmc_register leads to a lot of duplicated code in drivers. Typically the initialization got something like this in every driver. struct mmc *mmc = malloc(sizeof(struct mmc)); memset(mmc, 0, sizeof(struct mmc); /* fill in fields of mmc struct */ /* store private data pointer */ mmc_register(mmc); By using the new mmc_create call one just passes an mmc config struct and an optional private data pointer like this: struct mmc = mmc_create(&cfg, priv); All in tree drivers have been updated to the new form, and expect mmc_register to go away before long. Changes since v1: * Use calloc instead of manually calling memset. * Mark mmc_register as deprecated. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2014-03-17sandbox: Add options to clean up temporary filesSimon Glass
When jumping from one sandbox U-Boot to another in sandbox, the RAM buffer is preserved in the jump by using a temporary file. Add an option to tell the receiving U-Boot to remove this file when it is no longer needed. Similarly the old U-Boot image is left behind in this case. We cannot delete it immediately since gdb cannot then find its debug symbols. Delete it just before exiting. Together these changes ensure that temporary files are removed both for memory and U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-03-17sandbox: Allow Ctrl-C to work in sandboxSimon Glass
It is useful for Cltl-C to be handled by U-Boot as it is on other boards. But it is also useful to be able to terminate U-Boot with Ctrl-C. Add an option to enable signals while in raw mode, and make this the default. Add an option to leave the terminal cooked, which is useful for redirecting output. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-03-17sandbox: Add LCD driverSimon Glass
Add a simple LCD driver which uses SDL to display the image. We update the image regularly, while still providing for reasonable performance. Adjust the common lcd code to support sandbox. For command-line runs we do not want the LCD to be displayed, so add a --show_lcd option to enable it. Tested-by: Che-Liang Chiou <clchiou@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
2014-03-17sandbox: Add a simple sound driverSimon Glass
Add a sound driver for sandbox, which uses SDL. Tested-by: Che-Liang Chiou <clchiou@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>