Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 14 Jan 2011 21:09:01 +0000 (UTC)
From:      Jung-uk Kim <jkim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r217424 - in head/sys/amd64: ia32 linux32
Message-ID:  <201101142109.p0EL91fD001147@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jkim
Date: Fri Jan 14 21:09:01 2011
New Revision: 217424
URL: http://svn.freebsd.org/changeset/base/217424

Log:
  Remove redundant, bogus, and even harmful uses of setting TS bit in CR0.
  It is done from fpstate_drop() when it is really necessary.
  
  Reviewed by:	kib
  MFC after:	1 week

Modified:
  head/sys/amd64/ia32/ia32_signal.c
  head/sys/amd64/linux32/linux32_sysvec.c

Modified: head/sys/amd64/ia32/ia32_signal.c
==============================================================================
--- head/sys/amd64/ia32/ia32_signal.c	Fri Jan 14 20:43:24 2011	(r217423)
+++ head/sys/amd64/ia32/ia32_signal.c	Fri Jan 14 21:09:01 2011	(r217424)
@@ -741,7 +741,6 @@ ia32_setregs(struct thread *td, struct i
 	regs->tf_gs = _ugssel;
 	regs->tf_flags = TF_HASSEGS;
 
-	load_cr0(rcr0() | CR0_MP | CR0_TS);
 	fpstate_drop(td);
 
 	/* Return via doreti so that we can change to a different %cs */

Modified: head/sys/amd64/linux32/linux32_sysvec.c
==============================================================================
--- head/sys/amd64/linux32/linux32_sysvec.c	Fri Jan 14 20:43:24 2011	(r217423)
+++ head/sys/amd64/linux32/linux32_sysvec.c	Fri Jan 14 21:09:01 2011	(r217424)
@@ -865,7 +865,7 @@ exec_linux_setregs(struct thread *td, st
 	regs->tf_flags = TF_HASSEGS;
 	regs->tf_cs = _ucode32sel;
 	regs->tf_rbx = imgp->ps_strings;
-	load_cr0(rcr0() | CR0_MP | CR0_TS);
+
 	fpstate_drop(td);
 
 	/* Do full restore on return so that we can change to a different %cs */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201101142109.p0EL91fD001147>