From owner-svn-src-head@FreeBSD.ORG Fri Feb 10 21:26:26 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 62C50106566B; Fri, 10 Feb 2012 21:26:26 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4D6288FC15; Fri, 10 Feb 2012 21:26:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q1ALQQYK095513; Fri, 10 Feb 2012 21:26:26 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q1ALQQvI095511; Fri, 10 Feb 2012 21:26:26 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201202102126.q1ALQQvI095511@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 10 Feb 2012 21:26:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r231441 - head/sys/amd64/amd64 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Feb 2012 21:26:26 -0000 Author: kib Date: Fri Feb 10 21:26:25 2012 New Revision: 231441 URL: http://svn.freebsd.org/changeset/base/231441 Log: In cpu_set_user_tls(), consistently set PCB_FULL_IRET pcb flag for both 64bit and 32bit binaries, not for 64bit only. The set of the flag is not neccessary there, because the only current user of the cpu_set_user_tls() is create_thread(), which calls cpu_set_upcall() before and cpu_set_upcall() itself sets PCB_FULL_IRET. Change the function for consistency and preserve existing KPI for now. MFC after: 1 week Modified: head/sys/amd64/amd64/vm_machdep.c Modified: head/sys/amd64/amd64/vm_machdep.c ============================================================================== --- head/sys/amd64/amd64/vm_machdep.c Fri Feb 10 21:07:52 2012 (r231440) +++ head/sys/amd64/amd64/vm_machdep.c Fri Feb 10 21:26:25 2012 (r231441) @@ -552,6 +552,7 @@ cpu_set_user_tls(struct thread *td, void return (EINVAL); pcb = td->td_pcb; + set_pcb_flags(pcb, PCB_FULL_IRET); #ifdef COMPAT_FREEBSD32 if (SV_PROC_FLAG(td->td_proc, SV_ILP32)) { pcb->pcb_gsbase = (register_t)tls_base; @@ -559,7 +560,6 @@ cpu_set_user_tls(struct thread *td, void } #endif pcb->pcb_fsbase = (register_t)tls_base; - set_pcb_flags(pcb, PCB_FULL_IRET); return (0); }