horn_vm
General VM protocol. Availability is advertised, not implied by declaration.
On this page
- VmInfo (Record)
- VmMemoryInfo (Record)
- VmRegionRequest (Record)
- VmRegionInfo (Record)
- VmRange (Record)
- VmMap (Record)
- VmProtect (Record)
- VmBatchError (Record)
- VmFault (Record)
- VmFaultMap (Record)
- VmFaultReject (Record)
- VmUntypedGrant (Record)
- VmError (EnumDecl)
- VmBacking (EnumDecl)
- VmPlacement (EnumDecl)
- VmUpdate (EnumDecl)
- VmFaultReason (EnumDecl)
- VmFaultReply (EnumDecl)
- VmProtection (FlagsDecl)
- VmMemoryRights (FlagsDecl)
- VmFeatures (FlagsDecl)
- VmMemory (Interface)
- VmAddressSpace (Interface)
- VmRegion (Interface)
- VmPager (Interface)
- VmUntyped (Interface)
- VmFactory (Interface)
- VmMemoryObject (Object)
- VmAddressSpaceObject (Object)
- VmRegionObject (Object)
- VmPagerObject (Object)
- VmUntypedObject (Object)
- VmService (Object)
- VmHost (Object)
Interfaces
VmMemory #
net.nhnn.horn.vm.memory, version 3.0, default transport sync, strict
info #
info() → Result[VmMemoryInfo, VmError]
Transport: sync, label: 0x29c774137eac9
duplicate #
duplicate(ceiling: VmProtection) → Result[Cap[VmMemoryObject, move, ALL], VmError]
Transport: sync, label: 0xc44fa17b8b6a9
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmMemoryObject |
move | ALL |
close #
close() → Result[void, VmError]
Transport: sync, label: 0xe2b75210c306c
revoke #
revoke() → Result[void, VmError]
Transport: sync, label: 0x1a01060a4a6dc
make_immutable #
make_immutable() → Result[void, VmError]
Transport: sync, label: 0x89935fad817ea
delegate #
delegate(rights: VmMemoryRights) → Result[Cap[VmMemoryObject, move, ALL], VmError]
Transport: sync, label: 0xd20673cc42a89
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmMemoryObject |
move | ALL |
rights #
rights() → Result[VmMemoryRights, VmError]
Transport: sync, label: 0xefe715c1bfbd
VmAddressSpace #
net.nhnn.horn.vm.space, version 1.0, default transport sync, strict
reserve #
reserve(request: VmRegionRequest) → Result[Cap[VmRegionObject, move, ALL], VmError]
Transport: sync, label: 0xb94da00cfd75f
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmRegionObject |
move | ALL |
destroy #
destroy() → Result[void, VmError]
Transport: sync, label: 0xa604f56f85ec7
VmRegion #
net.nhnn.horn.vm.region, version 1.0, default transport sync, strict
info #
info() → Result[VmRegionInfo, VmError]
Transport: sync, label: 0x2115253751352
apply #
apply(memory: Option[Cap[VmMemoryObject, borrow, ALL]], updates: Parcel[List[VmUpdate, 16]]) → Result[void, VmBatchError]
Transport: sync, label: 0x60e4834b20e93
Request capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
memory? |
VmMemoryObject |
borrow | ALL |
bind_pager #
bind_pager(pager: Cap[VmPagerObject, borrow, ALL], cookie: u64) → Result[void, VmError]
Transport: sync, label: 0x2a26ef1bc7e05
Request capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
pager |
VmPagerObject |
borrow | ALL |
destroy #
destroy() → Result[void, VmError]
Transport: sync, label: 0x346002e1110a
VmPager #
net.nhnn.horn.vm.pager, version 1.0, default transport sync, strict
drain #
drain() → Result[Parcel[List[VmFault, 16]], VmError]
Transport: sync, label: 0x853329549011b
resolve #
resolve(memory: Option[Cap[VmMemoryObject, borrow, ALL]], replies: Parcel[List[VmFaultReply, 16]]) → Result[void, VmBatchError]
Transport: sync, label: 0x84a199a00f5b8
Request capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
memory? |
VmMemoryObject |
borrow | ALL |
destroy #
destroy() → Result[void, VmError]
Transport: sync, label: 0xce46c7f9ad1ae
VmUntyped #
net.nhnn.horn.vm.untyped, version 1.0, default transport sync, strict
capability #
capability() → Result[VmUntypedGrant, VmError]
Transport: sync, label: 0x1f6175511e214
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok.capability |
sel4.Untyped |
copy | ALL |
close #
close() → Result[void, VmError]
Transport: sync, label: 0xfde4fdd83fcb2
VmFactory #
net.nhnn.horn.vm.factory, version 1.0, default transport sync, strict
info #
info() → Result[VmInfo, VmError]
Transport: sync, label: 0xa1a5ba1805c54
allocate #
allocate(size: u64, backing: VmBacking, ceiling: VmProtection) → Result[Cap[VmMemoryObject, move, ALL], VmError]
Transport: sync, label: 0xb0ef6eb74eb04
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmMemoryObject |
move | ALL |
create_address_space #
create_address_space() → Result[Cap[VmAddressSpaceObject, move, ALL], VmError]
Transport: sync, label: 0xbc67ee365a1b0
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmAddressSpaceObject |
move | ALL |
create_pager #
create_pager(wake: Cap[sel4.Notification, copy, WRITE]) → Result[Cap[VmPagerObject, move, ALL], VmError]
Transport: sync, label: 0xc83293da8671b
Request capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
wake |
sel4.Notification |
copy | WRITE |
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmPagerObject |
move | ALL |
delegate #
delegate(size_bits: u32) → Result[Cap[VmUntypedObject, move, ALL], VmError]
Transport: sync, label: 0x6677e245d7717
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmUntypedObject |
move | ALL |
derive #
derive(limit_bytes: u64) → Result[Cap[VmService, move, ALL], VmError]
Transport: sync, label: 0xb416862cbafba
Result capabilities
| Path | Target | Transfer | Rights |
|---|---|---|---|
result.Ok |
VmService |
move | ALL |
Objects
VmMemoryObject #
VmMemoryObject, transport sync
Implements: VmMemory
VmAddressSpaceObject #
VmAddressSpaceObject, transport sync
Implements: VmAddressSpace
VmRegionObject #
VmRegionObject, transport sync
Implements: VmRegion
VmPagerObject #
VmPagerObject, transport sync
Implements: VmPager
VmUntypedObject #
VmUntypedObject, transport sync
Implements: VmUntyped
VmService #
VmService, transport sync
Implements: VmFactory
VmHost #
VmHost, transport sync
Implements: VmFactory, VmMemory, VmAddressSpace, VmRegion, VmPager, VmUntyped
Records
VmInfo #
Wire size: 48 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
features |
VmFeatures |
0 |
page_size |
u64 |
8 |
batch_limit |
u32 |
16 |
limit_bytes |
u64 |
24 |
charged_bytes |
u64 |
32 |
quarantined_bytes |
u64 |
40 |
VmMemoryInfo #
Wire size: 24 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
size |
u64 |
0 |
resident_size |
u64 |
8 |
ceiling |
VmProtection |
16 |
immutable |
bool |
20 |
VmRegionRequest #
Wire size: 32 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
address |
u64 |
0 |
length |
u64 |
8 |
alignment |
u64 |
16 |
placement |
VmPlacement |
24 |
ceiling |
VmProtection |
28 |
VmRegionInfo #
Wire size: 24 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
address |
u64 |
0 |
length |
u64 |
8 |
ceiling |
VmProtection |
16 |
VmRange #
Wire size: 16 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
offset |
u64 |
0 |
length |
u64 |
8 |
VmMap #
Wire size: 32 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
offset |
u64 |
0 |
length |
u64 |
8 |
memory_offset |
u64 |
16 |
protection |
VmProtection |
24 |
VmProtect #
Wire size: 24 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
offset |
u64 |
0 |
length |
u64 |
8 |
protection |
VmProtection |
16 |
VmBatchError #
Wire size: 8 bytes, alignment: 4, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
completed |
u32 |
0 |
error |
VmError |
4 |
VmFault #
Wire size: 32 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
id |
u64 |
0 |
cookie |
u64 |
8 |
offset |
u64 |
16 |
access |
VmProtection |
24 |
VmFaultMap #
Wire size: 24 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
id |
u64 |
0 |
memory_offset |
u64 |
8 |
protection |
VmProtection |
16 |
VmFaultReject #
Wire size: 16 bytes, alignment: 8, maximum capabilities: 0
| Field | Type | Byte offset |
|---|---|---|
id |
u64 |
0 |
reason |
VmFaultReason |
8 |
VmUntypedGrant #
Wire size: 4 bytes, alignment: 4, maximum capabilities: 1
| Field | Type | Byte offset |
|---|---|---|
capability |
Cap[sel4.Untyped, copy, ALL] |
0 |
size_bits |
u32 |
0 |
Enums
VmError #
Base: u32
| Variant | Value |
|---|---|
| Invalid | 1 |
| Denied | 2 |
| Overlap | 3 |
| Exhausted | 4 |
| QuotaExceeded | 5 |
| Busy | 6 |
| Stale | 7 |
| Unsupported | 8 |
| Backend | 9 |
| Quarantined | 10 |
VmBacking #
Base: u32
| Variant | Value |
|---|---|
| Resident | 0 |
| DemandZero | 1 |
VmPlacement #
Base: u32
| Variant | Value |
|---|---|
| Anywhere | 0 |
| Fixed | 1 |
VmUpdate #
Base: u32
VmFaultReason #
Base: u32
| Variant | Value |
|---|---|
| Invalid | 1 |
| Denied | 2 |
| Exhausted | 3 |
VmFaultReply #
Base: u32
| Variant | Tag | Payload |
|---|---|---|
| Map | 0 | VmFaultMap |
| Reject | 1 | VmFaultReject |
Flags
VmProtection #
Base: u32
| Variant | Value |
|---|---|
| READ | 1 |
| WRITE | 2 |
| EXECUTE | 4 |
VmMemoryRights #
Base: u32
| Variant | Value |
|---|---|
| READ | 1 |
| WRITE | 2 |
| EXECUTE | 4 |
| DELEGATE | 8 |
| MAKE_IMMUTABLE | 16 |
| REVOKE | 32 |
| DMA | 64 |
| CLOSE | 128 |
VmFeatures #
Base: u32
| Variant | Value |
|---|---|
| RESIDENT | 1 |
| DEMAND_ZERO | 2 |
| PROTECTION | 4 |
| USER_PAGER | 8 |
| CREATE_SPACE | 16 |
| DERIVE_ACCOUNT | 32 |
| DUPLICATE_MEMORY | 64 |
| UNTYPED | 128 |
| IMMUTABLE | 256 |