summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeLines
* dm: Add basic testsSimon Glass2014-03-04-0/+1426
| | | | | | | | | | | | | | | | | | | | Add some tests of driver model functionality. Coverage includes: - basic init - binding of drivers to devices using platform_data - automatic probing of devices when referenced - availability of platform data to devices - lifecycle from bind to probe to remove to unbind - renumbering within a uclass when devices are probed/removed - calling driver-defined operations - deactivation of drivers when removed - memory leak across creation and destruction of drivers/uclasses - uclass init/destroy methods - automatic probe/remove of children/parents when needed This function is enabled for sandbox, using CONFIG_DM_TEST. Signed-off-by: Simon Glass <sjg@chromium.org>
* dm: Set up driver model after relocationSimon Glass2014-03-04-0/+33
| | | | | | | | Make driver model available after relocation, by setting up data structures and scanning for devices using compiled-in platform_data and (when available) the device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
* sandbox: config: Enable driver modelSimon Glass2014-03-04-0/+1
| | | | | | Use driver model in sandbox to permit running of driver model unit test. Signed-off-by: Simon Glass <sjg@chromium.org>
* dm: Add base driver model supportSimon Glass2014-03-04-0/+1601
| | | | | | | | | | | | | | | | Add driver model functionality for generic board. This includes data structures and base code for registering devices and uclasses (groups of devices with the same purpose, e.g. all I2C ports will be in the same uclass). The feature is enabled with CONFIG_DM. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Marek Vasut <marex@denx.de> Signed-off-by: Pavel Herrmann <morpheus.ibis@gmail.com> Signed-off-by: Viktor Křivák <viktor.krivak@gmail.com> Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
* dm: Add README for driver modelSimon Glass2014-03-04-0/+368
| | | | | | This adds a README to help with understanding of this series. Signed-off-by: Simon Glass <sjg@chromium.org>
* yaffs: Remove private list implementationSimon Glass2014-03-04-127/+1
| | | | | | | | | | | | | | | | | | U-Boot already has a list implementation, and files which include both that and the yaffs implementation will get errors: In file included from ydirectenv.h:80:0, from yportenv.h:81, from yaffs_guts.h:19, from yaffs_allocator.h:19, from yaffs_allocator.c:14: yaffs_list.h:32:8: error: redefinition of ‘struct list_head’ struct list_head { ^ Remove the yaffs implementation. Signed-off-by: Simon Glass <sjg@chromium.org>
* Add cmd_process_error() to report and process errorsSimon Glass2014-03-04-0/+19
| | | | | | | | | | | | U-Boot now uses errors defined in include/errno.h which are negative integers. Commands which fail need to report the error and return 1 to indicate failure. Add this functionality in cmd_process_error(). For now this merely reports the error number. It would be possible also to produce a helpful error message by storing the error strings in U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org>
* sandbox: Build a device tree file for sandboxSimon Glass2014-03-04-0/+35
| | | | | | | | | | | | Add support for building a device tree for sandbox's CONFIG_OF_HOSTFILE option to make it easier to use device tree with sandbox. This adjusts the Makefile to build a u-boot.dtb file which can be passed to sandbox U-Boot with: ./u-boot -d u-boot.dtb Signed-off-by: Simon Glass <sjg@chromium.org>
* sizes.h - consolidate for all architecturesAlexey Brodkin2014-03-04-90/+98
| | | | | | | | | | | | | | | | Copied from Linux sources "include/linux/sizes.h" commit 413541dd66d51f791a0b169d9b9014e4f56be13c Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Vineet Gupta <vgupta@synopsys.com> Cc: Tom Rini <trini@ti.com> Cc: Stefan Roese <sr@denx.de> Cc: Albert Aribaud <albert.u.boot@aribaud.net> Acked-by: Tom Rini <trini@ti.com> Acked-by: Stefan Roese <sr@denx.de> [trini: Add bcm Kona platforms to the patch] Signed-off-by: Tom Rini <trini@ti.com>
* nand_spl: display warning message to inform the end of nand_splMasahiro Yamada2014-03-04-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now we have two different frameworks for doing the same thing. I'd like to propose to drop nand_spl framework. How about deleting it before v2014.07 release? In the interim, this commit will display a warning message when compiling nand_spl board. Now we have 19 nand_spl boards: MPC8315ERDB_NAND SIMPC8313_LP SIMPC8313_SP MPC8536DS_NAND MPC8569MDS_NAND MPC8572DS_NAND P1023RDS_NAND P1011RDB_NAND P1020RDB_NAND P2010RDB_NAND P2020RDB_NAND acadia_nand bamboo_nand canyonlands_nand glacier_nand haleakala_nand kilauea_nand rainier_nand sequoia_nand They must be ported to SPL before the deadline, otherwise they will be removed. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Dave Liu <daveliu@freescale.com> Cc: Ron Madrid <info@sheldoninst.com> Cc: Roy Zang <tie-fei.zang@freescale.com> Cc: Stefan Roese <sr@denx.de> Acked-by: Stefan Roese <sr@denx.de>
* m68k: merge compile flags -ffixed-d7 -sep-dataMasahiro Yamada2014-03-04-10/+2
| | | | | | | | | All arch/m68k/cpu/*/config.mk define the same flags PLAGFORM_REFLFLAGS += -ffixed-d7 -msep-data Move it to arch/m68k/config.mk Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Jason Jin <Jason.jin@freescale.com>
* sh: merge compiler flag -ffixed-r13Masahiro Yamada2014-03-04-3/+1
| | | | | | | | -ffixed-r13 is defined commonly for sh2, sh3, sh4. Move it to arch/sh/config.mk Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
* sh: Do not define -ffreestanding twiceMasahiro Yamada2014-03-04-1/+1
| | | | | | | | -ffreestanding is defined at the top Makefile for all architectures. Do not define it twice for SH2A. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
* x86: Delete redundant compiler flagsMasahiro Yamada2014-03-04-4/+1
| | | | | | | | | | | -Wstrict-prototypes, -ffreestanding, -fno-stack-protector are defined at the top Makefile for all architectures. Do not define them twice for x86. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org>
* nand_spl: simpc8313: move config.mk used only for nand_splMasahiro Yamada2014-03-04-0/+2
| | | | | | | board/sheldon/simpc8313/config.mk is used only for nand_spl. So it should go into nand_spl/board/sheldon/simpc8313/. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
* Makefile: delete unused variable LDSCRIPT_MAKEFILE_DIRMasahiro Yamada2014-03-04-4/+0
| | | | | | LDSCRIPT_MAKEFILE_DIR is not referenced from anywhere. Remove. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
* config.mk: Delete unused variable BCURDIRMasahiro Yamada2014-03-04-2/+0
| | | | | | | This variable was abolished by Kbuild series. I forgot to delete it. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
* kbuild: post: fix dependency tracking correctlyMasahiro Yamada2014-03-04-1/+1
| | | | | | | $(call if_changed,...) must take FORCE as a prerequite. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by: Simon Glass <sjg@chromium.org>
* serial: zynq: Add OF initialization supportMichal Simek2014-03-04-0/+28
| | | | | | | Add console selection from DTB which is enough to have OF driven solution. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* zynq: Add OF ram initialization supportMichal Simek2014-03-04-1/+21
| | | | | | Read ram size directly from DTB. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* mmc: zynq: Add OF initialization supportMichal Simek2014-03-04-0/+30
| | | | | | Enable initialize sdhci from DTB. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* net: gem: Add OF initialization supportMichal Simek2014-03-04-0/+43
| | | | | | Gem can be directly initialized from DTB. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* zynq: Do not use SPL OF initializationMichal Simek2014-03-04-0/+1
| | | | | | Disable CONFIG_OF_CONTROL for SPL compilation. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* net: emaclite: Fix OF initializationMichal Simek2014-03-04-8/+10
| | | | | | | | - Add xilinx_emaclite_of_init to netdev.h - Remove global data pointer from the driver - Add better handling for error state. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
* Merge branch 'master' of git://git.denx.de/u-boot-armTom Rini2014-02-26-608/+5960
|\ | | | | | | | | | | | | | | | | Conflicts: arch/arm/cpu/armv7/config.mk board/ti/am43xx/mux.c include/configs/am43xx_evm.h Signed-off-by: Tom Rini <trini@ti.com>
| * arm: Switch to -mno-unaligned-access when supported by the compilerTom Rini2014-02-26-138/+248
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we tell the compiler to optimize for ARMv7 (and ARMv6 for that matter) it assumes a default of SCTRL.A being cleared and unaligned accesses being allowed and fast at the hardware level. We set this bit and must pass along -mno-unaligned-access so that the compiler will still breakdown accesses and not trigger a data abort. To better help understand the requirements of the project with respect to unaligned memory access, the Documentation/unaligned-memory-access.txt file has been added as doc/README.unaligned-memory-access.txt and is taken from the v3.14-rc1 tag of the kernel. Cc: Albert ARIBAUD <albert.u.boot@aribaud.net> Cc: Mans Rullgard <mans@mansr.com> Signed-off-by: Tom Rini <trini@ti.com>
| * checkpatch.pl: Add warning for new __packed additionsTom Rini2014-02-26-0/+5
| | | | | | | | | | | | | | While there are valid reasons to use __packed, often the answer is that you should be doing something else here instead. Signed-off-by: Tom Rini <trini@ti.com>
| * arm: remove unneeded symbol offsets and _TEXT_BASEAlbert ARIBAUD2014-02-26-369/+24
| | | | | | | | | | | | | | | | Remove the last uses of symbol offsets in ARM U-Boot. Remove some needless uses of _TEXT_BASE. Remove all _TEXT_BASE definitions. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
| * arm: make _end compiler-generatedAlbert ARIBAUD2014-02-26-29/+117
| | | | | | | | | | | | | | | | | | This prevents references to _end from generating absolute relocation records. This change is binary invariant for ARM targets. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
| * cm_t335: fix linker file to produce full ELFAlbert ARIBAUD2014-02-26-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Newly added cm_t335 was missed in commit 47ed5dd0 which made ARM targets produce full ELF files. Fix its linker script. This change is binary-invariant when only .dynsym, .dynstr, .dynamic, .plt, .interp and .gun sections are declared. Sections .hash, .got.plt, .dynbss and .ARM.exidx are also declared so that their (unused) content is moved out of the u-boot binary. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
| * Merge branch 'u-boot-ti/master' into 'u-boot-arm/master'Albert ARIBAUD2014-02-24-36/+2323
| |\
| | * ti814x: Fix illegal use of FP ops in clock_ti814x.cMåns Rullgård2014-02-21-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | The function pll_sigma_delta_val uses "float" data which is not correct. The exact "why" of this mangling is lost to history, but this changes us to equivalent non-FP math to get the same results. Reported-by: Wolfgang Denk <wd@denx.de> Acked-by: Matt Porter <mporter@linaro.org>
| | * omap4_common: config: remove I2C for SPL modeNishanth Menon2014-02-21-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 6789e84ecaa8f45d053084e08c381284a04abff7 (i2c, omap24xx: convert driver to new mutlibus/mutliadapter framework) intended to make I2C driver compatible with latest changes. It unfortunately has had a impact on size on SPL as well. For example on SDP4430, 32032 bytes before/MLO 35416 bytes after/MLO With this mentioned commit, MLO stops booting on SDP4430 as only 32K is accessible for non-secure (bootloader) s/w on GP devices and the size increase to 56K fails boot. On the latest u-boot commit e7be18225fbea76d1f0034b224f0d1e60f07cfcf, MLO is now at size 35592 bytes, However, I2C is not necessary for SPL to function as we use SR_I2C for controlling the PMIC. Disabling I2C reduces MLO to 32224 bytes which allows OMAP4 GP platform to boot up. Since this is common for all OMAP4 platforms, remove the need for I2C for SPL builds in the common config. Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Sricharan R <r.sricharan@ti.com>
| | * dra7xx_evm: Enable GPT commandsTom Rini2014-02-21-0/+11
| | | | | | | | | | | | Signed-off-by: Tom Rini <trini@ti.com>
| | * am43xx_evm: Enable GPT commandsTom Rini2014-02-21-0/+9
| | | | | | | | | | | | Signed-off-by: Tom Rini <trini@ti.com>
| | * am335x_evm: Enable GPT commandsTom Rini2014-02-21-0/+12
| | | | | | | | | | | | Signed-off-by: Tom Rini <trini@ti.com>
| | * arm: omap: cm_t35: Remove CONFIG_SYS_BOOTMAPSZ to fix FDT Linux bootingStefan Roese2014-02-21-7/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With CONFIG_SYS_BOOTMAPSZ defined, recent Linux kernel booting results in this error: Booting using the fdt blob at 0x81f00000 Loading Kernel Image ... OK ERROR: Failed to allocate 0x1189d bytes below 0x80004000. device tree - allocation error FDT creation failed! hanging...### ERROR ### Please RESET the board ### Removing this define solves this issue. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Nikita Kiryanov <nikita@compulab.co.il> Cc: Igor Grinberg <grinberg@compulab.co.il> Cc: Tom Rini <trini@ti.com>
| | * DRA7: fix ABB efuse offset for OPP_NOMNishanth Menon2014-02-21-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | commit 194dd74ad919e57026f385aaab7f89acf7ea79ef (DRA7: add ABB setup for MPU voltage domain) Made an offset typo error by using 0x4A003B24 as the efuse offset for OPP_NOM. As per TI documentation, 0x4A003B24 is for OPP_OD, and 0x4A003B20 is for OPP_NOM. Fix the same. Reported-by: Praveen Rao <prao@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com>
| | * ARM: OMAP4: fix DDR timings for OMAP4430 ES2.0Janne Grunau2014-02-21-0/+18
| | | | | | | | | | | | | | | | | | | | | DDR timings were broken since 47abc3df701d8bc26f311350aa523fc1d0f8ad4e for PandaBoard EA1. Signed-off-by: Janne Grunau <j@jannau.net>
| | * OMAP3: fix default environment for mcx boardStefano Babic2014-02-21-4/+3
| | | | | | | | | | | | | | | | | | Patch allows to load a script at the startup from MMC. Signed-off-by: Stefano Babic <sbabic@denx.de>
| | * omap3: fix pinmux for mcx boardStefano Babic2014-02-21-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New hardware version cannot recognize the SD-Card because the SYS_NRESWARM, set as GPIO, does not guarantee the required reset time. Change the pin function back to enable the SYS_NRESWARM signal driven by the SOC. Signed-off-by: Stefano Babic <sbabic@denx.de>
| | * OMAP3: add missing gpio clock init and fix NAND SPL for mcx boardStefano Babic2014-02-21-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patch contains the same fixes as commit 4b9b2c300a23ca4a85811918dc92e822a9571a87 (missing CONFIG_OMAP3_GPIO_2) and commit f9095aac793aa8917ab9b915c5d449e6dc8d3d30 (missing CONFIG_SPL_NAND_SOFTECC). Same issues are relevant for the mcx board, too. Signed-off-by: Stefano Babic <sbabic@denx.de>
| | * arm: omap3: Fix tao3530/omap3_ha SPL boot hangup (GPIO clocks not enabled)Stefan Roese2014-02-21-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patch f33b9bd3 [arm: omap3: Enable clocks for peripherals only if they are used] breaks SPL booting on tao3530. Since some gpio input's are read to detect the board revision. But with this patch above, the clocks to the GPIO subsystems are not enabled per default any more. The GPIO banks need to be configured specifically now. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Tom Rini <trini@ti.com> Cc: Michael Trimarchi <michael@amarulasolutions.com> Reviewed-by: Stefano Babic <sbabic@denx.de>
| | * ARM: AM43xx: GP-EVM: Correct GPIO used for VTT regulator controlDave Gerlach2014-02-21-15/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Schematic indicates GPIO5_7 is to be used for VTT regulator control rather than GPIO0_21 so modify enable_vtt_regulator to reflect this. Without this some boards will experience DDR3 corruption and fail to boot. Signed-off-by: Dave Gerlach <d-gerlach@ti.com> [trini: Rework patch against mainline] Signed-off-by: Tom Rini <trini@ti.com>
| | * Add support for B&R KWB MotherboardHannes Petermaier2014-02-21-2/+580
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds support for Bernecker & Rainer Industrieelektronik GmbH KWB Motherboard, using TI's AM3352 SoC. Most of code is derived from TI's AM335x_EVM Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Cc: trini@ti.com
| | * board: Add support for B&R T-Series MotherboardHannes Petermaier2014-02-21-0/+1089
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adds support for Bernecker & Rainer Industrieelektronik GmbH T-Series Motherboard, using TI's AM3352 SoC. Most of code is derived from TI's AM335x_EVM Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>
| | * am335x: Initial support for Silica Pengwyn boardLothar Felten2014-02-21-1/+559
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch add support for the Silica Pengwyn board [1] The board is based on a TI AM3354 CPU [2] All jumpers removed it will boot from the SDcard, the console is on UART1 accessible via the FDTI -> USB. The on board NAND flash is supported and can act as boot medium, depending on jumper settings. USB Host, USB Device and Ethernet are also provided but untested. [1] http://www.silica.com/product/silica-pengwyn-board.html [2] http://www.ti.com/product/am3354 Signed-off-by: Lothar Felten <lothar.felten@gmail.com> [trini: Move CONFIG_BOARD_LATE_INIT into am335x_evm.h, drop unused spi0_pin_mux from Pengwyn support] Signed-off-by: Tom Rini <trini@ti.com>
| * | board: bcm28155_ap: Add board filesDarwin Rambo2014-02-22-0/+235
| | | | | | | | | | | | | | | | | | | | | | | | Add support for the bcm28155_ap reference board. Signed-off-by: Darwin Rambo <drambo@broadcom.com> Reviewed-by: Steve Rae <srae@broadcom.com> Reviewed-by: Tim Kryger <tkryger@linaro.org>
| * | mmc: kona: Add Kona mmc driverDarwin Rambo2014-02-22-0/+135
| | | | | | | | | | | | | | | | | | | | | | | | Add support for the Kona SDHCI found on Broadcom mobile SoCs. Signed-off-by: Darwin Rambo <drambo@broadcom.com> Reviewed-by: Steve Rae <srae@broadcom.com> Reviewed-by: Tim Kryger <tkryger@linaro.org>
| * | i2c: kona: Add Kona I2C driverDarwin Rambo2014-02-22-0/+731
| | | | | | | | | | | | | | | | | | | | | | | | Add support for the Kona I2C controller found on Broadcom mobile SoCs. Signed-off-by: Darwin Rambo <drambo@broadcom.com> Reviewed-by: Steve Rae <srae@broadcom.com> Reviewed-by: Tim Kryger <tkryger@linaro.org>