Hi Christoffer, I ran the provided guest zImage-2.6.17 and again got to 0x1008C, so I can't say what's going on with any certainty. Some questions that may make sense of things... 1) What is the real instruction at 0x00010040? For me, it is 0x1a000001 (BNE PC+4). To figure out the real instruction, I trap at kvmarm_handle_exit, and on entry: p/x vcpu->arch.guest_regs this shows regs 0-15 followed by the "guestified" CPSR. Reg 15 shows (for an SWI) the next instruction (in this case it should show 0x00010044) For me, the emulation code takes the branch to 0x1004C, which I trapped on (same method you did), the trap did hit for me. I don't think this matters, but I set the trap while using the host page table, not the shadow page table. 2) Did you recompile QEMU to pick up the new setregs? 3) Are you running straight from the emulate branch? If not, did you merge from commit ffb9d4df3c91936da03406eb8d7a4dcca3a14744? 4) What other traps do you have set in the debug below? getOp is called twice for every SWI. First its called in kvmarm_handle_exit to figure out if the instruction should be emulated, then in kvmarm_emulate_trans_op when figuring out what instruction to emulate. kvmarm_translate_getOp is a very simple loop, I find it hard to believe you are stuck in there. Have you stepped through the loop? Does it return to the caller? If you want to discuss this, I'll be on skype for the rest of the night Hope this helps... Brian Christoffer Dall wrote: > Hi Brian. > > When we are running the guest boot code, we get as far as to the > instruction on 0x00010040. On this trap, it seems that the translation > code sits in an infinite loop. Would you mind looking at it? > > We have built our own linux arm image to ease debugging and > disassembly. You can find the binary in the svn repo in > bin/zImage-2.6.17. Please use this when testing so we don't have any > inconsistencies. > > Attached here is the debug output: > > ---- > Breakpoint 1, 0x00010040 in ?? () > 694 { > (gdb) x 0x10040 > 0x10040: 0xef000000 > (gdb) b *0x10044 > Breakpoint 2 at 0x10044 > (gdb) b *0x1004c > Breakpoint 3 at 0x1004c > (gdb) b *0x10064 > Breakpoint 4 at 0x10064 > (gdb) cont > Continuing. > > Program received signal SIGINT, Interrupt. > kvmarm_translate_getOp (instr=<value optimized out>) at > arch/arm/kvm/arm_translate.c:70 > 70 for(i=0; i<NUM_TRANS_INSTR; i++) { > (gdb) c > Continuing. > > Program received signal SIGINT, Interrupt. > kvmarm_translate_getOp (instr=<value optimized out>) at > arch/arm/kvm/arm_translate.c:70 > 70 for(i=0; i<NUM_TRANS_INSTR; i++) { > (gdb) c > Continuing. > --- > > Best, > Christoffer > ------------------------------------------------------------------------ > > _______________________________________________ > Android-virt mailing list > Android-virt at lists.cs.columbia.edu > https://lists.cs.columbia.edu/cucslists/listinfo/android-virt >