Emulating lwz instruction powerpc e500

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

I'm trying to emulate the lwz instruction in powerpc e500 kvm for my project . 
And the instruction can modify any of the 32 gpr's . So i'm resuming the guest 
using RESUME_GUEST_NV Flag so that all the gpr's can be updated . But somehow 
the the guest OS doesn't boots after that. I took the vcpu dump before emulating 
the instruction and after emulating it . Also i took the vcpu dump without 
emulating the instruction just before and just after the emulation . And i'm 
surprised to see that while lwz should have changed only one gpr instrction 
which i'm doing and is getting correctly emulated but int he original dump there 
are more then 1 gpr is modified and this problem only arrives when i use 
RESUME_GUEST_NV but if i use RESUME_GUEST all other registers get modified 
correctly while the one which lwz should have modified if it belongs to gpr15-31 
then the change doesn't reflects there. I'm attaching the vcpu dump 

Inst=0x8249a0e0, opcode:32 xop:112
RT: 18 , RA: 9, D: 0xa0e0 Data (to be written in RT) 0x20000000
(VCPU Dump just before the instruction is executed)
pc:   c055f518 msr:  00021002
lr:   c055f710 ctr:  00000001
srr0: c0548560 srr1: 00021002
exceptions: 00000000
gpr00: 00000000 c05b3ee0 c05872e0 00000000
gpr04: 00000ae7 00000000 00000004 00000000
gpr08: 00000000 c05c0000 0000005b c0a0073b
gpr12: 88000082 00000000 00000000 00000000
gpr16: 00000000 00000000 00000000 00000000
gpr20: 00000000 00000000 00000000 00000000
gpr24: 00000000 00000000 00001620 00000000
gpr28: c05c0000 00000adf c05c0000 c05b3f68

(VCPU DUMP just at the next instruction if i don't emulate the instruction )
pc:   c055f51c msr:  00021002
lr:   c055f710 ctr:  00000001
srr0: c0548560 srr1: 00021002
exceptions: 00000000
gpr00: 00000000 c05b3ee0 c05872e0 00000000
gpr04: 00000ae7 00000000 00000004 00000000
gpr08: 00000000 c05c0000 0000005b c0a0073b
gpr12: 88000082 00000000 00000000 00000000
gpr16: 00000000 00000000 20000000 00000000
gpr20: 00000000 00000000 00000000 00000000
gpr24: ffffffff fffffffc 00001620 00000000
gpr28: 00000000 00000ae4 00000000 00000000


(VCPU DUMP if i emulate the instruction manually and resume the guest using   
RESUME_GUEST_NV flag)

pc:   c055f51c msr:  00021002
lr:   c055f710 ctr:  00000001
srr0: c0548560 srr1: 00021002
exceptions: 00000000
gpr00: 00000000 c05b3ee0 c05872e0 00000000
gpr04: 00000ae7 00000000 00000004 00000000
gpr08: 00000000 c05c0000 0000005b c0a0073b
gpr12: 88000082 00000000 00000000 00000000
gpr16: 00000000 00000000 20000000 00000000
gpr20: 00000000 00000000 00000000 00000000
gpr24: 00000000 00000000 00001620 00000000
gpr28: c05c0000 00000adf c05c0000 c05b3f68

Thanks in advance . 



--
To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM Development]     [KVM ARM]     [KVM ia64]     [Linux Virtualization]     [Linux USB Devel]     [Linux Video]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux