Avi Kivity wrote: > On 12/22/2009 05:36 PM, Alexander Graf wrote: >> >>> Is there a way to trap this and fprintf something? >>> >> I don't think so. KVM will just trap on execution outside of RAM and >> either fail badly or throw something bad into the guest. MMIO access >> works by analyzing the instruction that accesses the MMIO address. That >> just doesn't work when we don't have an instruction to analyze. >> > > We could certainly extend emulate.c to fetch instruction bytes from > userspace. It uses ->read_std() now, so we'd need to switch to > ->read_emulated() and add appropriate buffering. I thought the policy on emulate.c was to not have a full instruction emulator but only emulate instructions that do PT modifications or MMIO access? Btw, we're in the same situation with PowerPC here. The instruction emulator is _really_ small. It only does a few MMU specific instructions, a couple of privileged ones and MMIO accessing ones. Alex -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html