blob: 29b89b2a7df50fac456753c54ccfc83776a3ac9a [file] [log] [blame]
Olivier Deprez9938c132021-04-21 11:22:23 +02001FF-A manifest binding to device tree
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -05002====================================
Louis Mayencourt5f0fc152019-11-29 15:05:14 +00003
4This document defines the nodes and properties used to define a partition,
Olivier Deprez9938c132021-04-21 11:22:23 +02005according to the FF-A specification.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +00006
Louis Mayencourt31030e52020-04-08 13:04:33 +01007Partition Properties
Olivier Deprez7a632c52022-05-12 18:17:05 +02008--------------------
Louis Mayencourt5f0fc152019-11-29 15:05:14 +00009
10- compatible [mandatory]
11 - value type: <string>
J-Alves2672cde2020-05-07 18:42:25 +010012 - Must be the string "arm,ffa-manifest-X.Y" which specifies the major and
David Horstmann051fd6d2020-11-12 15:19:04 +000013 minor versions of the device tree binding for the FFA manifest represented
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000014 by this node. The minor number is incremented if the binding changes in a
15 backwards compatible manner.
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000016
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000017 - X is an integer representing the major version number of this document.
18 - Y is an integer representing the minor version number of this document.
19
J-Alves2672cde2020-05-07 18:42:25 +010020- ffa-version [mandatory]
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000021 - value type: <u32>
22 - Must be two 16 bits values (X, Y), concatenated as 31:16 -> X,
23 15:0 -> Y, where:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000024
Olivier Deprez9938c132021-04-21 11:22:23 +020025 - X is the major version of FF-A expected by the partition at the FFA
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000026 instance it will execute.
Olivier Deprez9938c132021-04-21 11:22:23 +020027 - Y is the minor version of FF-A expected by the partition at the FFA
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000028 instance it will execute.
29
30- uuid [mandatory]
31 - value type: <prop-encoded-array>
32 - An array consisting of 4 <u32> values, identifying the UUID of the service
33 implemented by this partition. The UUID format is described in RFC 4122.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000034
35- id
36 - value type: <u32>
37 - Pre-allocated partition ID.
38
39- auxiliary-id
40 - value type: <u32>
41 - Pre-allocated ID that could be used in memory management transactions.
42
43- description
44 - value type: <string>
45 - Name of the partition e.g. for debugging purposes.
46
47- execution-ctx-count [mandatory]
48 - value type: <u32>
49 - Number of vCPUs that a VM or SP wants to instantiate.
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000050
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000051 - In the absence of virtualization, this is the number of execution
52 contexts that a partition implements.
53 - If value of this field = 1 and number of PEs > 1 then the partition is
54 treated as UP & migrate capable.
55 - If the value of this field > 1 then the partition is treated as a MP
56 capable partition irrespective of the number of PEs.
57
58- exception-level [mandatory]
59 - value type: <u32>
60 - The target exception level for the partition:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000061
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000062 - 0x0: EL1
63 - 0x1: S_EL0
64 - 0x2: S_EL1
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000065
66- execution-state [mandatory]
67 - value type: <u32>
68 - The target execution state of the partition:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000069
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000070 - 0: AArch64
71 - 1: AArch32
72
73- load-address
74 - value type: <u64>
75 - Physical base address of the partition in memory. Absence of this field
76 indicates that the partition is position independent and can be loaded at
77 any address chosen at boot time.
78
79- entrypoint-offset
80 - value type: <u64>
81 - Offset from the base of the partition's binary image to the entry point of
82 the partition. Absence of this field indicates that the entry point is at
83 offset 0x0 from the base of the partition's binary.
84
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -050085- xlat-granule
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000086 - value type: <u32>
87 - Translation granule used with the partition:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +000088
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000089 - 0x0: 4k
90 - 0x1: 16k
Louis Mayencourt31030e52020-04-08 13:04:33 +010091 - 0x2: 64k
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000092
93- boot-order
Madhukar Pappireddyc85a69e2024-07-25 17:46:08 -050094 - value type: <u32>
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000095 - A unique number amongst all partitions that specifies if this partition
96 must be booted before others. The partition with the smaller number will be
Madhukar Pappireddyc85a69e2024-07-25 17:46:08 -050097 booted first. Highest vlue allowed for this field is 0xFFFF.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +000098
99- rx-tx-buffer
100 - value type: "memory-regions" node
101 - Specific "memory-regions" nodes that describe the RX/TX buffers expected
102 by the partition.
J-Alves2672cde2020-05-07 18:42:25 +0100103 The "compatible" must be the string "arm,ffa-manifest-rx_tx-buffer".
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000104
105- messaging-method [mandatory]
Madhukar Pappireddyc85a69e2024-07-25 17:46:08 -0500106 - value type: <u32>
Maksims Svecovsdfdec7c2021-05-06 14:17:00 +0100107 - Specifies which messaging methods are supported by the partition, set bit
108 means the feature is supported, clear bit - not supported:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +0000109
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500110 - Bit[0]: partition can receive direct requests via FFA_MSG_SEND_DIRECT_REQ ABI if set
111 - Bit[1]: partition can send direct requests via FFA_MSG_SEND_DIRECT_REQ ABI if set
Maksims Svecovs14713202021-05-06 19:03:48 +0100112 - Bit[2]: partition can send and receive indirect messages
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500113 - Bit[9]: partition can receive direct requests via FFA_MSG_SEND_DIRECT_REQ2 ABI if set
114 - Bit[10]: partition can send direct requests via FFA_MSG_SEND_DIRECT_REQ2 ABI if set
Maksims Svecovs14713202021-05-06 19:03:48 +0100115
116- managed-exit
117 - value type: <empty>
118 - Specifies if managed exit is supported.
Madhukar Pappireddybfc7aa82022-09-01 10:57:21 -0500119 - This field is deprecated in favor of ns-interrupts-action field in the FF-A
120 v1.1 EAC0 spec.
121
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500122- managed-exit-virq
123 - value type: <empty>
124 - Indicates if the partition needs managed exit, if supported, to be signaled
125 through vFIQ signal.
126
Madhukar Pappireddybfc7aa82022-09-01 10:57:21 -0500127- ns-interrupts-action [mandatory]
128 - value type: <u32>
129 - Specifies the action that the SPMC must take in response to a Non-secure
130 physical interrupt.
131
132 - 0x0: Non-secure interrupt is queued
133 - 0x1: Non-secure interrupt is signaled after a managed exit
134 - 0x2: Non-secure interrupt is signaled
135
136 - This field supersedes the managed-exit field in the FF-A v1.0 spec.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000137
Madhukar Pappireddyeff48e02023-01-26 08:47:58 -0600138- other-s-interrupts-action
139 - value type: <u32>
140 - Specifies the action that the SPMC must take in response to a Other-Secure
141 physical interrupt.
142
143 - 0x0: Other-Secure interrupt is queued
144 - 0x1: Other-Secure interrupt is signaled
145
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500146- runtime-model
147 - value type: <u32>
148 - Indicates whether the SP execution can be preempted.
149 - This field is deprecated in favor of other-s-interrupts-action and
150 ns-interrupts-action fields in the FF-A v1.1 spec.
151
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000152- has-primary-scheduler
153 - value type: <empty>
154 - Presence of this field indicates that the partition implements the primary
155 scheduler. If so, run-time EL must be EL1.
156
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000157- time-slice-mem
158 - value type: <empty>
159 - Presence of this field indicates that the partition doesn't expect the
160 partition manager to time slice long running memory management functions.
161
162- gp-register-num
163 - value type: <u32>
J-Alvescfc6e232022-05-24 12:13:08 +0100164 - The field specifies the general purpose register number but not its width.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000165 The width is derived from the partition's execution state, as specified in
166 the partition properties. For example, if the number value is 1 then the
167 general-purpose register used will be x1 in AArch64 state and w1 in AArch32
168 state.
J-Alvescfc6e232022-05-24 12:13:08 +0100169 Presence of this field indicates that the partition expects the address of
170 the FF-A boot information blob to be passed in the specified general purpose
171 register.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000172
Marc Bonnici25f4b542022-04-12 17:18:13 +0100173- power-management-messages
174 - value type: <u32>
175 - Specifies which power management messages a partition subscribes to.
176 A set bit means the partition should be informed of the power event, clear
177 bit - should not be informed of event:
178
179 - Bit[0]: CPU_OFF
180 - Bit[1]: CPU_SUSPEND
181 - Bit[2]: CPU_SUSPEND_RESUME
182
Balint Dobszay251be5f2024-07-10 11:46:37 +0200183- vm-availability-messages
184 - value type: <u32>
185 - Specifies which VM availability messages a partition subscribes to. A set
186 bit means the partition should be informed of the event, clear bit - should
187 not be informed of event:
188
189 - Bit[0]: VM created
190 - Bit[1]: VM destroyed
191
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500192.. _memory_region_node:
193
Louis Mayencourt31030e52020-04-08 13:04:33 +0100194Memory Regions
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000195--------------
196
197- compatible [mandatory]
198 - value type: <string>
J-Alves2672cde2020-05-07 18:42:25 +0100199 - Must be the string "arm,ffa-manifest-memory-regions".
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000200
201- description
202 - value type: <string>
203 - Name of the memory region e.g. for debugging purposes.
204
205- pages-count [mandatory]
206 - value type: <u32>
207 - Count of pages of memory region as a multiple of the translation granule
208 size
209
210- attributes [mandatory]
211 - value type: <u32>
Louis Mayencourt31030e52020-04-08 13:04:33 +0100212 - Mapping modes: ORed to get required permission
213
214 - 0x1: Read
215 - 0x2: Write
216 - 0x4: Execute
Olivier Deprez7a632c52022-05-12 18:17:05 +0200217 - 0x8: Security state
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000218
219- base-address
220 - value type: <u64>
221 - Base address of the region. The address must be aligned to the translation
222 granule size.
223 The address given may be a Physical Address (PA), Virtual Address (VA), or
Olivier Deprez7a632c52022-05-12 18:17:05 +0200224 Intermediate Physical Address (IPA). Refer to the FF-A specification for
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000225 more information on the restrictions around the address type.
226 If the base address is omitted then the partition manager must map a memory
227 region of the specified size into the partition's translation regime and
228 then communicate the region properties (including the base address chosen
229 by the partition manager) to the partition.
230
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500231- stream-ids
232 - value type: <prop-encoded-array>
233 - List of IDs belonging to a DMA capable peripheral device that has access to
234 the memory region represented by current node.
235 - Each ID must have been declared in exactly one device region node.
236
237- smmu-id
238 - value type: <u32>
239 - Identifies the SMMU IP that enforces the access control for the DMA device
240 that owns the above stream-ids.
241
242- stream-ids-access-permissions
243 - value type: <prop-encoded-array>
244 - List of attributes representing the instruction and data access permissions
245 used by the DMA device streams to access the memory region represented by
246 current node.
247
248.. _device_region_node:
249
Louis Mayencourt31030e52020-04-08 13:04:33 +0100250Device Regions
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000251--------------
252
253- compatible [mandatory]
254 - value type: <string>
J-Alves2672cde2020-05-07 18:42:25 +0100255 - Must be the string "arm,ffa-manifest-device-regions".
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000256
257- description
258 - value type: <string>
259 - Name of the device region e.g. for debugging purposes.
260
Olivier Deprez7a632c52022-05-12 18:17:05 +0200261- pages-count [mandatory]
262 - value type: <u32>
263 - Count of pages of memory region as a multiple of the translation granule
264 size
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000265
266- attributes [mandatory]
267 - value type: <u32>
Louis Mayencourt31030e52020-04-08 13:04:33 +0100268 - Mapping modes: ORed to get required permission
269
270 - 0x1: Read
271 - 0x2: Write
272 - 0x4: Execute
Olivier Deprez7a632c52022-05-12 18:17:05 +0200273 - 0x8: Security state
274
275- base-address [mandatory]
276 - value type: <u64>
277 - Base address of the region. The address must be aligned to the translation
278 granule size.
279 The address given may be a Physical Address (PA), Virtual Address (VA), or
280 Intermediate Physical Address (IPA). Refer to the FF-A specification for
281 more information on the restrictions around the address type.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000282
283- smmu-id
284 - value type: <u32>
285 - On systems with multiple System Memory Management Units (SMMUs) this
286 identifier is used to inform the partition manager which SMMU the device is
287 upstream of. If the field is omitted then it is assumed that the device is
288 not upstream of any SMMU.
289
Louis Mayencourt31030e52020-04-08 13:04:33 +0100290- stream-ids
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000291 - value type: <prop-encoded-array>
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500292 - List of IDs where an ID is a unique <u32> value amongst all devices assigned
293 to the partition.
Louis Mayencourt950ef2f2020-03-27 11:49:20 +0000294
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500295- interrupts
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000296 - value type: <prop-encoded-array>
297 - A list of (id, attributes) pair describing the device interrupts, where:
Louis Mayencourt950ef2f2020-03-27 11:49:20 +0000298
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000299 - id: The <u32> interrupt IDs.
Olivier Deprez7a632c52022-05-12 18:17:05 +0200300 - attributes: A <u32> value, containing attributes for each interrupt ID:
301
302 +----------------------+----------+
303 |Field | Bit(s) |
304 +----------------------+----------+
305 | Priority | 7:0 |
306 +----------------------+----------+
307 | Security state | 8 |
308 +----------------------+----------+
309 | Config(Edge/Level) | 9 |
310 +----------------------+----------+
311 | Type(SPI/PPI/SGI) | 11:10 |
312 +----------------------+----------+
Louis Mayencourt950ef2f2020-03-27 11:49:20 +0000313
Olivier Deprez7a632c52022-05-12 18:17:05 +0200314 Security state:
315 - Secure: 1
316 - Non-secure: 0
317
318 Configuration:
319 - Edge triggered: 0
320 - Level triggered: 1
321
322 Type:
323 - SPI: 0b10
324 - PPI: 0b01
325 - SGI: 0b00
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000326
Raghu Krishnamurthy7e7242d2023-01-16 12:43:40 -0800327- interrupts-target
328 - value type: <prop-encoded-array>
329 - A list of (id, mpdir upper bits, mpidr lower bits) tuples describing which
330 mpidr the interrupt is routed to, where:
331
332 - id: The <u32> interrupt ID. Must be one of those specified in the
333 "interrupts" field.
334 - mpidr upper bits: The <u32> describing the upper bits of the 64 bits
335 mpidr
336 - mpidr lower bits: The <u32> describing the lower bits of the 64 bits
337 mpidr
338
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000339- exclusive-access
340 - value type: <empty>
341 - Presence of this field implies that this endpoint must be granted exclusive
David Horstmann051fd6d2020-11-12 15:19:04 +0000342 access and ownership of this device's MMIO region.
Louis Mayencourt5f0fc152019-11-29 15:05:14 +0000343
344--------------
345
Madhukar Pappireddy5df35bb2024-07-25 17:40:23 -0500346*Copyright (c) 2019-2024, Arm Limited and Contributors. All rights reserved.*