Olivier Deprez | ecb2fe5 | 2020-04-02 15:38:02 +0200 | [diff] [blame] | 1 | Secure Partition Manager (MM) |
| 2 | ***************************** |
| 3 | |
| 4 | Foreword |
| 5 | ======== |
| 6 | |
| 7 | Two implementations of a Secure Partition Manager co-exist in the TF-A codebase: |
| 8 | |
Olivier Deprez | 9938c13 | 2021-04-21 11:22:23 +0200 | [diff] [blame] | 9 | - SPM based on the FF-A specification (:ref:`Secure Partition Manager`). |
Olivier Deprez | ecb2fe5 | 2020-04-02 15:38:02 +0200 | [diff] [blame] | 10 | - SPM based on the MM interface. |
| 11 | |
Olivier Deprez | ecb2fe5 | 2020-04-02 15:38:02 +0200 | [diff] [blame] | 12 | Both implementations differ in their architectures and only one can be selected |
| 13 | at build time. |
| 14 | |
| 15 | This document describes the latter implementation where the Secure Partition Manager |
| 16 | resides at EL3 and management services run from isolated Secure Partitions at S-EL0. |
| 17 | The communication protocol is established through the Management Mode (MM) interface. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 18 | |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 19 | Background |
| 20 | ========== |
| 21 | |
| 22 | In some market segments that primarily deal with client-side devices like mobile |
| 23 | phones, tablets, STBs and embedded devices, a Trusted OS instantiates trusted |
| 24 | applications to provide security services like DRM, secure payment and |
| 25 | authentication. The Global Platform TEE Client API specification defines the API |
| 26 | used by Non-secure world applications to access these services. A Trusted OS |
| 27 | fulfils the requirements of a security service as described above. |
| 28 | |
| 29 | Management services are typically implemented at the highest level of privilege |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 30 | in the system, i.e. EL3 in Trusted Firmware-A (TF-A). The service requirements are |
| 31 | fulfilled by the execution environment provided by TF-A. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 32 | |
| 33 | The following diagram illustrates the corresponding software stack: |
| 34 | |
| 35 | |Image 1| |
| 36 | |
| 37 | In other market segments that primarily deal with server-side devices (e.g. data |
| 38 | centres and enterprise servers) the secure software stack typically does not |
| 39 | include a Global Platform Trusted OS. Security functions are accessed through |
| 40 | other interfaces (e.g. ACPI TCG TPM interface, UEFI runtime variable service). |
| 41 | |
| 42 | Placement of management and security functions with diverse requirements in a |
| 43 | privileged Exception Level (i.e. EL3 or S-EL1) makes security auditing of |
| 44 | firmware more difficult and does not allow isolation of unrelated services from |
| 45 | each other either. |
| 46 | |
| 47 | Introduction |
| 48 | ============ |
| 49 | |
| 50 | A **Secure Partition** is a software execution environment instantiated in |
| 51 | S-EL0 that can be used to implement simple management and security services. |
| 52 | Since S-EL0 is an unprivileged Exception Level, a Secure Partition relies on |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 53 | privileged firmware (i.e. TF-A) to be granted access to system and processor |
| 54 | resources. Essentially, it is a software sandbox in the Secure world that runs |
| 55 | under the control of privileged software, provides one or more services and |
| 56 | accesses the following system resources: |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 57 | |
| 58 | - Memory and device regions in the system address map. |
| 59 | |
| 60 | - PE system registers. |
| 61 | |
| 62 | - A range of synchronous exceptions (e.g. SMC function identifiers). |
| 63 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 64 | Note that currently TF-A only supports handling one Secure Partition. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 65 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 66 | A Secure Partition enables TF-A to implement only the essential secure |
| 67 | services in EL3 and instantiate the rest in a partition in S-EL0. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 68 | Furthermore, multiple Secure Partitions can be used to isolate unrelated |
| 69 | services from each other. |
| 70 | |
| 71 | The following diagram illustrates the place of a Secure Partition in a typical |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 72 | Armv8-A software stack. A single or multiple Secure Partitions provide secure |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 73 | services to software components in the Non-secure world and other Secure |
| 74 | Partitions. |
| 75 | |
| 76 | |Image 2| |
| 77 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 78 | The TF-A build system is responsible for including the Secure Partition image |
| 79 | in the FIP. During boot, BL2 includes support to authenticate and load the |
| 80 | Secure Partition image. A BL31 component called **Secure Partition Manager |
| 81 | (SPM)** is responsible for managing the partition. This is semantically |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 82 | similar to a hypervisor managing a virtual machine. |
| 83 | |
| 84 | The SPM is responsible for the following actions during boot: |
| 85 | |
| 86 | - Allocate resources requested by the Secure Partition. |
| 87 | |
| 88 | - Perform architectural and system setup required by the Secure Partition to |
| 89 | fulfil a service request. |
| 90 | |
| 91 | - Implement a standard interface that is used for initialising a Secure |
| 92 | Partition. |
| 93 | |
| 94 | The SPM is responsible for the following actions during runtime: |
| 95 | |
| 96 | - Implement a standard interface that is used by a Secure Partition to fulfil |
| 97 | service requests. |
| 98 | |
| 99 | - Implement a standard interface that is used by the Non-secure world for |
| 100 | accessing the services exported by a Secure Partition. A service can be |
| 101 | invoked through a SMC. |
| 102 | |
| 103 | Alternatively, a partition can be viewed as a thread of execution running under |
| 104 | the control of the SPM. Hence common programming concepts described below are |
| 105 | applicable to a partition. |
| 106 | |
| 107 | Description |
| 108 | =========== |
| 109 | |
| 110 | The previous section introduced some general aspects of the software |
| 111 | architecture of a Secure Partition. This section describes the specific choices |
| 112 | made in the current implementation of this software architecture. Subsequent |
| 113 | revisions of the implementation will include a richer set of features that |
| 114 | enable a more flexible architecture. |
| 115 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 116 | Building TF-A with Secure Partition support |
| 117 | ------------------------------------------- |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 118 | |
| 119 | SPM is supported on the Arm FVP exclusively at the moment. The current |
| 120 | implementation supports inclusion of only a single Secure Partition in which a |
| 121 | service always runs to completion (e.g. the requested services cannot be |
| 122 | preempted to give control back to the Normal world). |
| 123 | |
| 124 | It is not currently possible for BL31 to integrate SPM support and a Secure |
| 125 | Payload Dispatcher (SPD) at the same time; they are mutually exclusive. In the |
| 126 | SPM bootflow, a Secure Partition image executing at S-EL0 replaces the Secure |
| 127 | Payload image executing at S-EL1 (e.g. a Trusted OS). Both are referred to as |
| 128 | BL32. |
| 129 | |
| 130 | A working prototype of a SP has been implemented by re-purposing the EDK2 code |
| 131 | and tools, leveraging the concept of the *Standalone Management Mode (MM)* in |
| 132 | the UEFI specification (see the PI v1.6 Volume 4: Management Mode Core |
| 133 | Interface). This will be referred to as the *Standalone MM Secure Partition* in |
| 134 | the rest of this document. |
| 135 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 136 | To enable SPM support in TF-A, the source code must be compiled with the build |
Manish Pandey | 24dbf3a | 2020-01-22 16:02:57 +0000 | [diff] [blame] | 137 | flag ``SPM_MM=1``, along with ``EL3_EXCEPTION_HANDLING=1``. On Arm |
Sughosh Ganu | df4db9c | 2018-11-14 10:40:33 +0530 | [diff] [blame] | 138 | platforms the build option ``ARM_BL31_IN_DRAM`` must be set to 1. Also, the |
| 139 | location of the binary that contains the BL32 image |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 140 | (``BL32=path/to/image.bin``) must be specified. |
| 141 | |
| 142 | First, build the Standalone MM Secure Partition. To build it, refer to the |
| 143 | `instructions in the EDK2 repository`_. |
| 144 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 145 | Then build TF-A with SPM support and include the Standalone MM Secure Partition |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 146 | image in the FIP: |
| 147 | |
Paul Beesley | 493e349 | 2019-03-13 15:11:04 +0000 | [diff] [blame] | 148 | .. code:: shell |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 149 | |
| 150 | BL32=path/to/standalone/mm/sp BL33=path/to/bl33.bin \ |
Manish Pandey | 24dbf3a | 2020-01-22 16:02:57 +0000 | [diff] [blame] | 151 | make PLAT=fvp SPM_MM=1 EL3_EXCEPTION_HANDLING=1 ARM_BL31_IN_DRAM=1 all fip |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 152 | |
| 153 | Describing Secure Partition resources |
| 154 | ------------------------------------- |
| 155 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 156 | TF-A exports a porting interface that enables a platform to specify the system |
| 157 | resources required by the Secure Partition. Some instructions are given below. |
| 158 | However, this interface is under development and it may change as new features |
| 159 | are implemented. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 160 | |
| 161 | - A Secure Partition is considered a BL32 image, so the same defines that apply |
| 162 | to BL32 images apply to a Secure Partition: ``BL32_BASE`` and ``BL32_LIMIT``. |
| 163 | |
| 164 | - The following defines are needed to allocate space for the translation tables |
| 165 | used by the Secure Partition: ``PLAT_SP_IMAGE_MMAP_REGIONS`` and |
| 166 | ``PLAT_SP_IMAGE_MAX_XLAT_TABLES``. |
| 167 | |
| 168 | - The functions ``plat_get_secure_partition_mmap()`` and |
| 169 | ``plat_get_secure_partition_boot_info()`` have to be implemented. The file |
| 170 | ``plat/arm/board/fvp/fvp_common.c`` can be used as an example. It uses the |
| 171 | defines in ``include/plat/arm/common/arm_spm_def.h``. |
| 172 | |
| 173 | - ``plat_get_secure_partition_mmap()`` returns an array of mmap regions that |
| 174 | describe the memory regions that the SPM needs to allocate for a Secure |
| 175 | Partition. |
| 176 | |
| 177 | - ``plat_get_secure_partition_boot_info()`` returns a |
Paul Beesley | 45f4028 | 2019-10-15 10:57:42 +0000 | [diff] [blame] | 178 | ``spm_mm_boot_info_t`` struct that is populated by the platform |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 179 | with information about the memory map of the Secure Partition. |
| 180 | |
| 181 | For an example of all the changes in context, you may refer to commit |
| 182 | ``e29efeb1b4``, in which the port for FVP was introduced. |
| 183 | |
| 184 | Accessing Secure Partition services |
| 185 | ----------------------------------- |
| 186 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 187 | The `SMC Calling Convention`_ (*Arm DEN 0028B*) describes SMCs as a conduit for |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 188 | accessing services implemented in the Secure world. The ``MM_COMMUNICATE`` |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 189 | interface defined in the `Management Mode Interface Specification`_ (*Arm DEN |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 190 | 0060A*) is used to invoke a Secure Partition service as a Fast Call. |
| 191 | |
| 192 | The mechanism used to identify a service within the partition depends on the |
| 193 | service implementation. It is assumed that the caller of the service will be |
| 194 | able to discover this mechanism through standard platform discovery mechanisms |
| 195 | like ACPI and Device Trees. For example, *Volume 4: Platform Initialisation |
| 196 | Specification v1.6. Management Mode Core Interface* specifies that a GUID is |
| 197 | used to identify a management mode service. A client populates the GUID in the |
| 198 | ``EFI_MM_COMMUNICATE_HEADER``. The header is populated in the communication |
| 199 | buffer shared with the Secure Partition. |
| 200 | |
| 201 | A Fast Call appears to be atomic from the perspective of the caller and returns |
| 202 | when the requested operation has completed. A service invoked through the |
| 203 | ``MM_COMMUNICATE`` SMC will run to completion in the partition on a given CPU. |
| 204 | The SPM is responsible for guaranteeing this behaviour. This means that there |
| 205 | can only be a single outstanding Fast Call in a partition on a given CPU. |
| 206 | |
| 207 | Exchanging data with the Secure Partition |
| 208 | ----------------------------------------- |
| 209 | |
| 210 | The exchange of data between the Non-secure world and the partition takes place |
| 211 | through a shared memory region. The location of data in the shared memory area |
| 212 | is passed as a parameter to the ``MM_COMMUNICATE`` SMC. The shared memory area |
| 213 | is statically allocated by the SPM and is expected to be either implicitly known |
| 214 | to the Non-secure world or discovered through a platform discovery mechanism |
| 215 | e.g. ACPI table or device tree. It is possible for the Non-secure world to |
| 216 | exchange data with a partition only if it has been populated in this shared |
| 217 | memory area. The shared memory area is implemented as per the guidelines |
| 218 | specified in Section 3.2.3 of the `Management Mode Interface Specification`_ |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 219 | (*Arm DEN 0060A*). |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 220 | |
| 221 | The format of data structures used to encapsulate data in the shared memory is |
| 222 | agreed between the Non-secure world and the Secure Partition. For example, in |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 223 | the `Management Mode Interface specification`_ (*Arm DEN 0060A*), Section 4 |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 224 | describes that the communication buffer shared between the Non-secure world and |
| 225 | the Management Mode (MM) in the Secure world must be of the type |
| 226 | ``EFI_MM_COMMUNICATE_HEADER``. This data structure is defined in *Volume 4: |
| 227 | Platform Initialisation Specification v1.6. Management Mode Core Interface*. |
| 228 | Any caller of a MM service will have to use the ``EFI_MM_COMMUNICATE_HEADER`` |
| 229 | data structure. |
| 230 | |
| 231 | Runtime model of the Secure Partition |
| 232 | ===================================== |
| 233 | |
| 234 | This section describes how the Secure Partition interfaces with the SPM. |
| 235 | |
| 236 | Interface with SPM |
| 237 | ------------------ |
| 238 | |
| 239 | In order to instantiate one or more secure services in the Secure Partition in |
| 240 | S-EL0, the SPM should define the following types of interfaces: |
| 241 | |
| 242 | - Interfaces that enable access to privileged operations from S-EL0. These |
| 243 | operations typically require access to system resources that are either shared |
| 244 | amongst multiple software components in the Secure world or cannot be directly |
| 245 | accessed from an unprivileged Exception Level. |
| 246 | |
| 247 | - Interfaces that establish the control path between the SPM and the Secure |
| 248 | Partition. |
| 249 | |
| 250 | This section describes the APIs currently exported by the SPM that enable a |
| 251 | Secure Partition to initialise itself and export its services in S-EL0. These |
| 252 | interfaces are not accessible from the Non-secure world. |
| 253 | |
| 254 | Conduit |
| 255 | ^^^^^^^ |
| 256 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 257 | The `SMC Calling Convention`_ (*Arm DEN 0028B*) specification describes the SMC |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 258 | and HVC conduits for accessing firmware services and their availability |
| 259 | depending on the implemented Exception levels. In S-EL0, the Supervisor Call |
| 260 | exception (SVC) is the only architectural mechanism available for unprivileged |
| 261 | software to make a request for an operation implemented in privileged software. |
| 262 | Hence, the SVC conduit must be used by the Secure Partition to access interfaces |
| 263 | implemented by the SPM. |
| 264 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 265 | A SVC causes an exception to be taken to S-EL1. TF-A assumes ownership of S-EL1 |
| 266 | and installs a simple exception vector table in S-EL1 that relays a SVC request |
| 267 | from a Secure Partition as a SMC request to the SPM in EL3. Upon servicing the |
John Tsichritzis | 63801cd | 2019-07-05 14:22:12 +0100 | [diff] [blame] | 268 | SMC request, Trusted Firmware-A returns control directly to S-EL0 through an |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 269 | ERET instruction. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 270 | |
| 271 | Calling conventions |
| 272 | ^^^^^^^^^^^^^^^^^^^ |
| 273 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 274 | The `SMC Calling Convention`_ (*Arm DEN 0028B*) specification describes the |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 275 | 32-bit and 64-bit calling conventions for the SMC and HVC conduits. The SVC |
| 276 | conduit introduces the concept of SVC32 and SVC64 calling conventions. The SVC32 |
| 277 | and SVC64 calling conventions are equivalent to the 32-bit (SMC32) and the |
| 278 | 64-bit (SMC64) calling conventions respectively. |
| 279 | |
| 280 | Communication initiated by SPM |
| 281 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 282 | |
| 283 | A service request is initiated from the SPM through an exception return |
| 284 | instruction (ERET) to S-EL0. Later, the Secure Partition issues an SVC |
| 285 | instruction to signal completion of the request. Some example use cases are |
| 286 | given below: |
| 287 | |
| 288 | - A request to initialise the Secure Partition during system boot. |
| 289 | |
| 290 | - A request to handle a runtime service request. |
| 291 | |
| 292 | Communication initiated by Secure Partition |
| 293 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 294 | |
| 295 | A request is initiated from the Secure Partition by executing a SVC instruction. |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 296 | An ERET instruction is used by TF-A to return to S-EL0 with the result of the |
| 297 | request. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 298 | |
| 299 | For instance, a request to perform privileged operations on behalf of a |
| 300 | partition (e.g. management of memory attributes in the translation tables for |
| 301 | the Secure EL1&0 translation regime). |
| 302 | |
| 303 | Interfaces |
| 304 | ^^^^^^^^^^ |
| 305 | |
| 306 | The current implementation reserves function IDs for Fast Calls in the Standard |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 307 | Secure Service calls range (see `SMC Calling Convention`_ (*Arm DEN 0028B*) |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 308 | specification) for each API exported by the SPM. This section defines the |
| 309 | function prototypes for each function ID. The function IDs specify whether one |
| 310 | or both of the SVC32 and SVC64 calling conventions can be used to invoke the |
| 311 | corresponding interface. |
| 312 | |
| 313 | Secure Partition Event Management |
| 314 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 315 | |
| 316 | The Secure Partition provides an Event Management interface that is used by the |
| 317 | SPM to delegate service requests to the Secure Partition. The interface also |
| 318 | allows the Secure Partition to: |
| 319 | |
| 320 | - Register with the SPM a service that it provides. |
Paul Beesley | 1fbc97b | 2019-01-11 18:26:51 +0000 | [diff] [blame] | 321 | - Indicate completion of a service request delegated by the SPM |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 322 | |
| 323 | Miscellaneous interfaces |
| 324 | ------------------------ |
| 325 | |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 326 | ``SPM_MM_VERSION_AARCH32`` |
| 327 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 328 | |
| 329 | - Description |
| 330 | |
| 331 | Returns the version of the interface exported by SPM. |
| 332 | |
| 333 | - Parameters |
| 334 | |
| 335 | - **uint32** - Function ID |
| 336 | |
| 337 | - SVC32 Version: **0x84000060** |
| 338 | |
| 339 | - Return parameters |
| 340 | |
| 341 | - **int32** - Status |
| 342 | |
| 343 | On success, the format of the value is as follows: |
| 344 | |
| 345 | - Bit [31]: Must be 0 |
| 346 | - Bits [30:16]: Major Version. Must be 0 for this revision of the SPM |
| 347 | interface. |
| 348 | - Bits [15:0]: Minor Version. Must be 1 for this revision of the SPM |
| 349 | interface. |
| 350 | |
| 351 | On error, the format of the value is as follows: |
| 352 | |
| 353 | - ``NOT_SUPPORTED``: SPM interface is not supported or not available for the |
| 354 | client. |
| 355 | |
| 356 | - Usage |
| 357 | |
| 358 | This function returns the version of the Secure Partition Manager |
| 359 | implementation. The major version is 0 and the minor version is 1. The version |
| 360 | number is a 31-bit unsigned integer, with the upper 15 bits denoting the major |
| 361 | revision, and the lower 16 bits denoting the minor revision. The following |
| 362 | rules apply to the version numbering: |
| 363 | |
| 364 | - Different major revision values indicate possibly incompatible functions. |
| 365 | |
| 366 | - For two revisions, A and B, for which the major revision values are |
| 367 | identical, if the minor revision value of revision B is greater than the |
| 368 | minor revision value of revision A, then every function in revision A must |
| 369 | work in a compatible way with revision B. However, it is possible for |
| 370 | revision B to have a higher function count than revision A. |
| 371 | |
| 372 | - Implementation responsibilities |
| 373 | |
| 374 | If this function returns a valid version number, all the functions that are |
| 375 | described subsequently must be implemented, unless it is explicitly stated |
| 376 | that a function is optional. |
| 377 | |
| 378 | See `Error Codes`_ for integer values that are associated with each return |
| 379 | code. |
| 380 | |
| 381 | Secure Partition Initialisation |
| 382 | ------------------------------- |
| 383 | |
| 384 | The SPM is responsible for initialising the architectural execution context to |
| 385 | enable initialisation of a service in S-EL0. The responsibilities of the SPM are |
| 386 | listed below. At the end of initialisation, the partition issues a |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 387 | ``MM_SP_EVENT_COMPLETE_AARCH64`` call (described later) to signal readiness for |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 388 | handling requests for services implemented by the Secure Partition. The |
| 389 | initialisation event is executed as a Fast Call. |
| 390 | |
| 391 | Entry point invocation |
| 392 | ^^^^^^^^^^^^^^^^^^^^^^ |
| 393 | |
| 394 | The entry point for service requests that should be handled as Fast Calls is |
| 395 | used as the target of the ERET instruction to start initialisation of the Secure |
| 396 | Partition. |
| 397 | |
| 398 | Architectural Setup |
| 399 | ^^^^^^^^^^^^^^^^^^^ |
| 400 | |
| 401 | At cold boot, system registers accessible from S-EL0 will be in their reset |
| 402 | state unless otherwise specified. The SPM will perform the following |
| 403 | architectural setup to enable execution in S-EL0 |
| 404 | |
| 405 | MMU setup |
| 406 | ^^^^^^^^^ |
| 407 | |
| 408 | The platform port of a Secure Partition specifies to the SPM a list of regions |
| 409 | that it needs access to and their attributes. The SPM validates this resource |
| 410 | description and initialises the Secure EL1&0 translation regime as follows. |
| 411 | |
| 412 | 1. Device regions are mapped with nGnRE attributes and Execute Never |
| 413 | instruction access permissions. |
| 414 | |
| 415 | 2. Code memory regions are mapped with RO data and Executable instruction access |
| 416 | permissions. |
| 417 | |
| 418 | 3. Read Only data memory regions are mapped with RO data and Execute Never |
| 419 | instruction access permissions. |
| 420 | |
| 421 | 4. Read Write data memory regions are mapped with RW data and Execute Never |
| 422 | instruction access permissions. |
| 423 | |
| 424 | 5. If the resource description does not explicitly describe the type of memory |
| 425 | regions then all memory regions will be marked with Code memory region |
| 426 | attributes. |
| 427 | |
| 428 | 6. The ``UXN`` and ``PXN`` bits are set for regions that are not executable by |
| 429 | S-EL0 or S-EL1. |
| 430 | |
| 431 | System Register Setup |
| 432 | ^^^^^^^^^^^^^^^^^^^^^ |
| 433 | |
| 434 | System registers that influence software execution in S-EL0 are setup by the SPM |
| 435 | as follows: |
| 436 | |
| 437 | 1. ``SCTLR_EL1`` |
| 438 | |
| 439 | - ``UCI=1`` |
| 440 | - ``EOE=0`` |
| 441 | - ``WXN=1`` |
| 442 | - ``nTWE=1`` |
| 443 | - ``nTWI=1`` |
| 444 | - ``UCT=1`` |
| 445 | - ``DZE=1`` |
| 446 | - ``I=1`` |
| 447 | - ``UMA=0`` |
| 448 | - ``SA0=1`` |
| 449 | - ``C=1`` |
| 450 | - ``A=1`` |
| 451 | - ``M=1`` |
| 452 | |
| 453 | 2. ``CPACR_EL1`` |
| 454 | |
| 455 | - ``FPEN=b'11`` |
| 456 | |
| 457 | 3. ``PSTATE`` |
| 458 | |
| 459 | - ``D,A,I,F=1`` |
| 460 | - ``CurrentEL=0`` (EL0) |
| 461 | - ``SpSel=0`` (Thread mode) |
| 462 | - ``NRW=0`` (AArch64) |
| 463 | |
| 464 | General Purpose Register Setup |
| 465 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 466 | |
| 467 | SPM will invoke the entry point of a service by executing an ERET instruction. |
| 468 | This transition into S-EL0 is special since it is not in response to a previous |
| 469 | request through a SVC instruction. This is the first entry into S-EL0. The |
| 470 | general purpose register usage at the time of entry will be as specified in the |
| 471 | "Return State" column of Table 3-1 in Section 3.1 "Register use in AArch64 SMC |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 472 | calls" of the `SMC Calling Convention`_ (*Arm DEN 0028B*) specification. In |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 473 | addition, certain other restrictions will be applied as described below. |
| 474 | |
| 475 | 1. ``SP_EL0`` |
| 476 | |
| 477 | A non-zero value will indicate that the SPM has initialised the stack pointer |
| 478 | for the current CPU. |
| 479 | |
| 480 | The value will be 0 otherwise. |
| 481 | |
| 482 | 2. ``X4-X30`` |
| 483 | |
| 484 | The values of these registers will be 0. |
| 485 | |
| 486 | 3. ``X0-X3`` |
| 487 | |
| 488 | Parameters passed by the SPM. |
| 489 | |
| 490 | - ``X0``: Virtual address of a buffer shared between EL3 and S-EL0. The |
| 491 | buffer will be mapped in the Secure EL1&0 translation regime with read-only |
| 492 | memory attributes described earlier. |
| 493 | |
| 494 | - ``X1``: Size of the buffer in bytes. |
| 495 | |
| 496 | - ``X2``: Cookie value (*IMPLEMENTATION DEFINED*). |
| 497 | |
| 498 | - ``X3``: Cookie value (*IMPLEMENTATION DEFINED*). |
| 499 | |
| 500 | Runtime Event Delegation |
| 501 | ------------------------ |
| 502 | |
| 503 | The SPM receives requests for Secure Partition services through a synchronous |
| 504 | invocation (i.e. a SMC from the Non-secure world). These requests are delegated |
| 505 | to the partition by programming a return from the last |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 506 | ``MM_SP_EVENT_COMPLETE_AARCH64`` call received from the partition. The last call |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 507 | was made to signal either completion of Secure Partition initialisation or |
| 508 | completion of a partition service request. |
| 509 | |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 510 | ``MM_SP_EVENT_COMPLETE_AARCH64`` |
| 511 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 512 | |
| 513 | - Description |
| 514 | |
| 515 | Signal completion of the last SP service request. |
| 516 | |
| 517 | - Parameters |
| 518 | |
| 519 | - **uint32** - Function ID |
| 520 | |
| 521 | - SVC64 Version: **0xC4000061** |
| 522 | |
| 523 | - **int32** - Event Status Code |
| 524 | |
| 525 | Zero or a positive value indicates that the event was handled successfully. |
| 526 | The values depend upon the original event that was delegated to the Secure |
| 527 | partition. They are described as follows. |
| 528 | |
| 529 | - ``SUCCESS`` : Used to indicate that the Secure Partition was initialised |
| 530 | or a runtime request was handled successfully. |
| 531 | |
| 532 | - Any other value greater than 0 is used to pass a specific Event Status |
| 533 | code in response to a runtime event. |
| 534 | |
| 535 | A negative value indicates an error. The values of Event Status code depend |
| 536 | on the original event. |
| 537 | |
| 538 | - Return parameters |
| 539 | |
| 540 | - **int32** - Event ID/Return Code |
| 541 | |
| 542 | Zero or a positive value specifies the unique ID of the event being |
| 543 | delegated to the partition by the SPM. |
| 544 | |
| 545 | In the current implementation, this parameter contains the function ID of |
| 546 | the ``MM_COMMUNICATE`` SMC. This value indicates to the partition that an |
| 547 | event has been delegated to it in response to an ``MM_COMMUNICATE`` request |
| 548 | from the Non-secure world. |
| 549 | |
| 550 | A negative value indicates an error. The format of the value is as follows: |
| 551 | |
| 552 | - ``NOT_SUPPORTED``: Function was called from the Non-secure world. |
| 553 | |
| 554 | See `Error Codes`_ for integer values that are associated with each return |
| 555 | code. |
| 556 | |
| 557 | - **uint32** - Event Context Address |
| 558 | |
| 559 | Address of a buffer shared between the SPM and Secure Partition to pass |
| 560 | event specific information. The format of the data populated in the buffer |
| 561 | is implementation defined. |
| 562 | |
| 563 | The buffer is mapped in the Secure EL1&0 translation regime with read-only |
| 564 | memory attributes described earlier. |
| 565 | |
| 566 | For the SVC64 version, this parameter is a 64-bit Virtual Address (VA). |
| 567 | |
| 568 | For the SVC32 version, this parameter is a 32-bit Virtual Address (VA). |
| 569 | |
| 570 | - **uint32** - Event context size |
| 571 | |
| 572 | Size of the memory starting at Event Address. |
| 573 | |
| 574 | - **uint32/uint64** - Event Cookie |
| 575 | |
| 576 | This is an optional parameter. If unused its value is SBZ. |
| 577 | |
| 578 | - Usage |
| 579 | |
| 580 | This function signals to the SPM that the handling of the last event delegated |
| 581 | to a partition has completed. The partition is ready to handle its next event. |
| 582 | A return from this function is in response to the next event that will be |
| 583 | delegated to the partition. The return parameters describe the next event. |
| 584 | |
| 585 | - Caller responsibilities |
| 586 | |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 587 | A Secure Partition must only call ``MM_SP_EVENT_COMPLETE_AARCH64`` to signal |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 588 | completion of a request that was delegated to it by the SPM. |
| 589 | |
| 590 | - Callee responsibilities |
| 591 | |
| 592 | When the SPM receives this call from a Secure Partition, the corresponding |
| 593 | syndrome information can be used to return control through an ERET |
| 594 | instruction, to the instruction immediately after the call in the Secure |
| 595 | Partition context. This syndrome information comprises of general purpose and |
| 596 | system register values when the call was made. |
| 597 | |
| 598 | The SPM must save this syndrome information and use it to delegate the next |
| 599 | event to the Secure Partition. The return parameters of this interface must |
| 600 | specify the properties of the event and be populated in ``X0-X3/W0-W3`` |
| 601 | registers. |
| 602 | |
| 603 | Secure Partition Memory Management |
| 604 | ---------------------------------- |
| 605 | |
| 606 | A Secure Partition executes at S-EL0, which is an unprivileged Exception Level. |
| 607 | The SPM is responsible for enabling access to regions of memory in the system |
| 608 | address map from a Secure Partition. This is done by mapping these regions in |
| 609 | the Secure EL1&0 Translation regime with appropriate memory attributes. |
| 610 | Attributes refer to memory type, permission, cacheability and shareability |
| 611 | attributes used in the Translation tables. The definitions of these attributes |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 612 | and their usage can be found in the `Armv8-A ARM`_ (*Arm DDI 0487*). |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 613 | |
| 614 | All memory required by the Secure Partition is allocated upfront in the SPM, |
| 615 | even before handing over to the Secure Partition for the first time. The initial |
| 616 | access permissions of the memory regions are statically provided by the platform |
| 617 | port and should allow the Secure Partition to run its initialisation code. |
| 618 | |
| 619 | However, they might not suit the final needs of the Secure Partition because its |
| 620 | final memory layout might not be known until the Secure Partition initialises |
| 621 | itself. As the Secure Partition initialises its runtime environment it might, |
| 622 | for example, load dynamically some modules. For instance, a Secure Partition |
| 623 | could implement a loader for a standard executable file format (e.g. an PE-COFF |
| 624 | loader for loading executable files at runtime). These executable files will be |
| 625 | a part of the Secure Partition image. The location of various sections in an |
| 626 | executable file and their permission attributes (e.g. read-write data, read-only |
| 627 | data and code) will be known only when the file is loaded into memory. |
| 628 | |
| 629 | In this case, the Secure Partition needs a way to change the access permissions |
| 630 | of its memory regions. The SPM provides this feature through the |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 631 | ``MM_SP_MEMORY_ATTRIBUTES_SET_AARCH64`` SVC interface. This interface is |
| 632 | available to the Secure Partition during a specific time window: from the first |
| 633 | entry into the Secure Partition up to the first ``SP_EVENT_COMPLETE`` call that |
| 634 | signals the Secure Partition has finished its initialisation. Once the |
| 635 | initialisation is complete, the SPM does not allow changes to the memory |
| 636 | attributes. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 637 | |
| 638 | This section describes the standard SVC interface that is implemented by the SPM |
| 639 | to determine and change permission attributes of memory regions that belong to a |
| 640 | Secure Partition. |
| 641 | |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 642 | ``MM_SP_MEMORY_ATTRIBUTES_GET_AARCH64`` |
| 643 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 644 | |
| 645 | - Description |
| 646 | |
| 647 | Request the permission attributes of a memory region from S-EL0. |
| 648 | |
| 649 | - Parameters |
| 650 | |
| 651 | - **uint32** Function ID |
| 652 | |
| 653 | - SVC64 Version: **0xC4000064** |
| 654 | |
| 655 | - **uint64** Base Address |
| 656 | |
| 657 | This parameter is a 64-bit Virtual Address (VA). |
| 658 | |
| 659 | There are no alignment restrictions on the Base Address. The permission |
| 660 | attributes of the translation granule it lies in are returned. |
| 661 | |
| 662 | - Return parameters |
| 663 | |
| 664 | - **int32** - Memory Attributes/Return Code |
| 665 | |
| 666 | On success the format of the Return Code is as follows: |
| 667 | |
| 668 | - Bits[1:0] : Data access permission |
| 669 | |
| 670 | - b'00 : No access |
| 671 | - b'01 : Read-Write access |
| 672 | - b'10 : Reserved |
| 673 | - b'11 : Read-only access |
| 674 | |
| 675 | - Bit[2]: Instruction access permission |
| 676 | |
| 677 | - b'0 : Executable |
| 678 | - b'1 : Non-executable |
| 679 | |
| 680 | - Bit[30:3] : Reserved. SBZ. |
| 681 | |
| 682 | - Bit[31] : Must be 0 |
| 683 | |
| 684 | On failure the following error codes are returned: |
| 685 | |
| 686 | - ``INVALID_PARAMETERS``: The Secure Partition is not allowed to access the |
| 687 | memory region the Base Address lies in. |
| 688 | |
| 689 | - ``NOT_SUPPORTED`` : The SPM does not support retrieval of attributes of |
| 690 | any memory page that is accessible by the Secure Partition, or the |
| 691 | function was called from the Non-secure world. Also returned if it is |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 692 | used after ``MM_SP_EVENT_COMPLETE_AARCH64``. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 693 | |
| 694 | See `Error Codes`_ for integer values that are associated with each return |
| 695 | code. |
| 696 | |
| 697 | - Usage |
| 698 | |
| 699 | This function is used to request the permission attributes for S-EL0 on a |
| 700 | memory region accessible from a Secure Partition. The size of the memory |
| 701 | region is equal to the Translation Granule size used in the Secure EL1&0 |
| 702 | translation regime. Requests to retrieve other memory region attributes are |
| 703 | not currently supported. |
| 704 | |
| 705 | - Caller responsibilities |
| 706 | |
| 707 | The caller must obtain the Translation Granule Size of the Secure EL1&0 |
| 708 | translation regime from the SPM through an implementation defined method. |
| 709 | |
| 710 | - Callee responsibilities |
| 711 | |
| 712 | The SPM must not return the memory access controls for a page of memory that |
| 713 | is not accessible from a Secure Partition. |
| 714 | |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 715 | ``MM_SP_MEMORY_ATTRIBUTES_SET_AARCH64`` |
| 716 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 717 | |
| 718 | - Description |
| 719 | |
| 720 | Set the permission attributes of a memory region from S-EL0. |
| 721 | |
| 722 | - Parameters |
| 723 | |
| 724 | - **uint32** - Function ID |
| 725 | |
| 726 | - SVC64 Version: **0xC4000065** |
| 727 | |
| 728 | - **uint64** - Base Address |
| 729 | |
| 730 | This parameter is a 64-bit Virtual Address (VA). |
| 731 | |
| 732 | The alignment of the Base Address must be greater than or equal to the size |
| 733 | of the Translation Granule Size used in the Secure EL1&0 translation |
| 734 | regime. |
| 735 | |
| 736 | - **uint32** - Page count |
| 737 | |
| 738 | Number of pages starting from the Base Address whose memory attributes |
| 739 | should be changed. The page size is equal to the Translation Granule Size. |
| 740 | |
| 741 | - **uint32** - Memory Access Controls |
| 742 | |
| 743 | - Bits[1:0] : Data access permission |
| 744 | |
| 745 | - b'00 : No access |
| 746 | - b'01 : Read-Write access |
| 747 | - b'10 : Reserved |
| 748 | - b'11 : Read-only access |
| 749 | |
| 750 | - Bit[2] : Instruction access permission |
| 751 | |
| 752 | - b'0 : Executable |
| 753 | - b'1 : Non-executable |
| 754 | |
| 755 | - Bits[31:3] : Reserved. SBZ. |
| 756 | |
| 757 | A combination of attributes that mark the region with RW and Executable |
| 758 | permissions is prohibited. A request to mark a device memory region with |
| 759 | Executable permissions is prohibited. |
| 760 | |
| 761 | - Return parameters |
| 762 | |
| 763 | - **int32** - Return Code |
| 764 | |
| 765 | - ``SUCCESS``: The Memory Access Controls were changed successfully. |
| 766 | |
| 767 | - ``DENIED``: The SPM is servicing a request to change the attributes of a |
| 768 | memory region that overlaps with the region specified in this request. |
| 769 | |
| 770 | - ``INVALID_PARAMETER``: An invalid combination of Memory Access Controls |
| 771 | has been specified. The Base Address is not correctly aligned. The Secure |
| 772 | Partition is not allowed to access part or all of the memory region |
| 773 | specified in the call. |
| 774 | |
| 775 | - ``NO_MEMORY``: The SPM does not have memory resources to change the |
| 776 | attributes of the memory region in the translation tables. |
| 777 | |
| 778 | - ``NOT_SUPPORTED``: The SPM does not permit change of attributes of any |
| 779 | memory region that is accessible by the Secure Partition. Function was |
| 780 | called from the Non-secure world. Also returned if it is used after |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 781 | ``MM_SP_EVENT_COMPLETE_AARCH64``. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 782 | |
| 783 | See `Error Codes`_ for integer values that are associated with each return |
| 784 | code. |
| 785 | |
| 786 | - Usage |
| 787 | |
| 788 | This function is used to change the permission attributes for S-EL0 on a |
| 789 | memory region accessible from a Secure Partition. The size of the memory |
| 790 | region is equal to the Translation Granule size used in the Secure EL1&0 |
| 791 | translation regime. Requests to change other memory region attributes are not |
| 792 | currently supported. |
| 793 | |
| 794 | This function is only available at boot time. This interface is revoked after |
Paul Beesley | e9754e6 | 2019-10-15 12:51:55 +0000 | [diff] [blame] | 795 | the Secure Partition sends the first ``MM_SP_EVENT_COMPLETE_AARCH64`` to |
| 796 | signal that it is initialised and ready to receive run-time requests. |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 797 | |
| 798 | - Caller responsibilities |
| 799 | |
| 800 | The caller must obtain the Translation Granule Size of the Secure EL1&0 |
| 801 | translation regime from the SPM through an implementation defined method. |
| 802 | |
| 803 | - Callee responsibilities |
| 804 | |
| 805 | The SPM must preserve the original memory access controls of the region of |
| 806 | memory in case of an unsuccessful call. The SPM must preserve the consistency |
| 807 | of the S-EL1 translation regime if this function is called on different PEs |
| 808 | concurrently and the memory regions specified overlap. |
| 809 | |
| 810 | Error Codes |
| 811 | ----------- |
| 812 | |
| 813 | .. csv-table:: |
| 814 | :header: "Name", "Value" |
| 815 | |
| 816 | ``SUCCESS``,0 |
| 817 | ``NOT_SUPPORTED``,-1 |
| 818 | ``INVALID_PARAMETER``,-2 |
| 819 | ``DENIED``,-3 |
| 820 | ``NO_MEMORY``,-5 |
| 821 | ``NOT_PRESENT``,-7 |
| 822 | |
| 823 | -------------- |
| 824 | |
Olivier Deprez | 9938c13 | 2021-04-21 11:22:23 +0200 | [diff] [blame] | 825 | *Copyright (c) 2017-2021, Arm Limited and Contributors. All rights reserved.* |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 826 | |
Dan Handley | 610e7e1 | 2018-03-01 18:44:00 +0000 | [diff] [blame] | 827 | .. _Armv8-A ARM: https://developer.arm.com/docs/ddi0487/latest/arm-architecture-reference-manual-armv8-for-armv8-a-architecture-profile |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 828 | .. _instructions in the EDK2 repository: https://github.com/tianocore/edk2-staging/blob/AArch64StandaloneMm/HowtoBuild.MD |
| 829 | .. _Management Mode Interface Specification: http://infocenter.arm.com/help/topic/com.arm.doc.den0060a/DEN0060A_ARM_MM_Interface_Specification.pdf |
| 830 | .. _SDEI Specification: http://infocenter.arm.com/help/topic/com.arm.doc.den0054a/ARM_DEN0054A_Software_Delegated_Exception_Interface.pdf |
laurenw-arm | 03e7e61 | 2020-04-16 10:02:17 -0500 | [diff] [blame] | 831 | .. _SMC Calling Convention: https://developer.arm.com/docs/den0028/latest |
Antonio Nino Diaz | 352c852 | 2017-12-15 11:41:17 +0000 | [diff] [blame] | 832 | |
Paul Beesley | 814f8c0 | 2019-03-13 15:49:27 +0000 | [diff] [blame] | 833 | .. |Image 1| image:: ../resources/diagrams/secure_sw_stack_tos.png |
| 834 | .. |Image 2| image:: ../resources/diagrams/secure_sw_stack_sp.png |