Reference
Glossary
Every term the course uses, in one plain line each, with the chapter or primer that teaches it.
#
- /chosen
- The device-tree node that describes no device: it carries settings for the operating system, such as its console (
stdout-path) and command line (bootargs). Taught in chapter 10. - #address-cells / #size-cells
- Two properties of a device-tree node that say how many cells each address and each size in its children's
regtakes. Taught in chapter 10.
A
- AArch64
- The 64-bit instruction set of Arm CPUs, the one your Mac runs. Taught in the aarch64-reading primer.
- active interrupt
- One the CPU has acknowledged (read from the IAR) and not yet ended with an EOI; while active it is not delivered again. Active and pending means it is being handled and its source is asking again. Taught in chapter 12.
- ad-hoc signature
- A code signature made on your own Mac without an Apple certificate; enough to carry an entitlement for local use. Taught in the codesign-entitlements primer.
- address size fault
- The fault a CPU raises when an address is too large for the memory it can address; with the guest's translation off, it is taken at the guest's own level and never reaches the VMM. Taught in chapter 03.
- ADR (architecture decision record)
- A short document recording one design decision: its context, the choice, the alternatives and the consequences. Taught in chapter 21.
- affinity
- The fields of
MPIDR_EL1that give a CPU's address in a hierarchy:Aff0numbers CPUs within a cluster,Aff1numbers clusters. Taught in chapter 06. - affinity routing
- The GICv3 rule that names a CPU by its
MPIDR_EL1affinity number; a shared interrupt is sent to the CPU whose affinity is written in its routing register. Taught in chapter 12. - AFFINITY_INFO
- The PSCI call that asks whether a CPU is on (0), off (1) or on pending (2). Taught in chapter 20.
- alignment fault
- The exception a load or store takes when its address is not a multiple of its size and the CPU checks alignment (
SCTLR_EL1.A = 1, or Device memory). Taught in chapter 06. - arm64 Image
- The flat-binary form of a Linux kernel for 64-bit Arm; its first 64 bytes are a header that tells the loader where the kernel must sit and how much memory it uses. Taught in chapter 13.
- ARP (Address Resolution Protocol)
- The broadcast question "who has this IPv4 address?" and its answer, which tells a sender the MAC address to put in its frames. Taught in chapter 19.
- assert
- For an interrupt line, to drive it high: the source is asking for attention now. A level-triggered source keeps asserting its line until its cause is removed. Taught in chapter 11.
- auxiliary storage
- A file VZ keeps beside a macOS guest's disk, holding data the boot loader and the guest need, such as boot settings; a VM must always boot with the one it was installed with. Taught in chapter 23.
- available ring
- The ring only the driver writes: the head descriptor of each request it offers, and
avail.idx, how many requests it has offered so far. Taught in chapter 16. - AVPBooter
- Apple's boot ROM for macOS virtual machines,
AVPBooter.vmapple2.bininside Virtualization.framework; macvmm reads it in place at run time and never copies it. Taught in chapter 24.
B
- bare-metal program
- A program that runs with no operating system under it: it sets up its own stack and zeroed memory, then calls its main function. Taught in chapter 03.
- bdif (backdoor block interface)
- The simple disk-reading device of QEMU's vmapple board: the guest writes the address of a three-entry descriptor (sector, data, status) and the device copies 512-byte sectors into guest memory. Taught in chapter 24.
- big-endian
- Storing a multi-byte number most significant byte first; every number in a DTB is stored this way, the opposite of AArch64's usual little-endian order. Taught in chapter 10.
- binary translation
- Rewriting a guest's machine code just before it runs, so the instructions that would misbehave become traps or calls. Taught in chapter 00.
- binding document
- A short schema, one per kind of device, kept in the Linux source tree, that says what each device-tree property of that device means. Not the same as driver binding. Taught in chapter 10.
- boot CPU
- The CPU that starts running at power-on (our vCPU 0); every other CPU is a secondary CPU and starts off. Taught in chapter 20.
- boot log
- The lines a kernel prints while it starts, in stages that each depend on the one before; on Arm most of them report what the device tree told the kernel. Taught in chapter 14.
- boot plan
- The printed, testable list of where every boot input goes in guest RAM and which register values the vCPU starts with; ours is
BootPlan, shown by--dry-run. Taught in chapter 13. - bootargs
- The property of
/chosenthat holds the kernel command line, such asconsole=ttyAMA0. Taught in chapter 10. - bounce buffer
- A fresh, zeroed host buffer that data passes through between a file and guest memory, capped in size, so the guest never sees bytes left from another request. Taught in chapter 18.
- BSS
- The part of a program's memory for variables that start at zero; the file holds no bytes for it, so start-up code must zero it. Taught in the bare-metal-rust primer.
- bundle
- In vz-mac, the directory that holds one macOS guest: its disk image, auxiliary storage, hardware model and machine identifier. Taught in chapter 23.
- bus mastering
- A device reading and writing main memory by itself, without the CPU copying each byte; the hardware name for what DMA does. Taught in chapter 15.
C
- C1 control
- One of the 8-bit control bytes
0x80to0x9F; some terminals treat one alone as the start of an escape sequence (0x9bas CSI, the same asESC [), so vz-mac's console filter never prints one raw. Taught in chapter 23. - canary
- A region of memory nobody should touch, hashed before and after a test; if any byte changed, something wrote where it had no right to. Taught in chapter 25.
- caret notation
- Showing a control byte as
^followed by the byte plus0x40, so ESC (0x1b) prints as^[; vz-mac's console filter uses it so no escape sequence reaches your terminal. Taught in chapter 23. - cell
- The unit device-tree numbers are counted in: one 32-bit big-endian value. A 64-bit address takes two. Taught in chapter 10.
- cfg block
- The configuration page of QEMU's vmapple board that the boot ROM reads to learn about its machine (version, CPU count, ECID, RAM size and fields nobody has explained). Taught in chapter 24.
- CFI (Common Flash Interface)
- The JEDEC standard command set (JESD68) that software uses to query, erase and program a flash chip. Taught in chapter 21.
- checked arithmetic
- Arithmetic that reports overflow instead of hiding it; in Rust,
checked_addreturnsNonewhen the true sum does not fit, so a bounds check cannot be fooled by a sum that wrapped. Taught in chapter 04. - CNTFRQ_EL0 (counter-timer frequency)
- The register that tells a guest how fast its counter ticks, in Hz; 24,000,000 under Hypervisor.framework. Taught in chapter 11.
- CNTV_CTL_EL0 (counter-timer virtual timer control)
- The virtual timer's control bits:
ENABLE,IMASK(mask its interrupt) and the read-onlyISTATUS(the count has reached the compare value). Taught in chapter 11. - CNTV_CVAL_EL0 (counter-timer virtual timer compare value)
- The virtual timer's alarm: the count at which it raises its interrupt. Taught in chapter 11.
- CNTVCT_EL0 (counter-timer virtual count)
- The count a guest reads for time; under Hypervisor.framework it is the host's tick count minus the VM's counter offset, at 24 MHz as Hypervisor.framework presents it. Taught in chapter 11.
- Companion
- In macvmm, a second host thread that belongs to one virtio device, such as a network card's receive thread; it is attached to the device's worker, so stopping the worker stops and joins it too. Taught in chapter 19.
- compatibility log
- A file per guest (ours are in
docs/compat/) that records how far the guest boots, the transcript and trace at any blocker, its root cause, and a ranked list of what could go wrong next. Taught in chapter 22. - compatible
- The device-tree property that names what a device is, most specific first, such as
"arm,pl011", "arm,primecell"; a kernel picks a driver by matching it. Taught in chapter 10. - compromised VMM
- The VMM process after an attacker has made it run their code: it acts with your rights, the hypervisor entitlement and every file it holds open. Taught in chapter 25.
- conduit
- The instruction that carries an SMCCC call to the level above:
hvc(to EL2) orsmc(to EL3). Under HVF both reach our VMM, with different PC rules. Taught in chapter 08. - ConfigGeneration
- A virtio-mmio register the device changes whenever its configuration changes; a driver reads it before and after reading config fields and retries if it moved. Taught in chapter 15.
- configuration space
- A virtio device's own settings, such as a disk's capacity or a network card's MAC address; in virtio-mmio it starts at offset
0x100of the device's window. Config space for short. Taught in chapter 15. - confused deputy
- A privileged program tricked into using its rights for someone else, such as a VMM opening a file it was handed for another purpose. Taught in chapter 25.
- containment
- Limiting what a program can do even after an attacker has taken it over, such as a sandbox the kernel enforces; not the same as holding no entitlement. Taught in chapter 19.
- context ID
- The value the caller of
CPU_ONchooses; the new CPU finds it inx0at its first instruction. Taught in chapter 20. - controlled variable
- In an experiment, the one thing you change on purpose while keeping everything else the same, so that any difference in the result can be traced to it. Taught in chapter 24.
- copy-only access
- The rule that our VMM reaches guest RAM only by copying bytes into and out of its own buffers, never through a reference into guest memory. Taught in chapter 04.
- copy-then-validate
- The rule that defeats double fetches: copy a guest structure once, check the copy, and use only the copy. Taught in chapter 16.
- corpus
- The set of good inputs a fuzzer starts from and damages; ours is drawn fresh from a generator of well-formed rings. Taught in chapter 25.
- counter offset
- The number Hypervisor.framework subtracts from the host's tick count to make a vCPU's virtual counter; a VMM sets it so the guest's counter starts near zero and is the same on every vCPU. Taught in chapter 11.
- coverage-guided fuzzing
- Fuzzing that watches which code each input reaches and keeps mutating the inputs that reached new code; libFuzzer, behind
cargo fuzz, works this way, and our blind loop does not. Taught in chapter 25. - CPSR / PSTATE (current program status register / processor state)
- The CPU's current mode and flags: which exception level, which stack pointer, which interrupts are masked. Taught in chapter 02.
- CPU interface
- The part of the GIC inside each CPU, used through
ICC_*system registers: it masks by priority, hands the CPU the next interrupt (IAR) and takes the end-of-interrupt (EOI). Taught in chapter 12. - CPU_OFF
- The PSCI call with which a CPU turns itself off; it does not return to the caller while the CPU is off. Taught in chapter 20.
- CPU_ON
- The PSCI call that starts an off CPU at an entry point, with a context ID in its
x0; it names the CPU by its MPIDR affinity. Taught in chapter 20. - CPU_ON mailbox
- Our VMM's one slot per vCPU that holds the entry point and context ID of an accepted
CPU_ONuntil that vCPU's thread takes it. Taught in chapter 20. - CSPRNG (cryptographically secure pseudo-random number generator)
- A generator whose output cannot be predicted from earlier output; on a Mac, the kernel's, read with
getentropy. Taught in chapter 17.
D
- DAIF
- Four mask bits in PSTATE (debug, SError, IRQ, FIQ) that stop those kinds of asynchronous exception from interrupting. Taught in chapter 02.
- data abort
- The exception a load or store takes when its address cannot be accessed; for a guest, often a VM exit at a stage-2 hole. Taught in chapter 05.
- debug hypercall
- One of the two calls our test guests make with
hvcto print a byte or to stop with an exit code; numbered by SMCCC as vendor-specific hypervisor calls. Taught in chapter 03. - defence in depth
- Several independent checks guarding the same thing, so that one missing check is caught by another. Taught in chapter 25.
- descriptor
- A 16-byte entry in a virtqueue's descriptor table naming one guest buffer: its address, its length, flags (
NEXT,WRITE,INDIRECT) and the index of the next descriptor. Taught in chapter 16. - descriptor chain
- The descriptors of one request, linked through their
nextfields; buffers the device reads come first, buffers it writes come after. Taught in chapter 16. - descriptor table
- The first part of a split virtqueue: N descriptors of 16 bytes, written only by the driver, at the address the driver wrote to
QueueDesc. Taught in chapter 16. - device status
- The virtio
Statusregister: bits the driver sets one at a time (ACKNOWLEDGE, DRIVER, FEATURES_OK, DRIVER_OK) as it brings a device up, and clears all at once by writing 0. Taught in chapter 15. - Device Tree (DT)
- A tree of nodes and properties that describes a machine's memory, CPUs and devices to the operating system that runs on it. Taught in chapter 10.
- device worker thread
- A host thread that belongs to one virtio device and does its queue work, so the vCPU thread that took the doorbell exit only sets a bit, wakes it, and returns to the guest. Taught in chapter 17.
- DEVICE_NEEDS_RESET
- The virtio status bit (value 64) a device sets when the driver gave it something it cannot use, such as a ring outside RAM; the device does nothing more until the driver writes 0 to
Status. Taught in chapter 15. - device-access trace
- The record of every guest access to an address with no device behind it, as program counter, address, size, direction and value; macvmm's logger prints at most 256 per boot, and none of it is published. Taught in chapter 24.
- device-tree node
- One entry of a Device Tree, named like
pl011@9000000, holding properties and child nodes. Taught in chapter 10. - device-tree property
- A named value inside a node, such as
regorcompatible; its bytes mean whatever the binding for that name says. Taught in chapter 10. - DFSC (data fault status code)
- Low bits of the syndrome that say which kind of data fault happened (for example translation fault). Taught in chapter 05.
- direct boot
- Starting a guest with the VMM as its bootloader: the VMM places the kernel, initramfs and DTB in RAM and starts the vCPU at the kernel's entry with
x0= the DTB's address; no firmware runs. The other way is the firmware boot protocol. Taught in chapter 21. - distributor
- The one GIC block shared by all CPUs; it holds the settings of every shared interrupt (enabled, priority, trigger, target CPU). Its registers are named
GICD_*. Taught in chapter 12. - DMA (direct memory access)
- A device reading or writing RAM by itself, without the CPU. Taught in chapter 15.
- doorbell
- A register a driver writes only to say "look now": one MMIO exit that tells the device new requests are waiting in memory. In virtio-mmio it is
QueueNotify. Taught in chapter 15. - double fetch
- Reading the same guest value twice, once to check it and once to use it; the TOCTOU bug in its most common form. Taught in chapter 16.
- driver binding
- The kernel attaching a driver to a device-tree node whose
compatiblestring the driver lists. Taught in chapter 10. - drop-and-count
- A device's answer to a frame it cannot deliver (no buffer posted, wrong size, wrong sender): discard it, add one to a named counter, never wait and never fail the device. Taught in chapter 19.
- DTB (device tree blob)
- The binary form of a Device Tree that firmware or a VMM hands to a kernel; on arm64 its address arrives in
x0. Taught in chapter 10. - dtc (device tree compiler)
- The standard tool that converts between a DTB and its text form; we use it as an independent checker. Taught in chapter 10.
- DTS (device tree source)
- The text form of a Device Tree, as
dtcprints it. Taught in chapter 10.
E
- earlycon
- A Linux command-line option that makes the kernel write to a serial port by address from its first moments, before any console driver exists. Taught in chapter 14.
- EC (exception class)
- The top six bits of an ESR: the kind of exception, for example
0x16for anhvc. Taught in chapter 02. - ECAM (Enhanced Configuration Access Mechanism)
- The PCI Express rule that maps every device's configuration space into one block of memory addresses; under VZ, Linux lists it as
PCI ECAMin/proc/iomem. Taught in chapter 23. - ECID (exclusive chip ID)
- The 64-bit identity number of a macOS virtual machine, held inside its machine identifier; QEMU's vmapple board hands it to the boot ROM in the cfg block and calls it
uuid. Taught in chapter 24. - edge-triggered
- An interrupt signalled by a change, a one-off event; if nobody is listening and nothing latches it, it is lost. Taught in chapter 11.
- EDK2
- The reference implementation of UEFI; its
ArmVirtQemubuild is firmware for QEMU'svirtmachine. Taught in chapter 21. - EFI stub
- Code built into a Linux kernel that lets UEFI firmware start it directly as a UEFI program; it is why an arm64 Image begins with the bytes
MZ. Taught in chapter 13. - EFI zboot
- A wrapper around a compressed Linux kernel: a small UEFI program (its file starts with
MZ, withzimgat offset 4) that decompresses the real Image and jumps to it. Our VMM refuses it by name;cargo xtask unzbootunwraps it on the host. Taught in chapter 13. - EL0, EL1, EL2, EL3 (exception levels)
- Arm's privilege levels: EL0 apps, EL1 a kernel, EL2 the level that supervises kernels, EL3 firmware. Higher number, more power. Taught in chapter 02.
- EL1h
- Running at EL1 using EL1's own stack pointer (
SP_EL1); the usual mode of a kernel. Taught in chapter 02. - EL1t
- Running at EL1 but using EL0's stack pointer (
SP_EL0); PSTATE0x3c4with all masks set. Exceptions taken to EL1 still switch toSP_EL1. Taught in chapter 06. - ELR (exception link register)
- Where the CPU will return to after an exception; the saved PC. Taught in chapter 02.
- emulated device
- A device the VMM imitates register by register, so an unmodified guest driver works; every register access traps to the VMM. Taught in chapter 00.
- emulator
- A program that pretends to be a CPU, carrying out each guest instruction in software. Correct, but slow. Taught in chapter 00.
- entitlement
- A permission written into a program's signature; ours is
com.apple.security.hypervisor. Taught in the codesign-entitlements primer. - entry point
- The address of a program's first instruction; for flat binaries loaded with
--raw, the load address of the first one, since the file has no header to name it. Taught in chapter 03. - entry state
- The registers and CPU mode a kernel may rely on at its first instruction; for Linux on 64-bit Arm, section 4 of
booting.rst. Taught in chapter 13. - EOI (end of interrupt)
- The write (
ICC_EOIR1_EL1) with which a handler tells the GIC it has finished an interrupt; a level line still high at that moment makes the interrupt pending again. Taught in chapter 12. - ERET (exception return)
- The instruction that ends an exception handler: the PC is set from
ELRand the mode and flags fromSPSR. Taught in chapter 02. - ESR (exception syndrome register)
- The register that records why an exception happened. Taught in chapter 02.
- Ethernet frame
- The unit a network card sends: a 14-byte header (destination MAC, source MAC, a two-byte type) and up to 1500 bytes of payload, so at most 1514 bytes without the wire's checksum. Taught in chapter 19.
- exception
- On Arm, anything that makes the CPU stop the current flow and run a handler at the same or a higher level: a system call, a fault, an interrupt. Not the same as a Rust panic or a C++ exception. Taught in the os-basics primer.
- exception vector table
- A table of handler addresses the kernel sets up; the CPU jumps to the entry for the kind of exception. Its base is in
VBAR. Taught in the os-basics primer. - exclusive monitor
- The hardware that remembers which address a load-exclusive (
ldxr) reserved, so that the matching store-exclusive (stxr) can fail if anyone else wrote there; our VMM does not model it, so it refuses exclusives. Taught in chapter 21. - execute in place
- Running code straight from flash, before the program has copied itself into RAM. Taught in chapter 21.
- exit code
- The number a process returns to the shell when it ends.
macvmm's codes are on the reference card. Not a VM exit. Taught in the os-basics primer. - exit cost
- The time one VM exit takes, guest to VMM and back; about 1.5 µs on our Mac, thousands of times the cost of one store instruction. Taught in chapter 03.
- exit reason
- The first field of HVF's exit record, saying why
hv_vcpu_runreturned: a guest exception (with its syndrome), the virtual timer, a cancel from another thread, or unknown. Taught in chapter 02. - exit ring
- A small per-vCPU memory of the last 256 VM exits, printed when the guest stops with a fatal error. Taught in chapter 07.
- exit trace
- A file with one line per VM exit (time, PC, exception class), written by
macvmm --trace, so you can count and read a guest's exits. Taught in chapter 03.
F
- fail closed
- To stop when a safety mechanism cannot be applied, instead of carrying on without it; macvmm's default sandbox exits 1 if the lockdown fails. Taught in chapter 25.
- failure fingerprint
- What a broken part of the machine looks like from outside: the last boot stage reached, what the kernel says, and how the VMM exits. Taught in chapter 14.
- FAR (fault address register)
- The address a faulting access tried to use. Taught in chapter 02.
- fast call
- An SMCCC call that runs to completion without being interrupted part-way; all of ours are fast. Taught in the smccc primer.
- FDT (flattened device tree)
- The binary format of a DTB: a header, a memory reservation map, a structure block of tokens and a strings block, all big-endian. Taught in chapter 10.
- feature negotiation
- The virtio step in which the device offers feature bits, the driver accepts a subset, and the device confirms or refuses it through
FEATURES_OK. Taught in chapter 15. - FFI (foreign function interface)
- Calling functions written in another language, here C functions in Apple's framework from Rust, by declaring their exact types. Taught in chapter 01.
- FIFO (first in, first out)
- A small queue inside a device; bytes leave in the order they arrived. The PL011's receive FIFO holds 32 bytes. Taught in chapter 09.
- FIQ (fast interrupt request)
- Arm's second kind of interrupt, with its own PSTATE mask bit (F) and its own vector entries; the kernels in this course use IRQ. Taught in chapter 11.
- firmware
- The program a CPU runs first after power-on; it sets up the hardware, loads the kernel, and answers a few requests such as power-off. Taught in the os-basics primer.
- firmware boot protocol
- The rule for starting a QEMU-
virtstyle machine through firmware: the firmware sits in flash at0x0, the DTB at the start of RAM (where U-Boot looks for it), and the vCPU starts atPC = 0. Our VMM also passes the DTB's address inx0, as Linux's boot protocol does. Taught in chapter 21. - flash (NOR flash)
- Memory that keeps its contents without power and reads like ROM, so firmware can run from it in place; changing it takes a command sequence, not a plain store. Taught in chapter 21.
- flat binary
- Raw machine code and data copied byte for byte into guest memory, with no headers; what
objcopymakes from an ELF file. Taught in chapter 03. - FLUSH
- The virtio-blk request (type 4) that asks for every completed write to be made durable; the device may answer OK only once the data would survive a power cut. Taught in chapter 18.
- free-running index
- A counter that only goes up and wraps at 65536; the ring slot is the counter modulo the queue size, and the wrapping difference of two counters is how many entries lie between them. Taught in chapter 16.
- function ID
- The 32-bit number in
w0that names an SMCCC call, with fields for fast or yielding, 32- or 64-bit convention, owner and function number. Taught in chapter 08. - fuzz target
- One function the fuzzer calls with a byte string; it decodes the bytes into an input for one parser or device model, runs the real code, and checks the invariants. Taught in chapter 25.
- fuzzing
- Testing by generating very many slightly wrong inputs, running the real code on each, and checking that nothing went wrong. Taught in chapter 25.
G
- generic timer
- Arm's per-core counter and alarm: a count that rises at a fixed rate, a compare value and control bits that raise an interrupt when the count reaches it. Taught in chapter 11.
- GET_ID
- The virtio-blk request (type 8) that asks for the disk's serial number, at most 20 bytes; Linux sends it when
/sys/block/vda/serialis read. Taught in chapter 18. - GIC (Generic Interrupt Controller)
- Arm's interrupt controller. It gathers many interrupt lines, ranks them by priority and delivers each to a chosen CPU; we use version 3, which Hypervisor.framework emulates in the kernel. Taught in chapter 12.
- GicSpi
- Our
IrqLineconnected to one SPI of the in-kernel GIC; it refuses an INTID that is not an SPI, and passes each level change tohv_gic_set_spi. Taught in chapter 12. - granule
- The page size a translation table uses: 4 KiB, 16 KiB or 64 KiB. Taught in the page-granules primer.
- guest
- The operating system (or test program) running inside a virtual machine. Taught in chapter 00.
- guest RAM
- Host memory our VMM allocates and maps into the guest's address space; the guest and our VMM see the same bytes. Taught in chapter 04.
- GuestMemory
- The fixed set of calls (
read,write,check_range, little-endian helpers,read_obj) through which every part of our VMM touches guest RAM, each one bounds-checked. Taught in chapter 04. - GuestMemoryOrdered
- The guest-memory trait that adds the two ordered accessors a split virtqueue needs (an acquire load and a release store of a 16-bit index) and a full fence. Taught in chapter 16.
H
- hardware model
- In VZ, an opaque value naming the kind of virtual Mac a macOS guest was installed for; every later boot must use the same one. Taught in chapter 23.
- hardware-assisted virtualization
- CPU support for a level above the kernel whose software chooses what traps, so a guest kernel can run in a real kernel mode at full speed. Taught in chapter 00.
- head
- The index of a request's first descriptor, which the driver puts in the available ring and the device returns in the used ring. Taught in chapter 16.
- hop budget
- A limit on how many descriptors one chain walk may visit (the queue size); it stops loops without remembering where the walk has been. Taught in chapter 16.
- host
- The real machine's operating system, here macOS. Taught in chapter 00.
- host bridge
- The PCI device that connects the CPU to the PCI bus; under VZ it is the Apple device (vendor
0x106b) at the start of the bus. Taught in chapter 23. - host page
- The Mac's own memory page, 16 KiB on Apple silicon; HVF's stage-2 mappings come in whole, aligned host pages. Taught in chapter 04.
- hostile guest
- Any guest that misbehaves on purpose (a malicious guest); in this course also the suite of test guests that attacks the VMM from inside a real virtual machine, phase by phase, each phase with the exit code the VMM must end with. Taught in chapter 25.
- HPFAR_EL2 (hypervisor IPA fault address register)
- Holds the page number of the guest-physical address (IPA) of a stage-2 fault; with the offset from
FAR_EL2, it gives the VMM the IPA without reading the guest's page tables. Taught in chapter 05. - hv_return_t
- The 32-bit result of every Hypervisor.framework call: 0 for success, otherwise an error code of the form
0xfae94000 | n, such asHV_DENIED(0xfae94007). Taught in chapter 01. - hvc (hypervisor call)
- An instruction a guest kernel uses to call the level above it; the
svcof EL1. Taught in chapter 02. - hvc0
- Linux's first hypervisor virtual console, the tty name a virtio-console gets; unrelated to the
hvcinstruction. Taught in chapter 17. - HVF (Hypervisor.framework)
- Apple's library that lets an ordinary process create VMs and run vCPUs; it makes system calls into the part of macOS that runs at EL2. Taught in chapter 01.
- hypercall
- A deliberate call from a guest kernel to the VMM, asking for a service, the way a system call asks a kernel. Taught in chapter 00.
- hypervisor
- In this course, the part that runs at a CPU level more privileged than the kernel's (on Arm, EL2) and controls the CPU's support for virtual machines (on a Mac, part of macOS). Elsewhere, often used to mean the whole VMM. Taught in chapter 00.
I
- IAR (interrupt acknowledge register)
- The register (
ICC_IAR1_EL1) a handler reads first; it returns the INTID of the most urgent pending interrupt and marks it active, or 1023 if there is none. Taught in chapter 12. - iBoot
- Apple's boot loader on physical Apple-silicon Macs, the stages between the boot ROM and the kernel; whether a macOS virtual machine uses it is unknown to us. Taught in chapter 24.
- ID register
- A read-only system register, such as
ID_AA64DFR0_EL1, that tells software which features the CPU has. Taught in chapter 08. - IL (instruction length)
- Bit 25 of an ESR: 1 when the instruction that caused the exception is 32 bits long, which on AArch64 is always. Taught in chapter 02.
- image lock
- The advisory
flocka VMM takes on a disk image while it runs (exclusive to write, shared to read), so a second VMM cannot open the same image. Taught in chapter 18. - image_size
- The Image header field at offset
0x10: how many bytes of memory, from its first byte, the kernel uses, including the zeroed BSS the file need not carry. Taught in chapter 13. - in-kernel GIC
- Hypervisor.framework's GICv3, emulated inside the macOS kernel: guest accesses to it, the timer's interrupts and WFI never exit to the VMM, which only raises and lowers SPI lines. Taught in chapter 12.
- indirect descriptor
- A descriptor whose buffer is itself a table of descriptors, so one ring slot can carry a long request. Taught in chapter 16.
- initramfs
- A cpio archive of files, such as
/init, that the kernel unpacks into memory and uses as its first file system, before it has a disk driver; the VMM places it in RAM and names its range in/chosen. Taught in chapter 13. - injection (of an exception)
- Our VMM doing by hand what the hardware would have done to deliver an exception to the guest. Taught in chapter 08.
- instruction abort
- The exception taken when the CPU cannot fetch the next instruction from its address. Taught in chapter 05.
- integer overflow
- A sum or product too large for its type; in wrapping arithmetic it silently becomes a small number, which is how
addr + lencan pass a bounds check it should fail. Taught in chapter 04. - interrupt controller
- The device between interrupt sources and CPUs: it collects every source's line, ranks them and delivers one interrupt at a time to a chosen CPU. Arm's is the GIC. Taught in chapter 11.
- interrupt line
- The object a device drives to say it wants attention: one method,
set_level, held high while the device's masked status is non-zero. Connected to nothing until chapter 12 wires it to the interrupt controller. Taught in chapter 09. - interrupt specifier
- The cells of a device tree
interruptsproperty; for a GICv3, three cells: the kind (0 SPI, 1 PPI), the number within that kind, and the trigger (4 is level-high). Taught in chapter 12. - interrupt storm
- An interrupt that is delivered again as soon as its handler ends, because its cause was never removed, so the CPU makes no other progress. Taught in chapter 11.
- interrupt-parent
- The device-tree property that names, by phandle, the interrupt controller a node's
interruptsrefer to; set once at the root, it applies to every node below. Taught in chapter 12. - INTID
- The number that names an interrupt line in Arm's interrupt controller: 0 to 15 SGIs, 16 to 31 PPIs, 32 to 1019 SPIs, 1023 for "nothing pending". Taught in chapter 12.
- invariant
- A property that must hold after every input, such as "every validated buffer lies in one RAM region"; the fuzzer's test oracle, which finds bugs that never panic. Taught in chapter 25.
- IOERR
- The virtio-blk status value 1: the device understood the request but could not or would not do it, such as a sector past the end of the disk. Taught in chapter 18.
- IPA (intermediate physical address)
- The address a guest believes is physical; stage 2 translates it to real host memory. Taught in chapter 05.
- IPA size
- The number of address bits a VM's stage-2 tables accept: with n bits the guest can reach IPAs from 0 up to, but not including, 2 to the power n; set with
hv_vm_config_set_ipa_size. Taught in chapter 05. - IPI (inter-processor interrupt)
- Linux's name for an interrupt one CPU sends another; on GICv3 it is an SGI. Taught in chapter 20.
- IRQ (interrupt request)
- The ordinary kind of interrupt on Arm; the CPU takes it through the IRQ entry of its vector table when the I bit of PSTATE is clear. Taught in chapter 11.
- IrqLine
- Our devices' one-method interface to an interrupt line,
set_level(high); the machine decides what the line is connected to (the GIC, nothing, or a test recorder). Taught in chapter 12. - ISS (instruction specific syndrome)
- The lower 25 bits of an ESR; their meaning depends on the EC. Taught in chapter 02.
- ISV (instruction syndrome valid)
- A bit that says whether the hardware described a faulting load or store for us (size, register, direction). Taught in chapter 07.
K
- KASLR (kernel address space layout randomisation)
- Placing the kernel's code at a random address on each boot so an attacker cannot predict it; on arm64 the seed can come from
/chosenin the device tree. Taught in chapter 14. - kernel command line
- The text a kernel reads at boot to set options such as
console=; our VMM passes it in the device tree's/chosennode. Taught in chapter 13. - kernel panic
- A kernel's last resort: it prints why it cannot continue and stops, by default spinning forever unless told to reboot (
panic=). Taught in chapter 14. - kernelcache
- The macOS kernel linked together with its drivers into one file that the boot loader loads. Taught in chapter 24.
- kick
- Forcing a running vCPU out of
hv_vcpu_runfrom another thread withhv_vcpus_exit; the run returns with the reasonCANCELED. A kick is sticky (one sent before the vCPU enters the guest is kept for its next run) and can be spurious (aCANCELEDexit with nothing left to do), so it means "look at what was posted", never "stop". Taught in chapter 20.
L
- latch
- A bit that remembers an event until someone clears it, so an edge is not lost while nobody listens; the PL011's
RISis one. Taught in chapter 11. - level-triggered
- An interrupt line that stays raised as long as its cause holds; it cannot be lost while masked, and it drops only when the cause is removed. Taught in chapter 11.
- linker script
- A file that tells the linker at which addresses to place each section of a program, such as
_startat0x4008_0000. Taught in the bare-metal-rust primer. - loader
- The code that copies a kernel and its companions into memory and starts it; in a VMM, the VMM itself. Taught in chapter 13.
- loader.efi
- FreeBSD's boot loader built as an EFI application: firmware starts it, it reads the kernel from FreeBSD's file system through the firmware's disk services, and hands the kernel the DTB from the configuration table. Taught in chapter 22.
- lock order
- One fixed order in which every thread takes the locks it needs; if all threads follow it, no two can wait for each other forever. Taught in chapter 20.
- LPI (locality-specific peripheral interrupt)
- A GICv3 interrupt, INTID 8192 and up, sent as a message written to memory instead of on a wire; used for message-signalled interrupts. Our board has none. Taught in chapter 12.
M
- MAC address (media access control address)
- The six-byte address of one network interface, such as
02:6d:76:00:00:01;ff:ff:ff:ff:ff:ffmeans every interface (broadcast). Taught in chapter 19. - machine identifier
- In VZ, an opaque value that gives one macOS VM its own identity; two VMs made from the same configuration each need their own. Taught in chapter 23.
- malicious guest
- The attacker a VMM is designed against: guest code that runs on every vCPU at once, rewrites its RAM while we read it and chooses every value it hands us, but cannot touch host memory directly. Taught in chapter 25.
- memory reservation map
- The part of a DTB after the header that lists RAM ranges the kernel must not use, as (address, size) pairs ending with (0, 0). Taught in chapter 10.
- MIDR (Main ID Register)
- The Arm register
MIDR_EL1that names a CPU's maker and model; under Hypervisor.framework the guest sees a value the hypervisor supplies,0x610f0000by default, not the chip's own. Taught in chapter 23. - minimisation
- Shrinking a failing input, by zeroing or deleting chunks while it still fails, until it is small enough for a person to see the cause. Taught in chapter 25.
- MMIO (memory-mapped I/O)
- Talking to a device by loading and storing at its addresses, where each access has side effects. Taught in chapter 05.
- MMIO bus
- The VMM's table from guest-physical address ranges to emulated devices: it decides which device answers an access, and refuses overlapping ranges. Taught in chapter 09.
- monitor
- Our name, from chapter 03 on, for the VMM program we write (
crates/, an ordinary macOS program), as opposed to the guest it runs. Taught in chapter 03. - mountroot prompt
- The
mountroot>prompt FreeBSD shows when it cannot find the device its root file system should be on. Taught in chapter 22. - MPIDR_EL1 (multiprocessor affinity register)
- A CPU's own identity number, which an OS uses to tell its CPUs apart; vCPU 0's is
0x8000_0000. Taught in chapter 06. - MSI (message-signalled interrupt)
- An interrupt a device raises by writing a value to an address instead of driving a line; our board reserves INTIDs 80 to 143 for them. Taught in chapter 12.
N
- NetBackend
- The trait between macvmm's virtio-net device and the host:
sendone frame,recvone frame, each with a short timeout. Taught in chapter 19. - NIC (network interface card)
- One network card of a machine, real or virtual; each has its own MAC address. In macvmm, one virtio-net device. Taught in chapter 19.
- no_std
- A Rust crate attribute meaning "no standard library": no heap, no files, no threads, only
core. Taught in the bare-metal-rust primer. - NOT_SUPPORTED
- The SMCCC and PSCI return value -1 (all ones in
x0): "no such function here". Taught in chapter 08. - notify coalescing
- Several doorbells that arrive while the worker is busy becoming one pass over the ring; safe because a doorbell carries no data, only "look now". Taught in chapter 17.
O
- observed, inferred, unknown
- The three columns every claim about an undocumented machine goes into: seen in your own run, derived from runs plus a named public source, or not shown by anyone. Taught in chapter 24.
- offload
- Work a guest hands to its network device through header fields, such as computing checksums or cutting a large packet into frames; faster, but more guest-written fields to check. Taught in chapter 19.
- ON_PENDING / ALREADY_ON
- The PSCI refusals -5 and -4 to a
CPU_ONfor a CPU that is already starting or already running. Taught in chapter 20. - Oops
- Linux's report of a fault inside the kernel itself (the registers, the faulting address, a call trace); the kernel may survive one, or panic after it. Taught in chapter 14.
- OS lock
- A debug bit an operating system sets while it saves or restores debug registers, so that an external debugger cannot interfere; written through
OSLAR_EL1, read back inOSLSR_EL1. It is set at cold reset and Linux clears it early in boot. Our VMM emulates it. Taught in chapter 08. - out-pointer
- A pointer a C function writes its result through, because its return value is already used for the error code. Taught in chapter 01.
- output filter
- The code that removes dangerous escape sequences from guest output before the bytes reach your terminal or a file. Taught in chapter 09.
P
- PAN (privileged access never)
- A PSTATE bit that stops EL1 code from touching EL0's memory by accident; exception entry to EL1 sets it unless
SCTLR_EL1.SPANis 1, so an injected exception must set it too. Taught in chapter 08. - paravirtual device
- A device designed for virtual machines, which guest and VMM drive through shared memory instead of trapping on every register; virtio is the standard one. Taught in chapter 00.
- paravirtualization
- Changing the guest so it asks the VMM directly instead of touching hardware. Taught in chapter 00.
- parked vCPU
- A vCPU whose CPU is off; its thread waits on a condition variable, outside
hv_vcpu_run, until its mailbox is filled or the VM stops. Taught in chapter 20. - PC-advance table
- The rule, per kind of VM exit, for whether the VMM moves the guest's PC past the instruction before running it again. Taught in chapter 07.
- PCIe (PCI Express)
- The bus ordinary computers use for expansion devices; the operating system finds each device by reading its vendor and device IDs. VZ puts its virtio devices on it; our VMM does not. Taught in chapter 23.
- pending interrupt
- One raised by its source but not yet taken by the CPU; it waits as state while the CPU has interrupts masked. Taught in chapter 11.
- phandle
- A number given to a device-tree node so that other nodes can refer to it, as the PL011's
clocksproperty refers to the fixed clock. Taught in chapter 10. - PL011
- Arm's PrimeCell UART, the serial port at
0x0900_0000on our machine and on QEMU'svirtmachine. Taught in chapter 09. - PL031
- Arm's PrimeCell real-time clock at
0x0901_0000; its data register gives seconds since 1 January 1970. Taught in chapter 09. - PMU (performance monitoring unit)
- The CPU's performance counters, controlled through registers such as
PMCR_EL0;ID_AA64DFR0_EL1.PMUVersays whether one exists. Taught in chapter 08. - policy table
- Our VMM's list of what to do with each system register that traps (emulate, read as zero, or inject UNDEF), with a reason per row. Taught in chapter 08.
- Popek and Goldberg's condition
- Trap-and-emulate works if every instruction that touches what the VMM must control traps when run unprivileged (Popek and Goldberg, 1974, Theorem 1). Taught in chapter 00.
- PPI (private peripheral interrupt)
- An interrupt that belongs to one CPU, such as its own timer; INTIDs 16 to 31, configured in that CPU's redistributor. Taught in chapter 12.
- preferred return address
- Where the PC goes after an exception: after a call that executed (
svc,hvc); at a fault, so it is retried; and at an instruction the level above intercepted before it executed, such as a trappedsmc. Taught in chapter 02. - priority mask
- The CPU interface's threshold (
ICC_PMR_EL1): only interrupts more urgent than it, that is with a lower priority number, reach the CPU;0xfflets every priority through. Taught in chapter 12. - private CPU mode
- A CPU setting, reported by an unmerged QEMU patch series as needed by recent macOS guests, that macvmm asks for and is refused with
HV_DENIED; that a restricted entitlement unlocks it is inferred, not shown. Taught in chapter 24. - privileged instruction
- One that traps when run in user mode and runs normally in kernel mode. Taught in chapter 00.
- probe
- To find hardware by asking for it, such as reading a bus's list of devices; Arm platform devices cannot be found that way, so they are described instead. Linux also says a driver "probes" a device when it attaches to a node it was told about; that is driver binding, not discovery. Taught in chapter 10.
- problem ledger
- The course's list of everything a guest kernel needs from a machine (a CPU, memory, devices, interrupts, time and more); each chapter closes one row. Taught in chapter 00.
- property-based test
- A test that checks a rule over many generated inputs, from a fixed seed so a failure can be replayed, instead of over a few written examples. Taught in chapter 13.
- PSCI (power state coordination interface)
- A standard set of calls a kernel uses to power off, reset or start CPUs. Taught in chapter 08.
- pvpanic
- A tiny device a guest writes to when it panics, so the host can tell a crash from a hang. Taught in chapter 24.
R
- RAII (resource acquisition is initialization)
- Tying a resource to a value, so creating the value acquires it and dropping the value releases it; our
Vmdestroys the VM inDrop. Taught in chapter 01. - RAZ/WI (read as zero, writes ignored)
- A register behaviour from the Arm manual: reads give 0, writes do nothing. Taught in the reading-arm-specs primer.
- RCU stall warning / soft lockup
- Linux's warnings (
rcu: INFO,soft lockup) that one CPU has made no progress for about 20 seconds; in a VM they usually mean the VMM starved or blocked that vCPU's thread. Taught in chapter 20. - redistributor
- The per-CPU GIC block that holds that CPU's private interrupts (SGIs and PPIs) and forwards interrupts to it; 128 KiB per vCPU here, named
GICR_*. Taught in chapter 12. - reference implementation
- The course's finished VMM, in this repository's
crates/. Every code block in a lesson is taken from it; your own code lives inlearner/. Taught in chapter 01. - reference machine
- A widely supported machine model whose behaviour helps settle whether our machine or a guest is wrong, beside the specification and the guest's source; ours is QEMU's
virt, whose memory map we copy. Taught in chapter 22. - reg
- The device-tree property that lists a device's address ranges as (address, size) pairs of cells. Taught in chapter 10.
- region table
- Our VMM's list of guest RAM regions, each checked for size, 16 KiB alignment, overflow and overlap; every access must lie inside one region. Taught in chapter 04.
- register dump
- A snapshot of a vCPU's registers printed when the guest stops for good, in the order a reader asks: where it was, what it computed, which exception it took first. Taught in chapter 06.
- register offset
- An addressing form (
ldr x0, [x1, x2, lsl #3]) that adds a second register, optionally shifted, to the base. Taught in chapter 21. - rendezvous
- A point where one thread waits until another reports that a step is done; our VMM spawns the next vCPU thread only after the previous one has created its vCPU, so vCPU i gets redistributor frame i. Taught in chapter 20.
- repr(C)
- A Rust attribute that lays a struct out exactly as C would (same order, same padding), so it can be shared with C code. Taught in chapter 01.
- RES0 / RES1 (reserved, zero / reserved, one)
- Arm's marks for register bits with no function that must read as 0 or as 1; bit 31 of
MPIDR_EL1is RES1. Taught in chapter 06. - reset state
- The register values a CPU has at power-on; not the same as a system reset the guest asks for through PSCI. Taught in chapter 06.
- restore image
- Apple's installation file for macOS, a file ending in
.ipsw; VZ installs a macOS guest from one. Taught in chapter 23. - ring dump
- Printing every running vCPU's exit ring on request, with
Ctrl-A tor SIGUSR1, while the guest keeps running. Taught in chapter 14. - RLIMIT_CORE
- The resource limit on the size of a core dump, the file a crashing process can leave with its whole memory; macvmm sets it to 0 so no file of guest RAM is ever written. Taught in chapter 25.
- routing
- The rule that decides which exception level takes an exception, and so whose vector table runs: the guest kernel at EL1, or the level above it. Taught in chapter 02.
- RTC (real-time clock)
- A device that knows the date and time, not only how much time has passed. Taught in chapter 09.
- run loop
- The VMM's loop around
hv_vcpu_run: run the vCPU, decode the exit, handle it, then resume or stop. Taught in chapter 03. - RX thread
- The host thread each macvmm network card gets for incoming frames (RX is receive, TX transmit); it waits on the host socket, never on the guest, and is the worker's companion. Taught in chapter 19.
S
- sandbox
- Rules the kernel enforces on a process, which the process cannot lift; macvmm applies one with
sandbox_initafter set-up, so a compromised VMM can open no file, start no program and reach no network except its configured peer. Taught in chapter 25. - SAS (syndrome access size)
- Two bits of a data-abort syndrome giving the access size as a power of two: 0 is 1 byte, 3 is 8 bytes. Taught in chapter 07.
- SCTLR_EL1 (system control register, EL1)
- The switches a kernel flips as it starts: M turns stage-1 translation on, C and I the caches, A alignment checking. Taught in chapter 06.
- SDK (software development kit)
- The headers and libraries Xcode installs for building macOS programs;
xcrun --show-sdk-pathprints where, and Hypervisor.framework's C headers live inside it. Taught in chapter 01. - secondary CPU
- A CPU other than the boot CPU; it stays off until the guest starts it with PSCI
CPU_ON. Taught in chapter 20. - seeded PRNG (seeded pseudo-random number generator)
- A small function that turns a starting number into a stream of numbers that look random and are identical on every run, so any fuzz input can be regenerated. Taught in chapter 25.
- sensitive instruction
- One that reads or changes machine state the VMM must control. Taught in chapter 00.
- SF (sixty-four-bit flag)
- A data-abort syndrome bit that says the register is a 64-bit
xregister, not a 32-bitwregister. Taught in chapter 07. - SGI (software-generated interrupt)
- An interrupt one CPU sends to another by writing a register; INTIDs 0 to 15, used by kernels to wake or signal other CPUs. Taught in chapter 12.
- sha256 pinning
- Recording a file's SHA-256 hash once, committing it, and refusing any later download whose hash differs. Taught in chapter 13.
- shadow page table
- A real page table the VMM keeps for a guest, mapping its addresses straight to host memory, kept in step by write-protecting the guest's own tables so its writes to them fault into the VMM; replaced by a second hardware translation stage. Taught in chapter 00.
- side-effecting read
- A register read that changes the device, such as a read of the PL011's data register, which removes the byte it returns. Taught in chapter 09.
- sink
- Where guest output goes: an output filter, then a destination (stdout, a file, or nothing), chosen with
--serial. Taught in chapter 09. - smc (secure monitor call)
- An instruction that calls the firmware at EL3. Apple's chips have no EL3; the level above intercepts every guest
smcbefore it executes, so it reaches our VMM as a VM exit with the saved PC still pointing at thesmc. Taught in chapter 02. - SMCCC (SMC calling convention)
- Arm's rules for calls to higher levels: the function number in
x0, arguments inx1onwards, results back inx0. Taught in the smccc primer. - SMP (symmetric multiprocessing)
- A machine with several CPUs that share one memory and can each run any work; for us, a guest with more than one vCPU. Taught in chapter 20.
- SPI (shared peripheral interrupt)
- An interrupt from a device that any CPU could take; INTIDs 32 to 1019, configured in the distributor. Device tree SPI n is INTID 32 + n. Taught in chapter 12.
- spin lock
- A lock that a waiting core polls in a loop instead of sleeping; Arm cores often pause in
WFEbetween polls. Taught in chapter 11. - SPSel (stack pointer select)
- Bit 0 of PSTATE's mode field: 0 means code at EL1 uses
SP_EL0(EL1t), 1 means it uses its ownSP_EL1(EL1h). Taught in chapter 06. - SPSR (saved program status register)
- The mode and flags to restore when returning from an exception. Taught in chapter 02.
- spurious interrupt
- What the IAR reports (INTID 1023) when the CPU asks for an interrupt and none is pending any more; the handler returns without an EOI. Taught in chapter 12.
- SRT (syndrome register transfer)
- Five bits of a data-abort syndrome naming the register loaded or stored; 31 means
xzr, neversp. Taught in chapter 07. - SSE (syndrome sign extend)
- A data-abort syndrome bit that says a load must be sign-extended into its register. Taught in chapter 07.
- stage 1, stage 2
- The guest's own page tables (virtual to IPA), then HVF's tables (IPA to host memory). Taught in chapter 05.
- stage-1 walk
- Reading the guest's own page tables in software to turn a guest virtual address into an IPA, as the guest's MMU would. Taught in chapter 21.
- stage-2 hole
- A guest-physical range we deliberately leave unmapped, so every access becomes a VM exit we can answer as a device. Taught in chapter 05.
- start gate
- The barrier that keeps vCPU 0 out of the guest until every vCPU has been created. Taught in chapter 20.
- stop flag
- A shared boolean (an atomic) that any thread sets to ask the VM to stop; each vCPU thread checks it before entering the guest again. Taught in chapter 09.
- STRIDE
- A checklist of six threat kinds to walk each trust boundary through: Spoofing, Tampering, Repudiation, Information disclosure, Denial of service, Elevation of privilege. Taught in chapter 25.
- strings block
- The part of a DTB that holds every property name once; each property points into it by offset. Taught in chapter 10.
- structure block
- The part of a DTB that holds the tree itself, written depth first as tokens: begin node, property, end node, end. Taught in chapter 10.
- structure-aware mutation
- Changing an input the way an attacker would, knowing its layout (a
nextpointing backwards, a length ending in the next region), instead of flipping random bits. Taught in chapter 25. - svc (supervisor call)
- The instruction an app uses to ask its kernel for a service: Arm's system call. Taught in the os-basics primer.
- synchronous / asynchronous exception
- Caused by the instruction being run (a call, a fault) / caused by something outside it (a timer, an interrupt). Taught in chapter 02.
- synchronous external abort
- A data abort that tells the guest the memory system refused an access (fault status code
0x10); our VMM injects one for any access it will not emulate. Taught in chapter 21. - syndrome
- The note the hardware writes about an exception: the ESR and, for faults, the addresses. Taught in chapter 02.
- sysreg (system register)
- A CPU control or ID register read with
mrsand written withmsr, named likeSCTLR_EL1. Taught in the aarch64-reading primer. - system reset
- A restart of the whole machine that the guest asks for with PSCI
SYSTEM_RESET; not the reset state of one CPU. Taught in chapter 08.
T
- terminal injection
- Guest output that makes your terminal act instead of display, such as retitling the window, writing your clipboard or typing a reply into whatever reads its input; the output filter stops it. Taught in chapter 25.
- test device
- A device with 512 scratch registers at
0x0b00_0000(--testdev) that returns what was last written, so any surprise is the decoder's fault. Taught in chapter 07. - text_offset
- The Image header field at offset
0x8: how far above a 2 MiB-aligned base the kernel's first byte must sit; 0 for modern kernels. Taught in chapter 13. - thread
- An independent flow of execution in a process, with its own registers. HVF ties each vCPU to the thread that created it. Taught in the host-concurrency primer.
- threat model
- A written list of what you protect (assets), where untrusted data crosses into trusted code (trust boundaries), and what each attacker can do; the security work is then checked against it. Taught in chapter 25.
- TOCTOU (time of check to time of use)
- A bug where a value is checked, then read again to be used, and someone changed it in between. Taught in chapter 16.
- trace category
- A filter on the exit trace (
mmio,hvc,sysreg,psci,cancelorall) that keeps only the exits of that kind. Taught in chapter 14. - translation fault
- The fault a translation table walk raises when it finds no valid entry, or when the address is outside the range the tables cover; its DFSC also says at which level the walk stopped. Taught in chapter 05.
- trap
- The hardware stopping an instruction and handing control to a more privileged level. Taught in chapter 00.
- trap-and-emulate
- Run the guest unprivileged; when it does something privileged, it traps; the VMM emulates the effect and resumes it. Taught in chapter 00.
- trap-control register
- A register at EL2, such as
HCR_EL2orMDCR_EL2, whose bits decide which guest actions trap; HVF owns them, so what traps is measured. Taught in chapter 08. - TRM (technical reference manual)
- Arm's datasheet for one device, such as ARM DDI 0183 for the PL011. Taught in chapter 09.
- trust boundary
- A place where data passes from someone you trust less to someone you trust more, such as guest RAM read by the VMM; every value crossing it is checked. Taught in chapter 25.
- two supervisors
- On a Mac, the macOS kernel's EL2 part decides what leaves the guest, and our VMM, an ordinary process, decides what to do with what it is handed. Taught in chapter 01.
- type 1 / type 2 hypervisor
- An old classification: type 1 runs on the bare machine, type 2 as a program on another operating system. Modern systems blur it; this course asks instead who owns the most privileged level. Taught in chapter 01.
U
- UART (universal asynchronous receiver-transmitter)
- The simplest serial port: write a byte to send it, read to receive. Ours is the PL011. Taught in chapter 09.
- UFS (Unix File System)
- FreeBSD's traditional file system; the FreeBSD image keeps its root on a UFS partition. Taught in chapter 22.
- UNDEF / UNDEFINED
- The exception real hardware raises for an instruction or register it does not have. Taught in chapter 08.
- unhandled-MMIO policy
- What our VMM does when the guest touches an address no RAM and no device claims: stop the VM (
fatal, exit code 3) or read as zero and ignore writes (log). Taught in chapter 05. - unit address
- The part of a node name after the
@, which must equal the first address in itsreg. Taught in chapter 10. - unixgram backend
- macvmm's
--net unixgram:LOCAL,peer=REMOTE: one Unix datagram socket per network card, one datagram per frame, accepting datagrams only from the peer's path; it needs no entitlement. The opt-inunixgram:LOCAL,learninstead locks onto the first sender with an absolute path, a weaker rule thanpeer=. Taught in chapter 19. - unknown-MMIO logger
- The vmapple board's answer to an access no device claims: read as zero, ignore the write, record one line, and stop after 256 entries. Taught in chapter 24.
- unsafe Rust
- Five extra operations (such as calling C or dereferencing a raw pointer) that the compiler cannot check; it does not switch the other checks off, and the invariants become yours. Taught in chapter 01.
- unscaled offset
- An addressing form (
ldur x0, [x1, #-3]) whose signed 9-bit offset counts bytes, not multiples of the access size. Taught in chapter 21. - UNSUPP
- The virtio-blk status value 2: the device does not implement this request type. Taught in chapter 18.
- used ring
- The ring only the device writes: for each finished request, its head and how many bytes the device wrote (
len), andused.idx, how many requests it has finished so far. Taught in chapter 16. - used-buffer notification
- The interrupt a virtio device raises after it has put finished requests in a used ring; bit 0 of
InterruptStatus. Taught in chapter 15.
V
- ValidatedChain
- What macvmm's chain walker hands a device: one request's buffers, already copied, checked and split into readable and writable, so no device ever parses a ring. Taught in chapter 16.
- VBAR (vector base address register)
- Holds the address of an exception vector table. Taught in chapter 02.
- vCPU (virtual CPU)
- One guest CPU; HVF runs it on a host thread when we call
hv_vcpu_run. Taught in chapter 02. - vector offset
- The distance from
VBAR_EL1to the handler entry the CPU jumps to, chosen by where the exception came from and by its kind (synchronous, IRQ, FIQ or SError). Taught in chapter 08. - virtio
- A standard for paravirtual devices: the guest and the VMM share rings in memory instead of trapping on every register. Taught in chapter 15.
- virtio slot
- One of 32 reserved MMIO windows of
0x200bytes from0x0a00_0000, each for one paravirtual (virtio) device; slot i uses INTID 48 + i. Taught in chapter 05. - VIRTIO_BLK_F_SIZE_MAX
- The virtio-blk feature bit (bit 1) that promises every data segment of a request (one data buffer, one descriptor) is at most
size_maxbytes; a driver that cannot keep that promise may refuse the device. Taught in chapter 22. - virtio_net_hdr
- The 12-byte header in front of every frame in a virtio-net buffer; with no offloads, the driver sends
flagsandgso_typeas 0 and the device writesnum_buffers = 1on receive. Taught in chapter 19. - virtio-blk
- The virtio block device (device ID 2): a disk the guest drives through one queue, with requests that read, write, flush or identify it. Taught in chapter 18.
- virtio-blk request
- One descriptor chain holding a 16-byte header (the type and a sector number), the data buffers, and a one-byte status the device writes last. Taught in chapter 18.
- virtio-console
- The virtio console device (device ID 3): a receive queue the device fills and a transmit queue it reads, for one byte stream in each direction. Taught in chapter 17.
- virtio-mmio
- The virtio transport in which each device is a 0x200-byte MMIO register window, found through the device tree. Taught in chapter 15.
- virtio-net
- The virtio network card (device ID 1): a receive queue of guest-posted buffers the device fills with incoming frames, and a transmit queue of frames the device reads and sends. Taught in chapter 19.
- virtio-rng
- The virtio entropy device (device ID 4): one queue of device-writable buffers that the device fills with random bytes. Linux shows it as
/dev/hwrng. Taught in chapter 17. - virtqueue
- A queue of buffers that a virtio driver and device share in guest RAM; the split layout used here has three parts: a descriptor table, an available ring and a used ring. Taught in chapter 16.
- VM (virtual machine)
- The illusion of a whole computer, made for a guest. Taught in chapter 00.
- VM exit
- The moment the guest stops and our VMM runs, because the guest did something HVF forwards to us. Not an exit code. Taught in chapter 02.
- vmapple
- The board, first built in QEMU, whose memory map and devices match what Apple's macOS boot ROM expects; in macvmm, a second machine behind the
experimental-vmapplefeature. Taught in chapter 24. - VMM (virtual machine monitor)
- The program that builds and runs the virtual machine around a guest; ours is
macvmm. Taught in chapter 00. - volatile access
- A memory access the compiler must perform exactly as written; it gives no atomicity and no ordering with other threads. Taught in chapter 04.
- vtimer
- Hypervisor.framework's name for a guest's virtual timer; with no interrupt controller its firing reaches the VMM as a
VTIMER_ACTIVATEDexit. Taught in chapter 11. - vtimer mask
- Hypervisor.framework's own mask on the vtimer, set by the framework at each
VTIMER_ACTIVATEDexit and cleared only by the VMM (hv_vcpu_set_vtimer_mask); not the guest'sIMASK. Taught in chapter 11. - VZ (Virtualization.framework)
- Apple's ready-made virtual machine, configured rather than built; used in chapter 23. Taught in chapter 01.
W
- watcher
- A hook a machine profile may install in macvmm's run loop, called before each exit is handled and for each access no device claims, so the board can log, answer or stop before the generic policy decides;
virtinstalls none, vmapple installs one. Taught in chapter 24. - Weak (weak reference)
- A Rust
Arcthat does not keep its value alive;upgrade()givesNoneonce the last strongArcis gone. Used to break reference cycles. Taught in chapter 09. - WFE (wait for event)
- An instruction that idles a CPU until an event from another CPU or an interrupt; used inside spin locks. Taught in chapter 11.
- WFI (wait for interrupt)
- An instruction that idles a CPU until an interrupt or another wake-up arrives; it may also end early, so code re-checks its condition after it. Taught in chapter 11.
- WnR (write not read)
- A data-abort syndrome bit that is 1 for a store and 0 for a load. Taught in chapter 07.
- world switch
- The round trip of one VM exit: the CPU leaves the guest, the hypervisor saves the guest's state and runs the VMM, then restores the guest and enters it again. Taught in chapter 03.
- write-back
- A cache mode in which a completed write may still sit in a volatile cache; the writer must ask for a flush to make it durable. Taught in chapter 18.
- write-through
- A cache mode in which every write is durable before it is reported complete. Taught in chapter 18.
- writeback (of a base register)
- A load or store form that also updates its address register, before the access (pre-index,
[x0, #8]!) or after it (post-index,[x0], #8). Taught in chapter 21.
X
- XNU
- The name of the macOS kernel. Part of it runs at EL2 and supervises our guests. Taught in chapter 01.
- XPC service
- A helper program macOS starts on an app's behalf and talks to by messages; VZ runs each virtual machine inside one, not inside the app that configured it. Taught in chapter 23.
- xz
- A compression format and the program that unpacks it; FreeBSD ships its disk images as
.raw.xz. Taught in chapter 22.