All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <srostedt@redhat.com>
To: Keir Fraser <keir@xensource.com>
Cc: "Yu, Wilfred" <wilfred.yu@intel.com>,
	"Xin, Xiaohui" <xiaohui.xin@intel.com>,
	xen-devel@lists.xensource.com, "Li, Susie" <susie.li@intel.com>,
	"Jiang, Yunhong" <yunhong.jiang@intel.com>,
	"Li, Xin B" <xin.b.li@intel.com>,
	Herbert Xu <herbert.xu@redhat.com>
Subject: Re: [Patch] Fix for x86_64 boot failures due	tobadsegment setup for protected mode.
Date: Fri, 10 Nov 2006 17:32:59 -0500	[thread overview]
Message-ID: <4554FE1B.8080408@redhat.com> (raw)
In-Reply-To: <C17A6693.458D%keir@xensource.com>

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

Keir Fraser wrote:
> I have a patch I'll check in. It'd be good get some testing of it.
> 
> Changeset is 12365:ca75b51d69c7
> 
>  -- Keir
> 

Keir,

I was playing with Plan9 which happens to also tinker with ss, fs, and
gs in this critical section. It still crashes pretty early, but it
crashes earlier without this patch.  This patch lets Plan9 crash at the
same location before the original patch Stephen Tweedie sent :}.

This patch makes the mov_to_seg more complete. I left out cs, since I
don't think that would even make sense with a mov.

-- Steve

Signed-off-by: Steven Rostedt <srostedt@redhat.com>



[-- Attachment #2: xen-vmxassist-more-segs.patch --]
[-- Type: text/x-patch, Size: 1075 bytes --]

diff -r ca75b51d69c7 tools/firmware/vmxassist/vm86.c
--- a/tools/firmware/vmxassist/vm86.c	Fri Nov 10 17:21:54 2006 +0000
+++ b/tools/firmware/vmxassist/vm86.c	Fri Nov 10 17:28:02 2006 -0500
@@ -829,15 +829,33 @@ mov_to_seg(struct regs *regs, unsigned p
 		goto fail;
 
 	switch ((modrm & 0x38) >> 3) {
+	case 0: /* es */
+		regs->ves = getreg16(regs, modrm);
+		saved_rm_regs.ves = 0;
+		oldctx.es_sel = regs->ves;
+		return 1;
+
+	/* case 1: cs */
+
+	case 2: /* ss */
+		regs->uss = getreg16(regs, modrm);
+		saved_rm_regs.uss = 0;
+		oldctx.ss_sel = regs->uss;
+		return 1;
 	case 3: /* ds */
 		regs->vds = getreg16(regs, modrm);
 		saved_rm_regs.vds = 0;
 		oldctx.ds_sel = regs->vds;
 		return 1;
-	case 0: /* es */
-		regs->ves = getreg16(regs, modrm);
-		saved_rm_regs.ves = 0;
-		oldctx.es_sel = regs->ves;
+	case 4: /* fs */
+		regs->vfs = getreg16(regs, modrm);
+		saved_rm_regs.vfs = 0;
+		oldctx.fs_sel = regs->vfs;
+		return 1;
+	case 5: /* gs */
+		regs->vgs = getreg16(regs, modrm);
+		saved_rm_regs.vgs = 0;
+		oldctx.gs_sel = regs->vgs;
 		return 1;
 	}
 

[-- 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:[~2006-11-10 22:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-10 17:04 [Patch] Fix for x86_64 boot failures due tobadsegment setup for protected mode Jiang, Yunhong
2006-11-10 17:25 ` Keir Fraser
2006-11-10 22:32   ` Steven Rostedt [this message]
2006-11-11  0:09     ` 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=4554FE1B.8080408@redhat.com \
    --to=srostedt@redhat.com \
    --cc=herbert.xu@redhat.com \
    --cc=keir@xensource.com \
    --cc=susie.li@intel.com \
    --cc=wilfred.yu@intel.com \
    --cc=xen-devel@lists.xensource.com \
    --cc=xiaohui.xin@intel.com \
    --cc=xin.b.li@intel.com \
    --cc=yunhong.jiang@intel.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.