From: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
To: Alexander Graf <agraf@suse.de>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: linuxppc-dev@lists.ozlabs.org, paulus@samba.org,
kvm-ppc@vger.kernel.org, kvm@vger.kernel.org
Subject: Re: [PATCH v3] powerpc/kvm: support to handle sw breakpoint
Date: Tue, 12 Aug 2014 10:47:55 +0530 [thread overview]
Message-ID: <53E9A383.5060009@linux.vnet.ibm.com> (raw)
In-Reply-To: <53E889BA.40108@suse.de>
On Monday 11 August 2014 02:45 PM, Alexander Graf wrote:
>
> On 11.08.14 10:51, Benjamin Herrenschmidt wrote:
>> On Mon, 2014-08-11 at 09:26 +0200, Alexander Graf wrote:
>>>> diff --git a/arch/powerpc/kvm/emulate.c b/arch/powerpc/kvm/emulate.c
>>>> index da86d9b..d95014e 100644
>>>> --- a/arch/powerpc/kvm/emulate.c
>>>> +++ b/arch/powerpc/kvm/emulate.c
>>> This should be book3s_emulate.c.
>> Any reason we can't make that 00dddd00 opcode as breakpoint common to
>> all powerpc variants ?
>
> I can't think of a good reason. We use a hypercall on booke (which traps
> into an illegal instruction for pr) today, but I don't think it has to
> be that way.
>
> Given that the user space API allows us to change it dynamically, there
> should be nothing blocking us from going with 00dddd00 always.
>
Kindly correct me if i am wrong. So we can still have a common code in
emulate.c to set the env for both HV and pr incase of illegal
instruction (i will rebase latest src). But suggestion here to use
00dddd00, in that case current path in embed is kvmppc_handle_exit
(booke.c) -> BOOKE_INTERRUPT_HV_PRIV -> emulation_exit ->
kvmppc_emulate_instruction, will change to kvmppc_handle_exit (booke.c)
-> BOOKE_INTERRUPT_PROGRAM -> if debug instr call emulation_exit else
send to guest?
Thanks for review
regards
Maddy
>
> Alex
>
next prev parent reply other threads:[~2014-08-12 5:18 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-01 4:50 [PATCH v3] powerpc/kvm: support to handle sw breakpoint Madhavan Srinivasan
2014-08-03 15:51 ` Segher Boessenkool
2014-08-11 3:59 ` Madhavan Srinivasan
2014-08-11 7:26 ` Alexander Graf
2014-08-11 8:51 ` Benjamin Herrenschmidt
2014-08-11 9:15 ` Alexander Graf
2014-08-12 5:17 ` Madhavan Srinivasan [this message]
2014-08-12 11:19 ` Alexander Graf
2014-08-12 11:35 ` Madhavan Srinivasan
2014-08-12 12:15 ` Alexander Graf
2014-08-12 12:21 ` Madhavan Srinivasan
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=53E9A383.5060009@linux.vnet.ibm.com \
--to=maddy@linux.vnet.ibm.com \
--cc=agraf@suse.de \
--cc=benh@kernel.crashing.org \
--cc=kvm-ppc@vger.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=paulus@samba.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).