aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* dtoc: Add support for 32 or 64-bit addressesSimon Glass2017-09-1513-6/+413
| | | | | | | | | | | | | | | | | | | | | | | | | | When using 32-bit addresses dtoc works correctly. For 64-bit addresses it does not since it ignores the #address-cells and #size-cells properties. Update the tool to use fdt64_t as the element type for reg properties when either the address or size is larger than one cell. Use the correct value so that C code can obtain the information from the device tree easily. Alos create a new type, fdt_val_t, which is defined to either fdt32_t or fdt64_t depending on the word size of the machine. This type corresponds to fdt_addr_t and fdt_size_t. Unfortunately we cannot just use those types since they are defined to phys_addr_t and phys_size_t which use 'unsigned long' in the 32-bit case, rather than 'unsigned int'. Add tests for the four combinations of address and size values (32/32, 64/64, 32/64, 64/32). Also update existing uses for rk3399 and rk3368 which now need to use the new fdt_val_t type. Signed-off-by: Simon Glass <sjg@chromium.org> Suggested-by: Heiko Stuebner <heiko@sntech.de> Reported-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Tested-by: Kever Yang <kever.yang@rock-chips.com>
* dtoc: Avoid very long lines in outputSimon Glass2017-09-152-3/+10
| | | | | | | | | Large arrays can result in lines with hundreds or thousands of characters which is not very editor-friendly. To avoid this, addjust the tool to group values 8 per line. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Kever Yang <kever.yang@rock-chips.com>
* dtoc: Add a 64-bit type and a way to convert cells into 64 bitsSimon Glass2017-09-153-1/+18
| | | | | | | | | | When dealing with multi-cell values we need a type that can hold this value. Add this and a function to process it from a list of cell values. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Tested-by: Kever Yang <kever.yang@rock-chips.com>
* dtoc: Adjust Node to record its parentSimon Glass2017-09-151-5/+7
| | | | | | | | | | We need to be able to search back up the tree for #address-cells and #size-cells. Record the parent of each node to make this easier. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Tested-by: Kever Yang <kever.yang@rock-chips.com>
* fdt: Sync libfdt up to upstreamSimon Glass2017-09-153-3/+106
| | | | | | | | | Add upstream changes to U-Boot: - new pylibfdt functions - fdt_setprop_placeholder() Signed-off-by: Simon Glass <sjg@chromium.org>
* Travis-CI: Switch back to using the top of tree dtcTom Rini2017-09-151-3/+2
| | | | | | | | | | | | | In a0f3e3df4adc we switched to using the Ubuntu-provided dtc as travis was having a problem with the number of warnings that were generated by the newer dtc. This is no longer a concern as we now have the same logic as Linux to enable/disable additional more stringent warnings. Go back to building dtc from source. Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org> Tested on travis-ci: Tested-by: Simon Glass <sjg@chromium.org>
* configs: at91: Remove CONFIG_SYS_EXTRA_OPTIONS assignmentWenyou Yang2017-09-1448-135/+102
| | | | | | | | To remove the assignment of CONFIG_SYS_EXTRA_OPTIONS option, which is deprecated, use the CONFIG_XXXX_BOOT options to indicate the boot media, and the SoC is selected by the board. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* ARM: at91: spl: Add macro CONFIG_XXXX_BOOT supportWenyou Yang2017-09-141-6/+10
| | | | | | | | Use the CONFIG_XXXX_BOOT to indicate the boot media, instead of the CONFIG_SYS_USE_XXXX option, which is declared by CONFIG_SYS_EXTRA_OPTIONS option. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* ARM: at91: Remove hardware.h included in configsWenyou Yang2017-09-1416-39/+39
| | | | | | | | | | As said in READRE.kconfig, include/configs/*.h will be removed after all options are switched to Kconfig. As the first step, remove the follow line from include/configs/*.h. #include <asm/hardware.h> Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* ARM: at91: Add the SoC options to KconfigWenyou Yang2017-09-141-27/+79
| | | | | | | | To prepare to remove the SoCs options such as SAMA5D2, SAMA5D3 and SAMA5D4 from the CONFIG_SYS_EXTRA_OPTIONS option which is deprecated, add the SoC options to Kconfig. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* ARM: at91: Move CONFIG_AT91FAMILY option to KconfigWenyou Yang2017-09-1411-43/+3
| | | | | | | Move the CONFIG_AT91FAMILY option from include/mach/<soc>.h header file to Kconfig. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* board: atmel: Add SAMA5D27 SOM1 EK boardWenyou Yang2017-09-1411-0/+809
| | | | | | | | | | | The SAMA5D27-SiP (System in Package) integrates the SAMA5D2 with 1Gbit DDR2-SDRAM in a single package. The SAMA5D27 SOM1 embeds a 64Mbit QSPI flash, KSZ8081 Phy and Mac-address EEPROM. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: at91: Get the Chip ID of SAMA5D2 SiPWenyou Yang2017-09-142-3/+30
| | | | | | | | The SAMA5D2 SiP(System in Package) has different Chip IDs in the CHIPID and CHIP_EXID registers. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: at91: mach: Add missing defines of MPDDRCWenyou Yang2017-09-141-0/+4
| | | | | | | Add missing defines of Multiport DDR-SDRAM Controller (MPDDRC). Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: at91: spl: Add boot device for boot from QSPIWenyou Yang2017-09-141-0/+2
| | | | | | | Add the boot device for booting from the QSPI flash. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* board: sama5d2_xplained: Make SPL work on spiflashWenyou Yang2017-09-142-1/+11
| | | | | | | | | | | | Because before switching to a lower clock source, we must switch the clock source first instead of last. So before configuring the PMC_MCKR register, invoke at91_mck_init_down() first. As said in datasheet, the the size of SPL must not exceed the maximum size allowed(64Kbytes). Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: at91: spl: Add mck function to lower rate while switchingWenyou Yang2017-09-142-0/+43
| | | | | | | | | | | | | | | Refer to the commit 70f8c8316ad(PMC: add new mck function to lower rate while switching) from AT91Bootstrap. While switching to a lower clock source, we must switch the clock source first instead of last. Otherwise, we could end up with too high frequency on internal bus and peripherals. This happens on SAMA5D2 as exitting from the ROM code. Add a function pmc_mck_init_down() to allow this sequence. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: at91: spl: Adjust switching to oscillator for SAMA5D2Wenyou Yang2017-09-142-1/+19
| | | | | | | | | As said in 29.5.7 section of SAMA5D2 datasheet, before switching to the crystal oscillator, a check must be carried out to ensure that the oscillator is present and that its freqency is valid. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* atmel: common: Add function to display via DM_VIDEO's APIWenyou Yang2017-09-143-0/+74
| | | | | | | | | Add a function to display the company's logo and board information via the API from DM_VIDEO. This function can be shared by other atmel boards, so locate it in board/atmel/common folder. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* lib: at91: Add logo files used via API of DM_VIDEOWenyou Yang2017-09-147-0/+2440
| | | | | | | | In order to display the company's logo via the API of DM_VIDEO, and add the logo files of both Atmel and Microchip. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* ARM: dts: at91: sama5: Add the sfr nodeWenyou Yang2017-09-142-0/+8
| | | | | | | | | | For sama5d2, add the sfr node with syscon support. In order to access the SFR_UTMICKTRIM register for the utmi clock driver, add the phandle property for the utmi node to point to the sfr node. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* clk: at91: utmi: Set the reference clock frequencyWenyou Yang2017-09-144-3/+88
| | | | | | | | | | | | | | | | | | | By default, it is assumed that the UTMI clock is generated from a 12 MHz reference clock (MAINCK). If it's not the case, the FREQ field of the SFR_UTMICKTRIM has to be updated to generate the UTMI clock in the proper way. The UTMI clock has a fixed rate of 480 MHz. In fact, there is no multiplier we can configure. The multiplier is managed internally, depending on the reference clock frequency, to achieve the target of 480 MHz. The patch is cloned from the patch of mailing-list: [PATCH v2] clk: at91: utmi: set the mainck rate Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> [trini: Depend on SPL_DM] Signed-off-by: Tom Rini <trini@konsulko.com>
* clk: Kconfig: Add dependences of SPL_CLKWenyou Yang2017-09-141-1/+1
| | | | | | | The SPL_CLK config should depend on SPL && SPL_DM. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* Merge git://git.denx.de/u-boot-dmTom Rini2017-09-131-3/+25
|\
| * patman: Fix error when the email blacklist is missingSimon Glass2017-09-131-3/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This section of the settings file may be missing. Handle that gracefully rather than emitting an error. Also update patman to write this section when a new settings file is created. Fixes: e11aa602 (patman: add support for omitting bouncing addresses) Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Chris Packham <judge.pckham@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
* | ARM: davinci: Update da8xxevm MaintainersAdam Ford2017-09-131-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | The e-mail addresses for DA8XXEVM BOARD and DA850_AM18XXEVM BOARD are invalid. Remove DA8XXEVM. Update DA850_AM18XXEVM to have me be the maintainer since I work for Logic PD and have access to OMAP-L138 and AM1808 EVM kits. Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com>
* | Convert CONFIG_EMIF4 et al to KconfigAdam Ford2017-09-1320-22/+22
| | | | | | | | | | | | | | | | | | | | This converts the following to Kconfig: CONFIG_EMIF4 CONFIG_SDRC Signed-off-by: Adam Ford <aford173@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stefano Babic <sbabic@denx.de>
* | Convert CONFIG_MAC_ADDR_IN_SPIFLASH et al to KconfigAdam Ford2017-09-135-5/+27
| | | | | | | | | | | | | | | | This converts the following to Kconfig: CONFIG_MAC_ADDR_IN_SPIFLASH CONFIG_MAC_ADDR_IN_EEPROM Signed-off-by: Adam Ford <aford173@gmail.com>
* | davinci: da850evm: Make EEPROM MAC code configurableAdam Ford2017-09-131-1/+4
| | | | | | | | | | | | | | | | | | | | | | There was a check for CONFIG_MAC_ADDR_IN_EEPROM and a check for CONFIG_MAC_ADDR_IN_SPIFLASH, however some of the EEPROM related code wasn't encapsulated inside the #if defined statement so the EEPROM code could get executed even when it wasn't explicitly enabled or wanted. Signed-off-by: Adam Ford <aford173@gmail.com>
* | include/configs: remove references to SMNAND_ENV_OFFSETAdam Ford2017-09-1315-44/+28
| | | | | | | | | | | | | | | | | | In mancy cases both CONFIG_ENV_OFFSET and CONFIG_ENV_ADDR point to an otherwise-unused SMNAND_ENV_OFFSET. This patch will set both CONFIG_ENV_OFFSET and CONFIG_ENV_ADDR to whatever value was defined by SMNAND_ENV_OFFSET. Signed-off-by: Adam Ford <aford173@gmail.com>
* | arm: dts: omap3: Re-sync DTS files with Linux 4.13-RC5Adam Ford2017-09-1313-3284/+3382
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The DTS files had some spacing issues and they needed fixing. This pull re-sync's the OMAP3xx related DTS files with Linux 4.13-RC5. To keep the DTS and DTSI files clean and in sync with Linux, new u-boot.dtsi files are added. Signed-off-by: Adam Ford <aford173@gmail.com> V3: The resync broke card detect on MMC1 on Logic PD's Torpedo, so we add the cd-invert to the Torpedo's -u-boot.dtsi file. V2: Add the u-boot.dtsi files for OMAP3, OMAP36xx, and Torpedo Remove the need for the second patch in the series
* | omap3: omap3_logic: Finish enabling fastboot on MUSBAdam Ford2017-09-132-1/+33
| | | | | | | | | | | | | | | | Either the USB and Fastboot were never finished, or somehow it got lost. This puts enough hooks back into omap3logic to enable fastboot and hopefully prepare it for Kconfig conversion. Signed-off-by: Adam Ford <aford173@gmail.com>
* | ARM: dts: ethernut5: Fix the build warningWenyou Yang2017-09-131-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Fix the building warning as below: ---8<---- Warning (reg_format): "reg" property in /i2c-gpio-0/pcf8563@50 has invalid length (4 bytes) (#address-cells == 2, #size-cells == 1) Warning (avoid_default_addr_size): Relying on default #address-cells value for /i2c-gpio-0/pcf8563@50 Warning (avoid_default_addr_size): Relying on default #size-cells value for /i2c-gpio-0/pcf8563@50 --->8---- Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com> Reviewed-by: Tom Rini <trini@konsulko.com>
* | serial: nulldev: Add nulldev serial driverKeng Soon Cheah2017-09-133-0/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some device the serial console's initialization cannot run early during the boot process. Hence, nulldev serial device is helpful on that situation. For example, if the serial module was implemented in FPGA. Serial initialization is prohibited to run until the FPGA was programmed. This commit is to adding nulldev serial driver. This will allows the default console to be specified as a nulldev. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Signed-off-by: Keng Soon Cheah <keng.soon.cheah@ni.com> Cc: Chen Yee Chew <chen.yee.chew@ni.com>
* | spl: add newline in debug outputAnatolij Gustschin2017-09-131-2/+2
|/ | | | | | | | With debug enabled, SPL output following these debug prints is on the same line and it is hard to read. Fix it. Signed-off-by: Anatolij Gustschin <agust@denx.de> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
* ARM: DRA72x: Add support for detection of DRA71x SR 2.1Vishal Mahaveer2017-09-126-0/+12
| | | | | | | | | DRA71x processors are reduced pin and software compatible derivative of DRA72 processors. Add support for detection of SR2.1 version of DRA71x family of processors. Signed-off-by: Vishal Mahaveer <vishalm@ti.com> Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
* davinci: da850-evm: switch to using TI_COMMON_CMD_OPTIONSAdam Ford2017-09-124-26/+37
| | | | | | | | Like the OMAP-L138 LCDK before it, let's move the da850-evm and the variations to TI_COMMON_CMD_OPTIONS to cut back one some of the defconfig entries. Signed-off-by: Adam Ford <aford173@gmail.com>
* linux/io.h: import generic ioread* / iowrite* accessors from LinuxMasahiro Yamada2017-09-121-0/+44
| | | | | | | | Some drivers in Linux (ex. drivers/mtd/nand/denali.c) use ioread*/iowrite* accessors. Import them to make drivers more synced. I copied code from include/asm-generic/io.h of Linux. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* dma: import linux/dma-direction.h to consolidate enum dma_data_directionMasahiro Yamada2017-09-127-25/+20
| | | | | | | | Import include/linux/dma-direction.h from Linux 4.13-rc7 and delete duplicated definitions of enum dma_data_direction. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
* omap3: am3517_evm: Enable TI_COMMON_CMD_OPTIONAdam Ford2017-09-122-14/+9
| | | | | | | | Enable TI_COMMON_CMD_OPTIONS and remove similar options from the defconfig. Updated with savedefconfig. Signed-off-by: Adam Ford <aford173@gmail.com> Tested-by: Derald D. Woods <woods.technical@gmail.com>
* ARM: OMAP3: am3517_evm: Move header to ti_omap3_common.hAdam Ford2017-09-121-43/+10
| | | | | | | | | | | | Much of the AM3517 functions are copies of the standard definitions used in ti_omap3_common.h. Moving to include a common file reduces the amount of duplicative code and clutter. A few AM3517 specific functions (like EMIF4) are explictly defined and a few items are undefined or redefined, but overall the number of lines of code shink. Signed-off-by: Adam Ford <aford173@gmail.com> Tested-by: Derald D. Woods <woods.technical@gmail.com>
* armv8: mmu: add space around operatorAndy Yan2017-09-121-1/+1
| | | | | | | | | Add space around operator "+", make it match the coding style. Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: York Sun <york.sun@nxp.com>
* armv8: mmu: remove unused macro definitionAndy Yan2017-09-122-11/+0
| | | | | | | | | Macro VA_BITS and PTE_BLOCK_BITS are not used in the code, so remove them. Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: York Sun <york.sun@nxp.com>
* cosmetic: bootcount: correct comment for used scratch registerTomas Melin2017-09-121-3/+3
| | | | Signed-off-by: Tomas Melin <tomas.melin@vaisala.com>
* misc: i2c_eeprom: Add compatible for AT24MAC402Wenyou Yang2017-09-121-0/+1
| | | | | | | | | | Add the new compatible "atmel,24mac402" to accommodate AT24MAC402. The AT24MAC402 is a 2K Serial EEPROM and the 2-Kbit memory array is internally organized as 16 pages of 16 bytes of EEPROM each. The 48-bit EUI address in the AT24MAC402 are located in the extended memory block. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* misc: i2c_eeprom: Add compatible for 24AA02E48Wenyou Yang2017-09-121-0/+1
| | | | | | | | Add the new compatible "microchip,24aa02e48" to accommodate 24AA02E48, the 24AA02E48 is a 2K I2C Serial EEPROM with pre-programmed globally unique, 48-bit node address, and 8-byte page size. Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
* configs: k2g_evm: Remove PMMC loading environment commandsAndrew F. Davis2017-09-121-1/+0
| | | | | | | The PMMC firmware should be bundled with the FIT image for HS devices, remove the steps that load and install this firmware outside of FIT. Signed-off-by: Andrew F. Davis <afd@ti.com>
* ARM: k2g: Add FIT image handler for PMMC firmwareAndrew F. Davis2017-09-121-0/+21
| | | | | | | | The PMMC firmware should be bundled into a FIT image on HS devices to allow authentication/decryption, add a handler to process this PMMC firmware. Signed-off-by: Andrew F. Davis <afd@ti.com>
* image: Add TI PMMC image typeAndrew F. Davis2017-09-122-0/+2
| | | | | | | Add a new image type representing TI Power Management Micro-Controller (PMMC) Firmware image type. Signed-off-by: Andrew F. Davis <afd@ti.com>
* examples: add fallback memcpyRob Clark2017-09-121-0/+12
| | | | | | | | | | | | | | | | | | | Solves build issue: Building current source for 134 boards (12 threads, 1 job per thread) arm: + lsxhl +examples/api/vsprintf.o: In function `string16': +lib/vsprintf.c:278: undefined reference to `memcpy' +examples/api/uuid.o: In function `uuid_bin_to_str': +lib/uuid.c:197: undefined reference to `memcpy' +lib/uuid.c:199: undefined reference to `memcpy' +make[3]: *** [examples/api/demo] Error 1 +make[2]: *** [examples/api] Error 2 +make[1]: *** [examples] Error 2 +make: *** [sub-make] Error 2 133 0 1 /134 sheevaplug Signed-off-by: Rob Clark <robdclark@gmail.com>