Debian Codegraph @

dtschema/schemas/iommu/iommu.yaml

raw
1 # SPDX-License-Identifier: BSD-2-Clause
2 # Copyright 2018 Linaro Ltd.
3 %YAML 1.2
4 ---
5 $id: http://devicetree.org/schemas/iommu/iommu.yaml#
6 $schema: http://devicetree.org/meta-schemas/base.yaml#
7
8 title: IOMMU Consumer Common Properties
9
10 maintainers:
11 - Rob Herring <[email protected]>
12
13 # always select the core schema
14 select: true
15
16 properties:
17 iommus:
18 description: >
19 A list of phandle and IOMMU specifier pairs that describe the IOMMU master
20 interfaces of the device. One entry in the list describes one master
21 interface of the device.
22
23 When an "iommus" property is specified in a device tree node, the IOMMU
24 will be used for address translation. If a "dma-ranges" property exists in
25 the device's parent node it will be ignored. An exception to this rule is
26 if the referenced IOMMU is disabled, in which case the "dma-ranges"
27 property of the parent shall take effect. Note that merely disabling a
28 device tree node does not guarantee that the IOMMU is really disabled
29 since the hardware may not have a means to turn off translation. But it is
30 invalid in such cases to disable the IOMMU's device tree node in the first
31 place because it would prevent any driver from properly setting up the
32 translations.
33 $ref: /schemas/types.yaml#/definitions/phandle-array
34
35 pasid-num-bits:
36 description:
37 Some masters support multiple address spaces for DMA, by tagging DMA
38 transactions with an address space identifier. By default, this is 0,
39 which means that the device only has one address space.
40 default: 0
41
42 dma-can-stall:
43 type: boolean
44 description: >
45 When present, the master can wait for a transaction to complete for an
46 indefinite amount of time. Upon translation fault some IOMMUs, instead of
47 aborting the translation immediately, may first notify the driver and keep
48 the transaction in flight. This allows the OS to inspect the fault and,
49 for example, make physical pages resident before updating the mappings and
50 completing the transaction. Such IOMMU accepts a limited number of
51 simultaneous stalled transactions before having to either put
52 back-pressure on the master, or abort new faulting transactions.
53
54 Firmware has to opt-in stalling, because most buses and masters don't
55 support it. In particular it isn't compatible with PCI, where transactions
56 have to complete before a time limit. More generally it won't work in
57 systems and masters that haven't been designed for stalling. For example
58 the OS, in order to handle a stalled transaction, may attempt to retrieve
59 pages from secondary storage in a stalled domain, leading to a deadlock.
60
61 additionalProperties: true