summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-04-14Convert CONFIG_FSL_DCU_FB to KconfigSanchayan Maity
Rename CONFIG_FSL_DCU_FB to CONFIG_VIDEO_FSL_DCU_FB and convert it to Kconfig. Signed-off-by: Sanchayan Maity <maitysanchayan@gmail.com> Reviewed-by: Stefan Agner <stefan.agner@toradex.com> Reviewed-by: Alison Wang <alison.wang@nxp.com>
2017-04-14mmc: sdhci: Wait for SDHCI_INT_DATA_END when transferring.Alex Deymo
sdhci_transfer_data() function transfers the blocks passed up to the number of blocks defined in mmc_data, but returns immediately once all the blocks are transferred, even if the loop exit condition is not met (bit SDHCI_INT_DATA_END set in the STATUS word). When doing multiple writes to mmc, returning right after the last block is transferred can cause the write to fail when sending the MMC_CMD_STOP_TRANSMISSION command right after the MMC_CMD_WRITE_MULTIPLE_BLOCK command, leaving the mmc driver in an unconsistent state until reboot. This error was observed in the rpi3 board. This patch waits for the SDHCI_INT_DATA_END bit to be set even after sending all the blocks. Test: Reliably wrote 2GiB of data to mmc in a rpi3. Signed-off-by: Alex Deymo <deymo@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-14mmc: bcm2835_sdhci: Speed up mmc writes.Jocelyn Bohr
The linux kernel driver for this module does not use a delay when writing to the SDHCI_BUFFER register. This patch mimics that behavior in order to speed up the mmc writes on the Raspberry Pi. Signed-off-by: Alex Deymo <deymo@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-14mmc: gen_atmel_mci: add driver model support for mciWenyou Yang
Add the driver model support for Atmel mci while retaining the existing legacy code. This allows the driver to support boards that have converted to driver model as well as those that have not. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-14odroid-c2: enable new Meson GX MMC driver in board defconfigHeiner Kallweit
Enable new Meson GX MMC driver in Odroid C2 defconfig. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
2017-04-14mmc: meson: add MMC driver for Meson GX (S905)Carlo Caione
This driver implements MMC support on Meson GX (S905) based systems. It's based on Carlo Caione's work, changes: - BLK support added - general refactoring Signed-off-by: Carlo Caione <carlo@caione.org> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Tested-by: Vagrant Cascadian <vagrant@debian.org>
2017-04-14arm: dts: update Meson GXBB / Odroid-C2 DT with recent Linux versionHeiner Kallweit
As a prerequisite for adding a Meson GX MMC driver update the Meson GXBB / Odroid-C2 device tree in Uboot with the latest version from Linux. Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Carlo Caione <carlo@endlessm.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
2017-04-13Merge git://git.denx.de/u-boot-dmTom Rini
Here with some DM changes as well as the long-standing AT91 DM/DT conversion patches which I have picked up via dm.
2017-04-13board: sama5d4ek: enable early debug UARTWenyou Yang
Enable the early debug UART to debug problems when an ICE or other debug mechanism is not available. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13board: sama5d4ek: clean up codeWenyou Yang
Due to the introduction of the pinctrl and clk driver, and using device tree files, remove the unneeded hardcoded pin configuration and clock enabling code from the board file. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13board: sama5d4ek: update to support DM/DTWenyou Yang
Update the configuration files to support the device tree and driver model, so do SPL. The device clock and pins configuration are handled by the clock and the pinctrl drivers respectively. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13board: sama5d4_xplained: enable early debug UARTWenyou Yang
Enable the early debug UART to debug problems when an ICE or other debug mechanism is not available. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13board: sama5d4_xplained: clean up codeWenyou Yang
Due to the introduction of the pinctrl and clk driver, and using device tree files, remove the unneeded hardcoded pin configuration and clock enabling code from the board file. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13board: sama5d4_xplained: update to support DM/DTWenyou Yang
Update the configuration files to support the device tree and driver model, so do SPL. The device clock and pins configuration are handled by the clock and the pinctrl drivers respectively. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13configs: at91-sama5_common: fix for CONFIG_AT91_GPIOWenyou Yang
Add #ifndef CONFIG_DM_GPIO for CONFIG_AT91_GPIO define to avoid the redefine compilation error. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13ARM: at91: lds: use "_image_binary_end" for DT locationWenyou Yang
The MMC SPL locates the BSS section to a different memory region from text, then use "_image_binary_end" variable to point to the correct device tree location. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: spl: atmel: move mem_init() advance in SPL init.Wenyou Yang
Because the MMC SPL puts the bbs section in the ddr memory, move calling mem_init() before calling spl_init(). Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: spl: atmel: bring in serial device before initWenyou Yang
Before setting up the serial communications, bring in the serial device from the device tree file. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: at91: spl: specify MMC and NAND boot deviceWenyou Yang
When OF_CONTROL is enabled, MMC boot device should not be detected automatically, it should be MMC1 fixedly only the status "enabled" is available. Add NAND Flash boot device as well. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: dts: at91: add dts file for sama5d4ekWenyou Yang
Add the device tree file for sama5d4ek board. The dts file is copied from Linux-4.4, do the following changes. - add the "u-boot,dm-pre-reloc" property to determine which nodes which are needed by SPL and by the board_init_f stage. - fix the compilation warning. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: dts: at91: add dts files for sama5d4 XplainedWenyou Yang
Add the device tree files for sama5d4 Xplained board. The dts files are copied from Linux-4.4, do the following changes. - add reg property for pinctrl node. - move the gpio nodes(pioA, pioB, pioC ...) from the pinctrl child's nodes to its slibling nodes. - add the "u-boot,dm-pre-reloc" property to determine which nodes which are needed by SPL and by the board_init_f stage. - fix the compilation warnings. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: at91: dt: add dts file for sama5d3 XplainedWenyou Yang
Add the device tree file for sama5d3 Xplained board. The dts files are copied from the Linux-4.9, do changes as below. - add the "u-boot,dm-pre-reloc" property to determine which nodes which are needed by SPL and by the board_init_f stage. - fix the compile warning. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13ARM: at91: dt: add dts files for sama5d3xek boardWenyou Yang
Add the device tree files for sama5d3xek board. The dts files are copied from Linux-4.9, do the changes as below. - add reg property for the pinctrl node. - move the gpio nodes (pioA, pioB, pioC ...) as the pinctrl's slibling nodes. - add the "u-boot,dm-pre-reloc" property to determine which nodes which are needed by SPL and by the board_init_f stage. - fix the compile warning. - add spi0 node aliases. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
2017-04-13gpio: at91_gpio: add the clock supportWenyou Yang
Add the clock support. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13gpio: at91_gpio: add the device tree supportWenyou Yang
Add the device tree support. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13gpio: Kconfig: add CONFIG_AT91_GPIO optionWenyou Yang
The CONFIG_AT91_GPIO option is used to select AT91 PIO GPIO driver. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Andreas Bießmann <andreas@biessmann.org>
2017-04-13pinctrl: at91: add pinctrl driverWenyou Yang
AT91 PIO controller is a combined gpio-controller, pin-mux and pin-config module. The peripheral's pins are assigned through per-pin based muxing logic. Each SoC will have to describe the its limitation and pin configuration via device tree. This will allow to do not need to touch the C code when adding new SoC if the IP version is supported. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13gpio: at91_gpio: remove CPU_HAS_PIO3 macroWenyou Yang
The intention of the removal is the preparation to introduce the new AT91 PIO pinctrl driver. Use the union to make the PIO3 and PIO2's registers be together and make their offset aligned. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13mtd: nand: atmel: use another functions to set gpio valueWenyou Yang
Because there isn't the implementation of gpio_set/get_value() and gpio_set/get_value() after the at91 gpio driver is converted to support the driver model, use at91_set_gpio_value() and at91_get_gpio_value() Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13ARM: at91: gpio: fix at91_set_gpio_value() defineWenyou Yang
When the CONFIG_ATMEL_LEGACY is undefined, according to the following defines, at91_set_gpio_value() references to at91_set_pio_value(x, y) with two parameters. #define at91_set_gpio_value(x, y) at91_set_pio_value(x, y) #define at91_get_gpio_value(x) at91_get_pio_value(x) But there isn't the implementation of at91_set_pio_value(x, y) with two parameters in U-Boot. This is an error. Same as at91_get_gpio_value(x) define. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13buildman: Handle commit subjects containing unicodeSimon Glass
One of these has crept in in this commit: 40a808f1 ARCv2: SLC: Make sure busy bit is set properly on SLC flushing Adjust buildman to handle it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-13tools: allow to override pythonStefano Babic
Not force to use python from PATH. Issue was noted when building with Yocto, because python from the distro is always taken instead of python-native built during Yocto process. Signed-off-by: Stefano Babic <sbabic@denx.de> CC: Simon Glass <sjg@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13dm: core: Ensure DMA regions start up with the cache cleanSimon Glass
There is a strange interaction with drivers which use DMA if the cache starts off in a dirty state. Buffer space which the driver reads (but has not previously written) can contain zero bytes from alloc_priv(). This can cause corruption of the memory used by DMA for incoming data. Fix this and add a comment to explain the problem. This allows the dwc2 driver to work correctly with driver model, for example. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-13core/uclass: Print name of device in uclass_find_device_by_seq()Alexandru Gagniuc
uclass_find_device_by_seq() prints seq and req_seq when debugging is enabled, but this information is not very useful by itself. Add the name of he driver to this information. This improves debugging as it shows which devices are being considered. Signed-off-by: Alexandru Gagniuc <alex.g@adaptrum.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-04-13fdtgrep: Cope with the /aliases node being lastSimon Glass
With skeleton.dtsi being dropped it is more likely that the /aliases node will be last in the device tree. Update fdtgrep to handle this. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-04-13dtoc: Decode val if it's a byte stringGeorge McCollister
With Python 3.5.2 encode will throw an exception if val is a byte array. Decode it to a string first. This assumes it's utf-8, if it's not valid utf-8 it will throw an exception. Signed-off-by: George McCollister <george.mccollister@gmail.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-04-13patman: Convert byte arrays to stringsGeorge McCollister
os.read() returns a byte array in Python 3.5.2 and needs to be converted into a string. Check if the returned value is an instance of bytes and if it is decode it as a utf-8 string. If it is not a utf-8 encoded string the decoding may fail with an exception. Prior to this fix the comparisions check data == "" would fail when data was b'' and would cause an infinite memory leaking loop. joins would also fail with an exception below but due to the infinite loop it never made it that far. Signed-off-by: George McCollister <george.mccollister@gmail.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-04-13serial: ns16550: Link in the DM driver when when using platdataAlexandru Gagniuc
Do not condition the compilation of the U_BOOT_DRIVER by !OF_PLATDATA. This is inconsistent with the majority of other drivers. This also blocks OF_PLATDATA boards with an 16550-compatible serial from using serial in SPL. Signed-off-by: Alexandru Gagniuc <alex.g@adaptrum.com> Reviewed-by: Simon Glass <sjg@chromium.org> Added tweak for rock to avoid a TPL build failure: Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-13Merge branch 'master' of git://www.denx.de/git/u-boot-imxTom Rini
Drop CONFIG_STACKSIZE from include/configs/imx6_logic.h Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-13lib: div64: sync with LinuxPeng Fan
Sync with Linux commit ad0376eb1483b ("Merge tag 'edac_for_4.11_2'"). Signed-off-by: Peng Fan <peng.fan@nxp.com> Cc: Tom Rini <trini@konsulko.com>
2017-04-13sandbox: Change CONFIG_SANDBOX_BITS_PER_LONG to hard-codedTom Rini
Instead of having CONFIG_SANDBOX_BITS_PER_LONG in sandbox.h set to 64 with a comment to change to 32 on a 32bit host, simply set this to 64 in asm/types.h and have the comment be there. Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-13tiny-printf: Add support for %p formatVignesh R
Add support for %p, %pa[p], %pM, %pm and %pI4 formats to tiny-printf. %pM and %pI4 are widely used by SPL networking stack and is required if networking support is desired in SPL. %p, %pa and %pap are mostly used by debug prints and hence supported only when DEBUG is enabled. Before this patch: $ size spl/u-boot-spl text data bss dec hex filename 99325 4899 218584 322808 4ecf8 spl/u-boot-spl After this patch (with CONFIG_SPL_NET_SUPPORT): $ size spl/u-boot-spl text data bss dec hex filename 99666 4899 218584 323149 4ee4d spl/u-boot-spl So, this patch adds ~350 bytes to code size. If CONFIG_SPL_NET_SUPPORT is not enabled, this adds ~25 bytes. If CONFIG_USE_TINY_PRINTF is disabled then: $ size spl/u-boot-spl text data bss dec hex filename 101116 4899 218584 324599 4f3f7 spl/u-boot-spl So, there is still ~1.4K space saved even with support for %pM/%pI4. Compiler used is to build is: arm-linux-gnueabihf-gcc (Linaro GCC 6.2-2016.11) 6.2.1 20161016 Signed-off-by: Vignesh R <vigneshr@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-04-13pci: Add a command to show PCI regionsSimon Glass
Add 'pci regions' which lists the I/O and memory regions accessible from the PCI controller. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-13Fix a bug with PL010s running at 19200 baudAlyssa Rosenzweig
I don't have the hardware test this, but it is almost certainly a typo in the code dating back to at least 2004. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
2017-04-13board_f: Rename initdram() to dram_init()Simon Glass
This allows us to use the same DRAM init function on all archs. Add a dummy function for arc, which does not use DRAM init here. Signed-off-by: Simon Glass <sjg@chromium.org> [trini: Dummy function on nios2] Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-12arm: freescale: Rename initdram() to fsl_initdram()Simon Glass
This function name shadows a global name but is in fact different. This is very confusing. Rename it to help with the following refactoring. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-12debug_uart: Try not to use stack in printchtim.chick
Spam detection software, running on the system "lists.denx.de", has identified this incoming email as possible spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Previous change to create _printch causes the stack to be used, breaking printch before stack is available. Inline _printch to prevent this happening. Signed-off-by: Tim Chick <tim.chick@mediatek.com> --- [...] Content analysis details: (6.3 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.7 RCVD_IN_XBL RBL: Received via a relay in Spamhaus XBL [188.29.165.105 listed in zen.spamhaus.org] 3.6 RCVD_IN_PBL RBL: Received via a relay in Spamhaus PBL 1.6 RCVD_IN_BRBL_LASTEXT RBL: No description available. [188.29.165.105 listed in bb.barracudacentral.org] 0.4 RDNS_DYNAMIC Delivered to internal network by host with dynamic-looking rDNS Previous change to create _printch causes the stack to be used, breaking printch before stack is available. Inline _printch to prevent this happening. Signed-off-by: Tim Chick <tim.chick@mediatek.com>
2017-04-12env: fix memory leak in fw_env routinesStefano Babic
fw_env_open allocates buffers to store the environment, but these buffers are never freed. This becomes quite nasty using the fw_ tools as library, because each access to the environment (even just reading a variable) generates a memory leak equal to the size of the environment. Fix this renaming fw_env_close() as fw_env_flush(), because the function really flushes the environment from RAM to storage, and add a fw_env_close function to free the allocated resources. Signed-off-by: Stefano Babic <sbabic@denx.de>
2017-04-12env: add a version number to check APIStefano Babic
Changes in the environment library are difficult to tracked by programs using the library. Add simply an API version number that must be increased each time when the API is changed. This can be detected and a program can work with different versions of the library. Signed-off-by: Stefano Babic <sbabic@denx.de>
2017-04-12env: split fw_env.h in public and private partsStefano Babic
Move U-Boot private data into a separate file. This lets export fw_env.h to be used by external programs that want to change the environment using the library built in tools/env. Signed-off-by: Stefano Babic <sbabic@denx.de>