1# OP-TEE Trusted OS 2## Contents 31. [Introduction](#1-introduction) 42. [License](#2-license) 53. [Platforms supported](#3-platforms-supported) 64. [Get and build OP-TEE software](#4-get-and-build-op-tee-software) 75. [Coding standards](#5-coding-standards) 8 9## 1. Introduction 10The `optee_os` git repository contains the source code of a Trusted Execution 11Environment (TEE) as companion to a non-secure OS on ARM® 12Cortex-A cores using the TrustZone® technology. This component meets the 13[TEE System Architecture specifications](http://www.globalplatform.org/specificationsdevice.asp) 14and provides the 15[TEE Internal Core API v1.1](http://www.globalplatform.org/specificationsdevice.asp) 16as defined by the 17[GlobalPlatform Device technology TEE specifications](http://www.globalplatform.org/specificationsdevice.asp) 18for the development of 19Trusted Applications. For a general overview of OP-TEE and to find out how to 20contribute, please see the [Notice.md](Notice.md) file. 21 22The Trusted OS is accessible from the Rich OS (Linux) using the 23[GlobalPlatform TEE Client API Specification v1.0](http://www.globalplatform.org/specificationsdevice.asp), 24which also is used to trigger secure execution of applications within the TEE. 25 26--- 27## 2. License 28The software is distributed mostly under the 29[BSD 2-Clause](http://opensource.org/licenses/BSD-2-Clause) open source 30license, apart from some files in the `optee_os/lib/libutils` directory 31which are distributed under the 32[BSD 3-Clause](http://opensource.org/licenses/BSD-3-Clause) or public domain 33licenses. 34 35--- 36## 3. Platforms supported 37Several platforms are supported. In order to manage slight differences 38between platforms, a `PLATFORM_FLAVOR` flag has been introduced. 39The `PLATFORM` and `PLATFORM_FLAVOR` flags define the whole configuration 40for a chip the where the Trusted OS runs. Note that there is also a 41composite form which makes it possible to append `PLATFORM_FLAVOR` directly, 42by adding a dash in-between the names. The composite form is shown below 43for the different boards. For more specific details about build flags etc, 44please read the file [build_system.md](documentation/build_system.md). Some 45platforms have different sub-maintainers, please refer to the file 46[MAINTAINERS](MAINTAINERS) for contact details for various platforms. 47 48The **Maintained?** column shows: 49 50- A green image if the platform is actively maintained: either tested successfully 51 with the latest release (N), or is a newly supported platform. 52- An orange image if the platform was last tested successfully with release N-1. 53- A red image if the last successful test report is older. 54 55<!-- Please keep this list sorted in alphabetic order --> 56| Platform | Composite PLATFORM flag | Publicly available? | Maintained? | 57|----------|-------------------------|---------------------|-------------| 58| [ARM Juno Board](http://www.arm.com/products/tools/development-boards/versatile-express/juno-arm-development-platform.php) |`PLATFORM=vexpress-juno`| Yes |  | 59| [Atmel ATSAMA5D2-XULT Board](http://www.atmel.com/tools/atsama5d2-xult.aspx)|`PLATFORM=sam`| Yes |  | 60| [DeveloperBox (Socionext Synquacer SC2A11)](https://www.96boards.org/product/developerbox/)|`PLATFORM=synquacer`| Yes |  | 61| [FSL ls1021a](http://www.freescale.com/tools/embedded-software-and-tools/hardware-development-tools/tower-development-boards/mcu-and-processor-modules/powerquicc-and-qoriq-modules/qoriq-ls1021a-tower-system-module:TWR-LS1021A?lang_cd=en)|`PLATFORM=ls-ls1021atwr`| Yes |  | 62| [NXP ls1043ardb](http://www.nxp.com/products/microcontrollers-and-processors/power-architecture-processors/qoriq-platforms/developer-resources/qoriq-ls1043a-reference-design-board:LS1043A-RDB)|`PLATFORM=ls-ls1043ardb`| Yes |  | 63| [NXP ls1046ardb](http://www.nxp.com/products/microcontrollers-and-processors/power-architecture-processors/qoriq-platforms/developer-resources/qoriq-ls1046a-reference-design-board:LS1046A-RDB)|`PLATFORM=ls-ls1046ardb`| Yes |  | 64| [NXP ls1012ardb](http://www.nxp.com/products/microcontrollers-and-processors/power-architecture-processors/qoriq-platforms/developer-resources/qoriq-ls1012a-reference-design-board:LS1012A-RDB)|`PLATFORM=ls-ls1012ardb`| Yes |  | 65| [NXP ls1088ardb](http://www.nxp.com/products/microcontrollers-and-processors/power-architecture-processors/qoriq-platforms/developer-resources/qoriq-ls1088a-reference-design-board:LS1088A-RDB)|`PLATFORM=ls-ls1088ardb`| Yes |  | 66| [NXP ls2088ardb](http://www.nxp.com/products/microcontrollers-and-processors/power-architecture-processors/qoriq-platforms/developer-resources/qoriq-ls2088a-reference-design-board:LS2088A-RDB)|`PLATFORM=ls-ls2088ardb`| Yes |  | 67| [NXP ls1012afrwy](https://www.nxp.com/support/developer-resources/software-development-tools/qoriq-developer-resources/layerscape-frwy-ls1012a-board:FRWY-LS1012A)|`PLATFORM=ls-ls1012afrwy`| Yes |  | 68| [FSL i.MX6 Quad SABRE Lite Board](https://boundarydevices.com/product/sabre-lite-imx6-sbc/) |`PLATFORM=imx-mx6qsabrelite`| Yes |  | 69| [FSL i.MX6 Quad SABRE SD Board](http://www.nxp.com/products/software-and-tools/hardware-development-tools/sabre-development-system/sabre-board-for-smart-devices-based-on-the-i.mx-6quad-applications-processors:RD-IMX6Q-SABRE) |`PLATFORM=imx-mx6qsabresd`| Yes |  | 70| [SolidRun i.MX6 Quad Hummingboard Edge](https://www.solid-run.com/product/hummingboard-edge-imx6q-wa-h/) |`PLATFORM=imx-mx6qhmbedge`| Yes |  | 71| [SolidRun i.MX6 Dual Hummingboard Edge](https://www.solid-run.com/product/hummingboard-edge-imx6d-wa-h/) |`PLATFORM=imx-mx6dhmbedge`| Yes |  | 72| [SolidRun i.MX6 Dual Lite Hummingboard Edge](https://www.solid-run.com/product/hummingboard-edge-imx6dl-0c-h/) |`PLATFORM=imx-mx6dlhmbedge`| Yes |  | 73| [SolidRun i.MX6 Solo Hummingboard Edge](https://www.solid-run.com/product/hummingboard-edge-imx6s-wa-h/) |`PLATFORM=imx-mx6shmbedge`| Yes |  | 74| [FSL i.MX6 UltraLite EVK Board](http://www.freescale.com/products/arm-processors/i.mx-applications-processors-based-on-arm-cores/i.mx-6-processors/i.mx6qp/i.mx6ultralite-evaluation-kit:MCIMX6UL-EVK) |`PLATFORM=imx-mx6ulevk`| Yes |  | 75| [NXP i.MX7Dual SabreSD Board](http://www.nxp.com/products/software-and-tools/hardware-development-tools/sabre-development-system/sabre-board-for-smart-devices-based-on-the-i.mx-7dual-applications-processors:MCIMX7SABRE) |`PLATFORM=imx-mx7dsabresd`| Yes |  | 76| [NXP i.MX7Solo WaRP7 Board](http://www.nxp.com/products/developer-resources/reference-designs/warp7-next-generation-iot-and-wearable-development-platform:WARP7) |`PLATFORM=imx-mx7swarp7`| Yes |  | 77| [ARM Foundation FVP](https://developer.arm.com/products/system-design/fixed-virtual-platforms) |`PLATFORM=vexpress-fvp`| Yes |  | 78| [HiSilicon D02](http://open-estuary.org/d02-2)|`PLATFORM=d02`| No |  | 79| [HiKey Board (HiSilicon Kirin 620)](https://www.96boards.org/product/hikey)|`PLATFORM=hikey` or `PLATFORM=hikey-hikey`| Yes |  | 80| [HiKey960 Board (HiSilicon Kirin 960)](https://www.96boards.org/product/hikey960)|`PLATFORM=hikey-hikey960`| Yes |  | 81| [Marvell ARMADA 7K Family](http://www.marvell.com/embedded-processors/armada-70xx/)|`PLATFORM=marvell-armada7k8k`| Yes |  | 82| [Marvell ARMADA 8K Family](http://www.marvell.com/embedded-processors/armada-80xx/)|`PLATFORM=marvell-armada7k8k`| Yes |  | 83| [Marvell ARMADA 3700 Family](http://www.marvell.com/embedded-processors/armada-3700/)|`PLATFORM=marvell-armada3700`| Yes |  | 84| [MediaTek MT8173 EVB Board](https://www.mediatek.com/products/tablets/mt8173)|`PLATFORM=mediatek-mt8173`| No |  v3.0.0 | 85| [Poplar Board (HiSilicon Hi3798C V200)](https://www.96boards.org/product/poplar)|`PLATFORM=poplar`| Yes |  | 86| [QEMU](http://wiki.qemu.org/Main_Page) |`PLATFORM=vexpress-qemu_virt`| Yes |  | 87| [QEMUv8](http://wiki.qemu.org/Main_Page) |`PLATFORM=vexpress-qemu_armv8a`| Yes |  | 88| [Raspberry Pi 3](https://www.raspberrypi.org/products/raspberry-pi-3-model-b) |`PLATFORM=rpi3`| Yes |  | 89| [Renesas RCAR](https://www.renesas.com/en-sg/solutions/automotive/products/rcar-h3.html)|`PLATFORM=rcar`| No |  | 90| [Rockchip RK322X](http://www.rock-chips.com/a/en/products/RK32_Series/2016/1109/799.html) |`PLATFORM=rockchip-rk322x`| No |  | 91| [STMicroelectronics b2260 - h410 (96boards fmt)](http://www.st.com/web/en/catalog/mmc/FM131/SC999/SS1628/PF258776) |`PLATFORM=stm-b2260`| No |  | 92| [STMicroelectronics b2120 - h310 / h410](http://www.st.com/web/en/catalog/mmc/FM131/SC999/SS1628/PF258776) |`PLATFORM=stm-cannes`| No |  | 93| STMicroelectronics stm32mp1 |`PLATFORM=stm32mp1`| No |  | 94| [Allwinner A64 Pine64 Board](https://www.pine64.org/) |`PLATFORM=sunxi-sun50i_a64`| Yes |  | 95| [Texas Instruments AM65x](http://www.ti.com/lit/ug/spruid7/spruid7.pdf)|`PLATFORM=k3-am65x`| Yes |  | 96| [Texas Instruments DRA7xx](http://www.ti.com/processors/automotive-processors/drax-infotainment-socs/overview.html)|`PLATFORM=ti-dra7xx`| Yes |  | 97| [Texas Instruments AM57xx](http://www.ti.com/processors/sitara/arm-cortex-a15/am57x/overview.html)|`PLATFORM=ti-am57xx`| Yes |  | 98| [Texas Instruments AM43xx](http://www.ti.com/processors/sitara/arm-cortex-a9/am438x/overview.html)|`PLATFORM=ti-am43xx`| Yes |  | 99| [Xilinx Zynq 7000 ZC702](http://www.xilinx.com/products/boards-and-kits/ek-z7-zc702-g.html)|`PLATFORM=zynq7k-zc702`| Yes |  v2.3.0 | 100| [Xilinx Zynq UltraScale+ MPSOC](http://www.xilinx.com/products/silicon-devices/soc/zynq-ultrascale-mpsoc.html)|`PLATFORM=zynqmp-zcu102`| Yes |  v2.4.0 | 101| [Spreadtrum SC9860](http://www.spreadtrum.com/en/SC9860GV.html)|`PLATFORM=sprd-sc9860`| No |  v2.1.0 | 102 103--- 104## 4. Get and build OP-TEE software 105Please see [build] for instructions how to run OP-TEE on various devices. 106 107--- 108## 5. Coding standards 109In this project we are trying to adhere to the same coding convention as used in 110the Linux kernel (see [CodingStyle]). We achieve this by running [checkpatch] 111from Linux kernel. However there are a few exceptions that we had to make since 112the code also follows GlobalPlatform standards. The exceptions are as follows: 113 114- CamelCase for GlobalPlatform types are allowed. 115- And we also exclude checking third party code that we might use in this 116 project, such as LibTomCrypt, MPA, newlib (not in this particular git, but 117 those are also part of the complete TEE solution, see 118 [Notice.md](Notice.md#repository-structure). The reason for 119 excluding and not fixing third party code is because we would probably 120 deviate too much from upstream and therefore it would be hard to rebase 121 against those projects later on and we don't expect that it is easy to 122 convince other software projects to change coding style. 123 Automatic variables should always be initialized. Mixed declarations 124 and statements are allowed, and may be used to avoid assigning useless 125 values. Please leave one blank line before and after such declarations. 126 127Regarding the checkpatch tool, it is not included directly into this project. 128Please use checkpatch.pl from the Linux kernel git in combination with the 129local [checkpatch script]. 130 131[build]: https://github.com/OP-TEE/build 132[checkpatch script]: scripts/checkpatch.sh 133[checkpatch]: http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/scripts/checkpatch.pl 134[CodingStyle]: https://www.kernel.org/doc/Documentation/process/coding-style.rst 135