Skip to content

Commit 6871f48

Browse files
committed
IOMMU: Update manual
Update the manual to include IOMMU information. Signed-off-by: Callum <c.berry@student.unsw.edu.au>
1 parent b398305 commit 6871f48

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

docs/manual.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ This document attempts to clearly describe all of these terms, however as the co
109109
* [interrupt](#irq)
110110
* [fault](#fault)
111111
* [ioport](#ioport)
112+
* [io address space](#io_address_space)
112113

113114
## System {#system}
114115

@@ -242,6 +243,13 @@ The mapping has a number of attributes, which include:
242243
* caching attributes (mostly relevant for device memory)
243244
* permissions (read, write and execute)
244245

246+
*Note:* On x86 a memory region can also be *mapped* into one or more
247+
io address spaces. This type of mapping is known as an *iomap*. It supports
248+
a number of attributes, which include:
249+
250+
* the io virtual address at which the region is mapped in the io address space
251+
* permissions (read, write)
252+
245253
**Note:** When a memory region is mapped into multiple protection
246254
domains, the attributes used for different mappings may vary.
247255

@@ -356,6 +364,12 @@ delivered to another PD, the fault being handled depends on when the parent PD i
356364

357365
I/O ports are x86 mechanisms to access certain physical devices (e.g. PC serial ports or PCI) using the `in` and `out` CPU instructions. The system description specifies if a protection domain have access to certain port address ranges. These accesses will be executed by seL4 and the result returned to protection domains.
358366

367+
## IO Address Spaces {#io_address_space}
368+
369+
IO Address Spaces provide a way to isolate device memory accesses within a fixed virtual address space. The isolation provided by the address space is enforced by the underlying hardware IOMMU or SMMU.
370+
371+
IO Address Spaces allow *memory regions* to be mapped to a provided base IO virtual address. These IO virtual addresses will be translated by the hardware IOMMU or SMMU to the underlying physical memory that backs the memory region.
372+
359373
# SDK {#sdk}
360374

361375
Microkit is distributed as a software development kit (SDK).
@@ -1056,6 +1070,23 @@ See the 'cap_sharing' example packaged in your SDK or [on GitHub](https://github
10561070
All capability elements (currently) all support the `pd` attribute, the name of the protection domain that the capability is from.
10571071
For instance, `<cap_tcb slot="1" pd="alpha">` will place the TCB of PD 'alpha' in the CSpace of the current PD.
10581072

1073+
## `io_address_space`
1074+
1075+
The `io_address_space` element describes an address space used to isolate a given device.
1076+
1077+
It supports the following attributes:
1078+
* `name`: A unique name for the io address space
1079+
* `peripheral_id`: A unique identifier. This must match the identifier used by the hardware IOMMU or SMMU to identify devices.
1080+
1081+
The `io_address_space` element supports the following elements as children:
1082+
1083+
* `iomap`: This is used to map a *memory_region* into the io address space.
1084+
1085+
The `iomap` element supports the following attributes:
1086+
* `mr`: Identifies the memory region to map.
1087+
* `iovaddr`: Identifies the io virtual address at which to map the memory region.
1088+
* `perms`: Identifies the permissions with which to map the memory region. Can be a combination of `r` (read), and `w` (write).
1089+
Defaults to read-write.
10591090

10601091
### Page sizes by architecture
10611092

0 commit comments

Comments
 (0)