WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

Re: [Xen-ia64-devel] PATCH: define guest_mode (instead of user_mode)

To: Alex Williamson <alex.williamson@xxxxxx>
Subject: Re: [Xen-ia64-devel] PATCH: define guest_mode (instead of user_mode)
From: Tristan Gingold <tgingold@xxxxxxx>
Date: Wed, 9 May 2007 05:33:31 +0200
Cc: Xen-ia64-devel <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Tue, 08 May 2007 20:26:54 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <1178643462.6146.1.camel@bling>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20070508132606.GA16081@saphi> <1178643462.6146.1.camel@bling>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.9i
On Tue, May 08, 2007 at 10:57:42AM -0600, Alex Williamson wrote:
> On Tue, 2007-05-08 at 15:26 +0200, Tristan Gingold wrote:
> > diff -r 8519e5db6510 -r 8e5083feaa52 xen/arch/ia64/vmx/vmx_process.c
> > --- a/xen/arch/ia64/vmx/vmx_process.c   Tue May 08 15:07:51 2007 +0200
> > +++ b/xen/arch/ia64/vmx/vmx_process.c   Tue May 08 15:24:57 2007 +0200
> > @@ -164,7 +164,7 @@ vmx_ia64_handle_break (unsigned long ifa
> >          if (iim == 0) 
> >              vmx_die_if_kernel("Break 0 in Hypervisor.", regs, iim);
> >  
> > -        if (!user_mode(regs)) {
> > +        if (ia64_psr(regs)->cpl == 0) {
> 
> Why is this first one a special case?  ie. why not !guest_mode(regs)
> same as the next one?  Thanks,
This is VTi code.  In my opinion, guest_mode makes sense only in PV mode.
Here we are testing wether kernel code is executing and not wether guest is.

Tristan.

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel

<Prev in Thread] Current Thread [Next in Thread>