All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Guthro <bguthro@virtualiron.com>
To: xen-devel <xen-devel@lists.xensource.com>,
	Robert Phillips <rphillips@virtualiron.com>
Subject: [PATCH][SVM] CPL initialization fix
Date: Mon, 10 Mar 2008 15:14:48 -0400	[thread overview]
Message-ID: <47D588A8.9030908@virtualiron.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 253 bytes --]

CPL should be determined by code segment's DPL, not data segment's.

This solves a problem migrating a QEMU guest without PV-on-HVM drivers

Signed-off-by: Robert Plillips <rphillips@virtualiron.com>
Signed-off-by: Ben Guthro <bguthro@virtualoiron.com>

[-- Attachment #2: lm-svm-cpl.patch --]
[-- Type: text/x-patch, Size: 439 bytes --]

diff -r f76f151a7431 xen/arch/x86/hvm/svm/svm.c
--- a/xen/arch/x86/hvm/svm/svm.c
+++ b/xen/arch/x86/hvm/svm/svm.c
@@ -557,7 +557,7 @@ static void svm_set_segment_register(str
         break;
     case x86_seg_ss:
         memcpy(&vmcb->ss, reg, sizeof(*reg));
-        vmcb->cpl = vmcb->ss.attr.fields.dpl;
+        vmcb->cpl = vmcb->cs.attr.fields.dpl;
         break;
     case x86_seg_tr:
         memcpy(&vmcb->tr, reg, sizeof(*reg));

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

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

             reply	other threads:[~2008-03-10 19:14 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-10 19:14 Ben Guthro [this message]
2008-03-10 19:18 ` [PATCH][SVM] CPL initialization fix Keir Fraser
2008-03-10 19:26   ` Keir Fraser
2008-03-10 20:01     ` Robert Phillips
2008-03-10 21:57       ` Keir Fraser

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=47D588A8.9030908@virtualiron.com \
    --to=bguthro@virtualiron.com \
    --cc=rphillips@virtualiron.com \
    --cc=xen-devel@lists.xensource.com \
    /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.