summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-06-09cmd/fdt: support single value replacement within an arrayHannes Schmelzer
With this commit we can modify single values within an array of a dts property. This is useful if we have for example a pwm-backlight where we want to modifiy the pwm frequency per u-boot script. The pwm is described in dts like this: backlight { pwms = <0x0000002b 0x00000000 0x004c4b40>; }; For changing the frequency, here the 3rd parameter, we simply type: fdt set /backlight pwms <? ? 0x1E8480>; For doing all this we: - backup the property content into our 'SCRATCHPAD' - only modify the array-cell if the new content doesn't start with '?' Signed-off-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09buildman: properly translate strings for log and err files to ASCIIDaniel Schwierzeck
The build output can still produce unicode encoded output. But in the buildman's log and err files we only want plain ASCII characters. To handle all situations with unicode and non-unicode output, encode the stdout and stderr strings to UTF-8 and afterwards to ASCII with replacing all special characters. Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
2017-06-09buildman: disable localized and unicode output of all build toolsDaniel Schwierzeck
Build tools like Make, gcc or binutils support localized output or unicode encoded output dependent on the default system locale. This is not useful for buildman, where we want reproducible warning or error messages or where the output of binutils is further processed. Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
2017-06-09README: Add instructions for chain-loading U-Boot on jerrySimon Glass
Add instructions for chromebook_jerry. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: jerry: Disable CONFIG_CONSOLE_SCROLL_LINESSimon Glass
The display on jerry is so fast that this option is not needed. Drop it so that the display scrolls more smoothly. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: Enable the video display bannerSimon Glass
Show the U-Boot banner and board information on the video display during boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: rk3288: Allow setting up clocks in U-Boot properSimon Glass
If U-Boot is chain-loaded from a previous boot loader we must set up the clocks the way U-Boot wants them. Add code for this. It will do nothing if SPL has already done the job. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: Init clocks again when chain-loadingSimon Glass
Detect with a previous boot loader has already set up the clocks and set them up again so that U-Boot gets what it expects. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: rk3288: Convert clock driver to use shifted masksSimon Glass
Shifted masks are the standard approach with rockchip since it allows use of the mask without shifting it each time. Update the definitions and the driver to match. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: jerry: Add a .its file for chromiumSimon Glass
Add a sample .its file for booting U-Boot on a jerry Chromebook. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: video: Take the vop device out of standbySimon Glass
On reset the standby bit is clear, but if U-Boot is chain-loaded from another boot loader it may be set. Clear it before starting up video so that it works correctly. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de> Squashed in 'rockchip: video: fix taking the VOP device out of standby': Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09rockchip: video: Add remove() methodsSimon Glass
Add remove() methods for EDP and VOP so that U-Boot can shut down the video on exit. This avoids leaving DMA running while booting Linux which can cause problems if Linux uses the frame buffer for something else. It also makes it clear what is needed to shut down video. While we are here, make rkvop_enable() static. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de> Squashed in 'rockchip: video: fix taking the VOP device out of standby': Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09rockchip: rk3288: Add error debugging to veyron_init()Simon Glass
Add a debug() statement so we can see when something goes wrong with the regulator. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: Fix regualtor typo in veyronSimon Glass
This typo doesn't actually cause any problems, but is wrong. Fix it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: Setup default PWM flagsSimon Glass
At present if the Signed-off-by: Simon Glass <sjg@chromium.org> Fixes: 874ee59 (rockchip: pwm: implement pwm_set_invert())
2017-06-09README: Add instructions for chain-loading U-BootSimon Glass
Most Chromebooks support chain-loading U-Boot but instructions are somewhat scattered. Add a README to hold this information within the U-Boot tree. Also add the standard developer keys to simplify the instructions, since they are small. For now this only supports nyan-big. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: nyan-big: Add a .its file for chromiumSimon Glass
Add a sample .its file for booting U-Boot on a nyan-big Chromebook. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: clock: Avoid a divide-by-zero errorSimon Glass
The clock fix-up for tegra is still present in the code. It causes a divide-by-zero bug after relocation when chain-loading U-Boot from coreboot. Fix this by adding a check. Signed-off-by: Simon Glass <sjg@chromium.org> Fixes: 7468676 (ARM: tegra: fix clock_get_periph_rate() for UART clocks)
2017-06-09tegra: Enable CP15 initSimon Glass
At present CP15 init is disabled on tegra. Use the correct option so that this init is performed on boot. This enables the instruction cache, for example, which is critical to the machine running at full speed. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: video: Don't power up the SOR twiceSimon Glass
If U-Boot is the secondary boot loader, or has been run from itself, the SOR may already be powered up. Powering it up again causes a hang, so detect this situation and skip it. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-06-09tegra: nyan-big: Enable the dhrystone benchmarkSimon Glass
Enable this so we can roughly measure CPU performance. Also enable the cache command to allow for timing. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: spi: Wait a little after setting the clocksSimon Glass
For devices that need a delay between SPI transactions we seem to need an additional delay before the first one if the CPU is running at full speed. Add this, under control of the existing setting. At present it will only be enabled with the Chrome OS EC. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: dts: Add cros-ec SPI settingsSimon Glass
At present the interrupt does not work and the SPI bus runs much less quickly than it should. Add settings to fix this. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09tegra: Init clocks even when SPL did not runSimon Glass
At present early clock init happens in SPL. If SPL did not run (because for example U-Boot is chain-loaded from another boot loader) then the clocks are not set as U-Boot expects. Add a function to detect this and call the early clock init in U-Boot proper. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09power: regulator: Add more debugging and fix a missing newlineSimon Glass
This file does not report a few possible errors and one message is missing a newline. Fix these. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
2017-06-09arm: Disable LPAE if not enabledSimon Glass
If CONFIG_ARMV7_LPAE is not defined we should make sure that the feature is disabled. This can happen if U-Boot is chain-loaded from another boot loader which does enable LPAE. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09arm: Don't try to support CONFIG_ARMV7_LPAE on ARMv4TSimon Glass
At present if CONFIG_ARMV7_LPAE is defined then mmu_setup() will use instructions which are invalid on ARMv4T. This happens on Tegra since it has an ARMv4T boot CPU. Add a check for the architecture version to allow the code to be built. It will not actually be executed by the boot CPU, but needs to compile. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09arm: Rename HCTR to HTCRSimon Glass
This appears to be a typo. Fix it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09arm: arm720t: Support CONFIG_SKIP_LOWLEVEL_INIT_ONLYSimon Glass
This option allows skipping the call to lowlevel() while still performing CP15 init. Support this on ARM720T so it can be used with Tegra. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-09patman: Add a functional testSimon Glass
The existing test (patman --test) only covers basic checkpatch output. We have had some problems with unicode processing and could use test coverage for the various tags patman supports. Add a new functional test which runs most of the patman flow on a few test commits and checks that the results are correct. See the documentation in the test for a description of what it does. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Rename 'list' variable in MakeCcFile()Simon Glass
This is not a good variable name in Python because 'list' is a type. It shows up highlighted in some editors. Rename it. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Add a maintainer test feature to MakeCcFile()Simon Glass
Allow the add_maintainers parameter to be a list of maintainers, thus allowing us to simulate calling the script in tests without actually needing it to work. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Add unicode to test patchesSimon Glass
Add some unicode to the test patches to make sure that patman does the right thing. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Don't return the series in FixPatches()Simon Glass
There is no need for this function to return the same object that was passed in. Drop the return value. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Don't report unicode characterSimon Glass
Unicode characters may appear in input patches so we should not warn about them. Drop this warning. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Rename 'str' variable in EmailPatches()Simon Glass
This is not a good variable name in Python because 'str' is a type. It shows up highlighted in some editors. Rename it. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Don't convert input data to unicodeSimon Glass
The communication filter reads data in blocks and converts each block to unicode (if necessary) one at a time. In the unlikely event that a unicode character in the input spans a block this will not work. We get an error like: UnicodeDecodeError: 'utf8' codec can't decode bytes in position 1022-1023: unexpected end of data There is no need to change the input to unicode, so the easiest fix is to drop this feature. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: Adjust handling of unicode email addressSimon Glass
Don't mess with the email address when outputting them. Just make sure they are encoded with utf-8. Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09patman: encode CC list to UTF-8Philipp Tomsich
This change encodes the CC list to UTF-8 to avoid failures on maintainer-addresses that include non-ASCII characters (observed on Debian 7.11 with Python 2.7.3). Without this, I get the following failure: Traceback (most recent call last): File "tools/patman/patman", line 159, in <module> options.add_maintainers) File "[snip]/u-boot/tools/patman/series.py", line 234, in MakeCcFile print(commit.patch, ', '.join(set(list)), file=fd) UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 81: ordinal not in range(128) from Heiko's email address: [..., u'"Heiko St\xfcbner" <heiko@sntech.de>', ...] While with this change added this encodes to: "=?UTF-8?q?Heiko=20St=C3=BCbner?= <heiko@sntech.de>" Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org> Tested-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09buildman: Fix bloat option when 'new' only drops functionsTom Rini
In the case where a new build only decreases sizes and does not increase any size we still want to report what functions have been dropped when doing a bloat comparison. Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09sandbox: Fix comparison of unsigned enum expression warningTom Rini
In os_dirent_get_typename() we are checking that type falls within the known values of the enum os_dirent_t. With clang-3.8 testing this value as being >= 0 results in a warning as it will always be true. This assumes of course that we are only given valid data. Given that we want to sanity check the input, we change this to check that it falls within the range of the first to the last entry in the given enum. Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08Merge git://git.denx.de/u-boot-rockchipTom Rini
Here is additional rk3368 and rk3399 support, rv1108 support, refactoring HDMI video (brought in from Anatolij's tree to resolve conflicts), some mkimage fixes and a few other things.
2017-06-08rockchip: board: puma_rk3399: enable BMP_16BPP, BMP_24BPP and BMP_32BPPPhilipp Tomsich
With video output support for the RK3399-Q7 (Puma) available, we want CMD_BMP enabled and the support for 16bit, 24bit and 32bit BMPs defined. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Version-changes: 2 - enable SYS_WHITE_ON_BLACK via defconfig Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: rk_vop: add grf fieldPhilipp Tomsich
The last set of rebases had dropped the 'grf' field from the common rk_vop. Add this back to un-break the build (and driver). Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-08rockchip: video: rk3399: add HDMI TX support on the RK3399Philipp Tomsich
This commit enables the RK3399 HDMI TX, which is very similar to the one found on the RK3288. As requested by Simon, this splits the HDMI driver into a SOC-specific portion (rk3399_hdmi.c, rk3288_hdmi.c) and a common portion (rk_hdmi.c). Note that the I2C communication for reading the EDID works well with the default settings, but does not with the alternate settings used on the RK3288... this configuration aspect is reflected by the driverdata for the RK3399 driver. Having some sort of DTS-based configuration for the regulator dependencies would be nice for the future, but for now we simply use lists of regulator names (also via driverdata) that we probe. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: split RK3288-specific part off from rk_hdmiPhilipp Tomsich
To prepare for the addition of RK3399 HDMI support, the HDMI driver is refactored and broken into a chip-specific and a generic part. This change adds the internal interfaces, makes common/reusable functions externally visible and splits the RK3288 driver into a separate file. For the probing of regulators, we reuse the infrastructure created during the VOP refactoring... i.e. we simply call into the helper function defined for the VOP. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: add mpixelclock settings from Linux driverPhilipp Tomsich
The Linux driver now supports higher mpixelclock settings. Add these to rockchip_phy_config[] and rockchip_mpll_cfg[]. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: rk3399: enable HDMI output (from the rk_vop) for the RK3399Philipp Tomsich
This commit adds a driver for the RK3399 VOPs capable and all the necessary plumbing to feed the HDMI encoder. For the VOP-big, this correctly tracks the ability to feed 10bit RGB data to the encoder. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: refactor rk_vop and split RK3288-specific code offPhilipp Tomsich
To prepare for adding the RK3399 VOP driver (which shares most of its registers and config logic with the RK3228 VOP), this change refactors the driver and splits the RK3288-specific driver off. The changes in detail are: - introduces a data-structure for chip-specific drivers to register features/callbacks with the common driver: at this time, this is limited to a callback for setting the pin polarities (between the VOP and the encoder modules) and a flag to signal 10bit RGB capability - refactors the probing of regulators into a helper function that can take a list of regulator names to probe and autoset - moves the priv data-structure into a (common) header file to be used by the chip-specific drivers to provide base addresses to the common driver - uses a callback into the chip-specific driver to set pin polarities (replacing the direct register accesses previously used) - splits enabling the output (towards an encoder) into a separate help function withint the common driver Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: Kconfig: set MAX_XRES and MAX_YRES via KconfigPhilipp Tomsich
This introduces two new Kconfig options that configure the maximum allowable framebuffer size (i.e. the memory reservation/allocation for the framebuffer): - VIDEO_ROCKCHIP_MAX_XRES - VIDEO_ROCKCHIP_MAX_YRES The resulting memory allocation will cover 4 byte per pixel for these resolutions. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>