From: Aashish Mittal <aashish.mittal4u@gmail.com>
To: kvm-ppc@vger.kernel.org
Subject: Emulating LWZU Instruction for e500 powerpc
Date: Fri, 19 Aug 2011 11:45:43 +0000 [thread overview]
Message-ID: <loom.20110819T134401-946@post.gmane.org> (raw)
Hi
I'm trying to emulate the lwzu instruction in e500 powerpc kvm for my project .
I've removed the read and write privileges from the tlb entries of guest's
certain pages . So when i'm trying to emulate lwzu instruction i'm getting a
kernel panic while mounting the guest filesystem while booting .
attempt to access beyond end of device
ram0: rw=0, wantu703268, limit&2144
To make sure that the emulation is faulty what i'm trying to do now is at the
time of DATA STORAGE exit on a marked page by an lwzu instruction i'm patching
the next instruction with an instruction which will raise an INTERRUPT PROGRAM
EXCEPTION and will get trapped in kvm and then i'm reverting the old read and
write privileges of this page and resuming the guest so that this LWZU
instruction can run natively . I'm expecting the immediate next instruction to
raise the INTERRUPT PROGRAM EXCEPTION but all i'm getting are DATA STORAGE Exits
at other pages marked by me and DTLB and ITLB misses on other addresses .
I've made sure to flush the icache after i patch using the instruction
flush_icache_range .
Error Log :
Emulating a lwzu instruction on pc 0xc00161ac && eaddr 0xc05742f0
Original Instruction is 0x90e60004 at pc: 0xc00161b0
Modified Instruction is 0x7ce000a6 at pc: 0xc00161b0
Exit : Interrupt DATA STORAGE at pc 0xc000f210 on eaddr:0xc000f228 instruction:
0x8085001c
Why i'm not getting any INTERRUPT PROGRAM EXCEPTION immediately in the next
instruction ?
--
Thanks and regards
Aashish Mittal
next reply other threads:[~2011-08-19 11:45 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-19 11:45 Aashish Mittal [this message]
2011-08-24 22:34 ` Emulating LWZU Instruction for e500 powerpc Alexander Graf
2011-08-24 22:34 ` Alexander Graf
[not found] ` <CAAonZCFpf9Nv1deAafSagDPjRoLWa3haAuH4Puz1Dksmnd62ng@mail.gmail.com>
2011-08-25 14:44 ` Alexander Graf
2011-08-25 14:44 ` Alexander Graf
2011-08-25 9:31 ` Aashish Mittal
2011-08-25 16:44 ` Scott Wood
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=loom.20110819T134401-946@post.gmane.org \
--to=aashish.mittal4u@gmail.com \
--cc=kvm-ppc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.