public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: Bhushan Bharat-R65777 <R65777@freescale.com>
Cc: Alexander Graf <agraf@suse.de>,
	"kvm-ppc@vger.kernel.org" <kvm-ppc@vger.kernel.org>,
	"kvm@vger.kernel.org" <kvm@vger.kernel.org>,
	Wood Scott-B07421 <B07421@freescale.com>
Subject: Re: [PATCH 4/4 v2] KVM: PPC: Add userspace debug stub support
Date: Tue, 2 Apr 2013 13:00:01 -0500	[thread overview]
Message-ID: <1364925601.24520.9@snotra> (raw)
In-Reply-To: <6A3DF150A5B70D4F9B66A25E3F7C888D06FBBF38@039-SN2MPN1-013.039d.mgd.msft.net> (from R65777@freescale.com on Tue Apr  2 09:09:34 2013)

On 04/02/2013 09:09:34 AM, Bhushan Bharat-R65777 wrote:
> 
> 
> > -----Original Message-----
> > From: Alexander Graf [mailto:agraf@suse.de]
> > Sent: Tuesday, April 02, 2013 1:57 PM
> > To: Bhushan Bharat-R65777
> > Cc: kvm-ppc@vger.kernel.org; kvm@vger.kernel.org; Wood Scott-B07421
> > Subject: Re: [PATCH 4/4 v2] KVM: PPC: Add userspace debug stub  
> support
> >
> >
> > On 29.03.2013, at 07:04, Bhushan Bharat-R65777 wrote:
> >
> > >
> > >
> > >> -----Original Message-----
> > >> From: Alexander Graf [mailto:agraf@suse.de]
> > >> Sent: Thursday, March 28, 2013 10:06 PM
> > >> To: Bhushan Bharat-R65777
> > >> Cc: kvm-ppc@vger.kernel.org; kvm@vger.kernel.org; Wood  
> Scott-B07421;
> > >> Bhushan
> > >> Bharat-R65777
> > >> Subject: Re: [PATCH 4/4 v2] KVM: PPC: Add userspace debug stub
> > >> support
> > >>
> > >>
> > >> How does the normal debug register switching code work in Linux?
> > >> Can't we just reuse that? Or rely on it to restore working state  
> when
> > >> another process gets scheduled in?
> > >
> > > Good point, I can see debug registers loading in function  
> __switch_to()-
> > >switch_booke_debug_regs() in file arch/powerpc/kernel/process.c.
> > > So as long as assume that host will not use debug resources we  
> can rely on
> > this restore. But I am not sure that this is a fare assumption. As  
> Scott earlier
> > mentioned someone can use debug resource for kernel debugging also.
> >
> > Someone in the kernel can also use floating point registers. But  
> then it's his
> > responsibility to clean up the mess he leaves behind.
> 
> I am neither convinced by what you said and nor even have much reason  
> to oppose :)
> 
> Scott,
> 	I remember you mentioned that host can use debug resources, you  
> comment on this ?

I thought the conclusion we reached was that it was OK as long as KVM  
waits until it actually needs the debug resources to mess with the  
registers.

-Scott

  parent reply	other threads:[~2013-04-02 18:00 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-21  6:24 [PATCH 0/4 v2] KVM :PPC: Userspace Debug support Bharat Bhushan
2013-03-21  6:24 ` [PATCH 1/4 v2] Added ONE_REG interface for debug instruction Bharat Bhushan
2013-03-29  1:55   ` Alexander Graf
2013-03-21  6:24 ` [PATCH 2/4 v2] KVM: PPC: debug stub interface parameter defined Bharat Bhushan
2013-03-29  1:55   ` Alexander Graf
2013-03-29  3:08     ` Bhushan Bharat-R65777
2013-04-02  8:27       ` Alexander Graf
2013-03-21  6:25 ` [PATCH 3/4 v2] Rename EMULATE_DO_PAPR to EMULATE_EXIT_USER Bharat Bhushan
2013-03-28 14:05   ` Alexander Graf
2013-03-21  6:25 ` [PATCH 4/4 v2] KVM: PPC: Add userspace debug stub support Bharat Bhushan
2013-03-28 16:36   ` Alexander Graf
2013-03-29  6:04     ` Bhushan Bharat-R65777
2013-04-02  8:27       ` Alexander Graf
2013-04-02 14:09         ` Bhushan Bharat-R65777
2013-04-02 15:41           ` Alexander Graf
2013-04-03 17:14             ` Bhushan Bharat-R65777
2013-04-03 17:35               ` Alexander Graf
2013-04-03 17:47                 ` Bhushan Bharat-R65777
2013-04-03 17:56                   ` Alexander Graf
2013-04-03 18:00                     ` Bhushan Bharat-R65777
2013-04-02 18:00           ` Scott Wood [this message]
2013-04-03 10:03             ` Bhushan Bharat-R65777
2013-04-03 10:28               ` Alexander Graf
2013-04-03 13:50                 ` Bhushan Bharat-R65777
2013-04-03 14:09                   ` Alexander Graf
2013-04-03 15:18                     ` Bhushan Bharat-R65777
2013-04-03 16:26                       ` Alexander Graf

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=1364925601.24520.9@snotra \
    --to=scottwood@freescale.com \
    --cc=B07421@freescale.com \
    --cc=R65777@freescale.com \
    --cc=agraf@suse.de \
    --cc=kvm-ppc@vger.kernel.org \
    --cc=kvm@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox