summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-10-08binman: Add a default path to libfdt.pySimon Glass
This module is often available in the sandbox_spl build created by 'make check'. Use this as a default path so that just typing 'binman -t' (without setting PYTHONPATH) will generally run the tests. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Tidy up comments and variable nameSimon Glass
The 'result' variable counts the number of failures in running the tests. Rename it to 'failures' to make this more obvious. Also tidy up a few comments. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Print the name of each test before running itSimon Glass
At present the tests are run without any indication of what is running. For the tests which start with a build this is pretty obvious, but for tools it is not. Add a name for each test we run, and print it before starting the test. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Simplify the PATH setupSimon Glass
Use 'export' to avoid repeating the path setup for each command. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08Makefile: Add a 'check' target for makeSimon Glass
At present we use 'make tests' to run the tests. For many projects 'make check' is more common, so support that as well. Also add some help to 'make help'. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08buildman: Make the toolchain test more forgivingSimon Glass
The filenames of the toolchains on kernel.org changes every now and then. Fix it for the current change, and make the test use a regex so that it has a better chance of passing with future changes too. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test/py: Fix unicode handling for log filteringSimon Glass
At present the unicode filtering seems to get confused at times with this error: UnicodeDecodeError: 'ascii' codec can't decode byte 0x80 in position 32: ordinal not in range(128) It seems to be due to self._nonprint being interpreted as UTF-8. Fix it by using ordinals instead of characters, changing the string to set. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Stephen Warren <swarren@nvidia.com> Tested-by: Michal Simek <michal.simek@xilinx.com>
2018-10-08patman: Handle unicode in _ProjectConfigParser testsSimon Glass
With Python 2.7.15rc1, ConfigParser.SafeConfigParser has unfortunately started returning unicode, for unknown reasons. Adjust the code to handle this by converting everything to unicode. We cannot convert things to ASCII since email addresses may be encoded with UTF-8. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08sandbox: Unprotect DATA regions in bus testsSimon Glass
On my Ubuntu 18.04.1 machine two driver-model bus tests have started failing recently. The problem appears to be that the DATA region of the executable is protected. This does not seem correct, but perhaps there is a reason. To work around it, unprotect the regions in these tests before accessing them. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-07Kconfig: sandbox: enable cmd_avb and dependenciesJens Wiklander
Enables cmd_avb and its dependencies need to run the AVB tests. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> [trini: Disable for sandbox_noblk] Signed-off-by: Tom Rini <trini@konsulko.com>
2018-10-07avb_verify: support sandbox configurationJens Wiklander
Change get_sector_buf() to use map_sysmem() to get a pointer to the CONFIG_FASTBOOT_BUF_ADDR in memory. Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-07test_avb: Update pymark.buildconfigspec information for the AVB testsJens Wiklander
Update the pymark.buildconfigspec to depend on 'cmd_mmc' in addition to 'cmd_avb' for those tests that needs more a more complete MMC implementation or the "mmc" command. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07avb_verify: support using OP-TEE TA AVBJens Wiklander
With CONFIG_OPTEE_TA_AVB use the trusted application AVB provided by OP-TEE to manage rollback indexes and device-lock status. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07test: tee: test TEE uclassJens Wiklander
Tests the TEE uclass with a sandbox tee driver. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> [trini: initialize session to 0 in dm_test_tee] Signed-off-by: Tom Rini <trini@konsulko.com>
2018-10-07tee: add sandbox driverJens Wiklander
Adds a sandbox tee driver which emulates a generic TEE with the OP-TEE AVB TA. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org> [trini: Fix printf warnings in ta_avb_invoke_func, slots is uint] Signed-off-by: Tom Rini <trini@konsulko.com>
2018-10-07sandbox: imply CONFIG_TEE (TEE uclass)Jens Wiklander
Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07sandbox: dt: add sandbox_tee nodeJens Wiklander
Adds a sandbox_tee node to enable the sandbox tee driver in all the sandbox dts files. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07tee: optee: support AVB trusted applicationJens Wiklander
Adds configuration option OPTEE_TA_AVB and a header file describing the interface to the Android Verified Boot 2.0 (AVB) trusted application provided by OP-TEE. Tested-by: Igor Opaniuk <igor.opaniuk@linaro.org> Reviewed-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-07optee: support routing of rpmb data frames to mmcJens Wiklander
Adds support in optee supplicant to route signed (MACed) RPMB frames from OP-TEE Secure OS to MMC and vice versa to manipulate the RPMB partition. Tested-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-07arm: dt: hikey: Add optee nodeJens Wiklander
Sync with 14e21cb8f811 ("arm64: dt: hikey: Add optee node" from Linux kernel. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07Documentation: tee uclass and op-tee driverJens Wiklander
Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07tee: add OP-TEE driverJens Wiklander
Adds a OP-TEE driver. * Targets ARM and ARM64 * Supports using any U-Boot memory as shared memory * Probes OP-TEE version using SMCs * Uses OPTEE message protocol version 2 to communicate with secure world Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07dt/bindings: add bindings for opteeJens Wiklander
Sync with c8bfafb15944 ("dt/bindings: add bindings for optee") from Linux kernel. Introduces linaro prefix and adds bindings for ARM TrustZone based OP-TEE implementation. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07Add UCLASS_TEE for Trusted Execution EnvironmentJens Wiklander
Adds a uclass to interface with a TEE (Trusted Execution Environment). A TEE driver is a driver that interfaces with a trusted OS running in some secure environment, for example, TrustZone on ARM cpus, or a separate secure co-processor etc. The TEE subsystem can serve a TEE driver for a Global Platform compliant TEE, but it's not limited to only Global Platform TEEs. The over all design is based on the TEE subsystem in the Linux kernel, tailored for U-Boot. Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07mmc: rpmb: add mmc_rpmb_route_frames()Jens Wiklander
Adds mmc_rpmb_route_frames() to route RPMB data frames from/to an external entity. Tested-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-07cmd: avb: print error message if command failsJens Wiklander
Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07cmd: avb read_rb: print rb_idx in hexadecimalJens Wiklander
Prior to this patch was do_avb_write_rb() reading supplied rb_idx as a hexadecimal number while do_avb_read_rb() printed the read out rb_idx as decimal number. For consistency change do_avb_read_rb() to print rb_idx as a hexadecimal number too. Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Igor Opaniuk <igor.opaniuk@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-07dm: fdt: scan for devices under /firmware tooJens Wiklander
Just as /chosen may contain devices /firmware may contain devices, scan for devices under /firmware too. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
2018-10-06spl: spi: Do not hardcode fixed size for headerMichal Simek
Find out size directly from header structure. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-10-06spl: ram: Fix u_boot_pos calculationMichal Simek
The patch: "spl: Weed out CONFIG_SYS_TEXT_BASE usage" (sha1: 04ce5427bd3914cab8be78513275a20ab878520a) introduced bug where assigning to u_boot_pos variable wasn't done which end up in situation where SPL wasn't able to find out image on the selected address. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-10-06mach-stm32: Set MPU SDRAM size to 512MB for STM32F7/H7Patrice Chotard
This allows to boot all STM32F7 and STM32H7 boards independently of the amount of embedded SDRAM. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Reviewed-by: Vikas Manocha <vikas.manocha@st.com>
2018-10-06fs: fat: fix set_cluster()Heinrich Schuchardt
Avoid CoverityScan warning SIGN_EXTENSION by changing the type of parameter size of set_cluster(). Avoid leaking stack content when writing an incomplete last sector. Reported-by: Coverity (CID: 184096) Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2018-10-06fs: fat: memory leak in fat_unlink()Heinrich Schuchardt
Do not leak filename_copy in case of error. Catch out of memory when calling strdup. Reported-by: Coverity (CID: 184086) Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2018-10-06ARM: LogicPD: omap3logic: Remove Torpedo/SOM-LV autodectionAdam Ford
With there now being four device tree files, and 4 separate defconfig files, the code necessary to determine which board is being used is no longer necessary as the corresponding pin-muxing and board names are determined by the device tree. Signed-off-by: Adam Ford <aford173@gmail.com>
2018-10-06ARM: DTS: Add Logic PD OMAP35/DM37 SOM-LV and OMAP35 TorpedoAdam Ford
With the device trees doing most of the work of pin-muxing and DM doing much of the peripheral initialization, this creates new defconfig files for each of the Logic PD variants with proper register settings/pin-muxing. Signed-off-by: Adam Ford <aford173@gmail.com> [trini: Update MAINTAINERS entry] Signed-off-by: Tom Rini <trini@konsulko.com>
2018-10-06ARM: DTS: Add support for Logic PD OMAP35 Torpedo & SOM-LVAdam Ford
The baseboards and SOM's are virtually identical to their DM37 counterparts, but OMAP36/37 and OMAP3 have some minor register differences. With the boards being mostly driven by device trees now, this synchronizes their respective device trees with linux-omap for-next branch destined for 4.20 (or whatever the version after 4.19 will be called) Signed-off-by: Adam Ford <aford173@gmail.com>
2018-10-06ARM: DTS: Remove unnecessary u-boot.dtsi options from omap3/36xxAdam Ford
With the introduction of the omap serial driver, the need for some of these U-Boot specific modifications is gone. This cleans up this unnneeded stuff. Signed-off-by: Adam Ford <aford173@gmail.com>
2018-10-06ARM: DTS: LogicPD-SOM-LV & Torpedo: Resync DTS with KernelAdam Ford
The device tree entries are from linux-omap's for-next branch destined to me put into 4.20 (or whatever the version is after 4.19) Signed-off-by: Adam Ford <aford173@gmail.com>
2018-10-06misc: Add support for the Arm Versatile Express config busLiviu Dudau
Add support for the Arm Versatile Express config bus that is being used for exposing various subsystems via a generic configuration bus. This driver adds support for generating transactions on this configuration bus and can be used by other drivers to abstract the communication with the actual function providers. Signed-off-by: Liviu Dudau <liviu.dudau@foss.arm.com> Reviewed-by: Heiko Schocher <hs@denx.de>
2018-10-06configs: drop CONFIG_SYS_EXTRA_ENV_RELOCSimon Goldschmidt
Instead of manually specifying CONFIG_SYS_EXTRA_ENV_RELOC for every board that needs it, it shouldn't hurt to let initr_reloc_global_data() always relocate gd->env_addr unless we know this pointer is outside the initial binary. To achieve this, the relocation is omitted if CONFIG_ENV_ADDR is defined (and ENV_IS_EMBEDDED is not). Signed-off-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
2018-10-06test/py: test_fs: add docstring comments to helper functionsAkashi Takahiro
After Siomon's comment, add a descriptive comment (docstring) to each of helper functions in conftest.py. No functionality changed. Signed-off-by: Akashi Takahiro <takahiro.akashi@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-06test/py: test_fs: remove fs_type argument from umount_fs()Akashi Takahiro
Since there is no use of fs_type in umount_fs(), just remove it. Signed-off-by: Akashi Takahiro <takahiro.akashi@linaro.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2018-10-06test/py: ignore console read exceptions after test failureStephen Warren
After a test has failed, test/py drains the U-Boot console log to ensure that any relevant output is captured. At this point, we don't care about detecting any additional errors, since the test is already known to have failed, and U-Boot will be restarted. To ensure that the test cleanup code is not interrupted, and can correctly terminate the log sections for the failed test, ignore any exception that occurs while reading the U-Boot console output during this limited period of time. Signed-off-by: Stephen Warren <swarren@nvidia.com>
2018-10-05Merge branch 'master' of git://git.denx.de/u-boot-shTom Rini
2018-10-05Merge branch 'master' of git://git.denx.de/u-boot-socfpgaTom Rini
2018-10-05Merge tag 'rockchip-for-v2018.11-rc2' of git://git.denx.de/u-boot-rockchipTom Rini
Rockchip-focused changes for v2018.11-rc2: - fixes to rkimage for SPL boot via USB - fixes to make_fit_atf.py, incl. entry-point calculation and python3 compatibility - OP-TEE support for ARMv7-based SoCs - fixes to RGMII/GMII selection on the RK3328 Signed-off-by: Tom Rini <trini@konsulko.com>
2018-10-05Merge tag 'arc-updates-for-2018.11-rc2' of git://git.denx.de/u-boot-arcTom Rini
Here we do a couple of impovements for all ARC boards as well as introduce yet another developemnt board. 1. Now for ARC boards we print CPU and board info which is useful for users and helps with analysis of logs "post-mortem". 2. Synopsys IoT development kit support is added This one might bw a bit too late as we're past RC1 but: 1) This doesn't affect any other arches etc as we change purely ARC code. 2) I've got a chance to talk about U-Boot on IoT platforms during ELCE (my proposal was on a wait list and only this week I've got an update and invitation to talk) so it would be good to have this board as a primer in upstream code-base by the time of ELCE 2018. 3) For complete support of IoT devkit I'm yet to significantly rework regmap subsystem in U-Boot but that's a different topic and hopefully it will be done sometime soon... though not this release cycle for sure.
2018-10-05arc: Add support for IoT development kitAlexey Brodkin
The DesignWare ARC IoT Development Kit is a versatile platform that includes the necessary hardware and software to accelerate software development and debugging of sensor fusion, voice recognition and face detection designs. More information is avaialble here [1] and here [2]. The board is based on real silicon with ARC EM9D-based Data Fusion IP Subsystem. It sports a rich set of I/O including * DW USB OTG * DW MobileStorage (used for micro SD-card) * GPIO * multiple serial interface including DW APB UART * ADC, PWM and eFlash, SRAM and SPI Flash memory * Real-Time Clock (RTC) * Bluetooth module with worldwide regulatory compliance (FCC, IC, CE, ETSI, TELEC) * On-board 9-axis sensor (gyro, accelerometer and compass) Extensible with Arduino, Pmod, mikroBUS connectors and a 2x18 extension header. One of the most interesting features for developers is built-in Digilent USB JTAG probe so only micro-USB cable is needed! [1] https://www.synopsys.com/dw/ipdir.php?ds=arc_iot_development_kit [2] https://www.synopsys.com/dw/doc.php/ds/cc/iot_dev_kit.pdf Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2018-10-05ARC: Enable DISPLAY_CPUINFO & DISPLAY_BOARDINFOAlexey Brodkin
With implemented print_cpuinfo() and model property in .dts we're ready to print nice info about ARC cores and boards on boot. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
2018-10-05ARC: Implement print_cpuinfo()Alexey Brodkin
Once we enable DISPLAY_CPUINFO for ARC we'll see ARC core family and version printed on boot. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>