Create a VM from a kernel assembled output. Loads the kernel ELF into RAM at `RAM_BASE`, then resets the CPU to `ROM_BASE` (0x0) so the ROM `_start` boot stub runs first. `_start` sets up PMP + delegation and `mret`s into S-mode at `RAM_BASE`.
(assembled: &AssembledOutput)
| 37 | impl VmSnapshot { |
| 38 | /// The architectural RAM image at capture time. |
| 39 | pub fn ram(&self) -> &[u8] { |
| 40 | &self.ram |
| 41 | } |
| 42 | |
| 43 | /// Framebuffer pixel planes at capture time (bulk, delta-compressed by the session). |
| 44 | pub fn fb_image(&self) -> Vec<u8> { |
| 45 | self.devices.fb_image() |
| 46 | } |
| 47 | |
| 48 | /// This snapshot with both bulk images dropped (RAM and framebuffer planes). |
| 49 | pub fn without_bulk(&self) -> Self { |
| 50 | Self { |
nothing calls this directly
no test coverage detected