This isn't enough to set the video mode yet but it gets us further. I
think allocate_memory/map_buf/powerOnDART need real implementations,
otherwise setting a video mode crashes the DCP in an APIODMA interrupt
handler, whatever that is.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
This accounts for most of the DCP traffic once macOS is booted. I used
a sophisticated side-channel hypervisor timing attack to determine the
message functions [ adding time.sleep(1) ]
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Now keeps track of the requested MMIO maps in a DictRangeMap, which is
then flattened to HV page table updates.
TODO: HOOK/SYNC codepaths
Signed-off-by: Hector Martin <marcan@marcan.st>
The hanlder omits noise/useless of the mmio access and annotates
known offsets, pins, interrupts and config values.
Signed-off-by: Janne Grunau <j@jannau.net>
-m <script>
Run a script in hypervisor context prior to starting the guest.
This is essentially the same as the shell context.
-c <code>
Run a literal string of code prior to starting the guest.
-S
Start a shell instead of directly starting the guest. Use `start` to
actually begin guest execution.
This also adds a couple example scripts under hv/.
Signed-off-by: Hector Martin <marcan@marcan.st>