Hi all. I finally got past my issues with interrupts injection and timer interrupts. Basically, I am letting QEMU emulate a timer, which works by way of a standard SIGALRM signal. When the emulated timer code wants to raise an interrupt it calls a handler in the emulated ARM PIC, which in turn calls cpu_interrupt. cpu_interrupt simply sets a flag, which would abort the main emulation loop when not using KVM, but I have amended the ARM PIC handler to call a new architecture-specific KVM hook: kvm_arch_interrupt. kvm_arch_interrupt(...) issues an IOCTL call to KVM, which sets a flag on the virtual CPU. This could all have been done by checking the CPU flags in kvm_arch_pre_run (which is invoked before each call to vcpu_run in KVM), but I liked this more asynchronous approach, as one might imagine a separate thread for the timer (perhaps one day running on its own ARM core) injecting interrupts in this way. This implementation has reminds me that there is some remaining work to ensure that we are using proper locking to concurrently accessed KVM data structures. Right now, it's not important as everything executes sequentially with hardly anything exported. Status-wise, the boot process now proceeds to check_bugs(), where the guest eventually crashes in remove_vm_area(). I will investigate this further tomorrow. Best, Christoffer -------------- next part -------------- An HTML attachment was scrubbed... URL: https://lists.cs.columbia.edu/pipermail/android-virt/attachments/20091207/41d0cd8a/attachment.html