lkml.org 
[lkml]   [2013]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] x86: correctly initialize the CS base on reset
On Tue, Mar 19, 2013 at 05:41:45PM +0100, Jan Kiszka wrote:
> On 2013-03-19 16:43, Gleb Natapov wrote:
> > On Tue, Mar 19, 2013 at 04:30:26PM +0100, Paolo Bonzini wrote:
> >> The CS base was initialized to 0 on VMX (wrong, but usually overridden
> >> by userspace before starting) or 0xf0000 on SVM. The correct value is
> >> 0xffff0000, and VMX is able to emulate it now, so use it.
> >>
> >> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> > Reviewed-by: Gleb Natapov <gleb@redhat.com>
>
> Just for the history (as I was wondering where this came from): CS base
> used to be set to 0xf0000 on VMX as well, but that was changed by
> b246dd5d to only affect guests when unrestricted mode is missing. That
> change actually left the base uninitialized.
>
Looking at the code before b246dd5d it sets CS base to 0xf0000 only if it was
0xffff0000. This is the same as with current code: fix_rmode_seg() does
it.

--
Gleb.


\
 
 \ /
  Last update: 2013-03-19 18:41    [W:0.041 / U:1.484 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site