From owner-svn-src-all@FreeBSD.ORG Wed May 20 22:30:58 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 652E6106564A; Wed, 20 May 2009 22:30:58 +0000 (UTC) (envelope-from kmacy@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 39CC88FC14; Wed, 20 May 2009 22:30:58 +0000 (UTC) (envelope-from kmacy@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n4KMUwlo046347; Wed, 20 May 2009 22:30:58 GMT (envelope-from kmacy@svn.freebsd.org) Received: (from kmacy@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n4KMUwhg046344; Wed, 20 May 2009 22:30:58 GMT (envelope-from kmacy@svn.freebsd.org) Message-Id: <200905202230.n4KMUwhg046344@svn.freebsd.org> From: Kip Macy Date: Wed, 20 May 2009 22:30:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r192493 - stable/7/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 May 2009 22:30:59 -0000 Author: kmacy Date: Wed May 20 22:30:57 2009 New Revision: 192493 URL: http://svn.freebsd.org/changeset/base/192493 Log: td_osd is at the end of struct thread to avoid breaking the ABI as a side effect it is outside of the td_startzero-td_endzero range, requiring it to be separately zeroed Modified: stable/7/sys/kern/kern_fork.c stable/7/sys/kern/kern_kse.c stable/7/sys/kern/kern_thr.c Modified: stable/7/sys/kern/kern_fork.c ============================================================================== --- stable/7/sys/kern/kern_fork.c Wed May 20 22:28:55 2009 (r192492) +++ stable/7/sys/kern/kern_fork.c Wed May 20 22:30:57 2009 (r192493) @@ -507,6 +507,7 @@ again: bcopy(&td->td_startcopy, &td2->td_startcopy, __rangeof(struct thread, td_startcopy, td_endcopy)); + bzero(&td2->td_osd, sizeof(struct osd)); td2->td_sigstk = td->td_sigstk; td2->td_sigmask = td->td_sigmask; Modified: stable/7/sys/kern/kern_kse.c ============================================================================== --- stable/7/sys/kern/kern_kse.c Wed May 20 22:28:55 2009 (r192492) +++ stable/7/sys/kern/kern_kse.c Wed May 20 22:30:57 2009 (r192493) @@ -1014,6 +1014,7 @@ thread_alloc_spare(struct thread *td) td->td_standin = spare; bzero(&spare->td_startzero, __rangeof(struct thread, td_startzero, td_endzero)); + bzero(&spare->td_osd, sizeof(struct osd)); spare->td_proc = td->td_proc; spare->td_ucred = crhold(td->td_ucred); spare->td_flags = TDF_INMEM; Modified: stable/7/sys/kern/kern_thr.c ============================================================================== --- stable/7/sys/kern/kern_thr.c Wed May 20 22:28:55 2009 (r192492) +++ stable/7/sys/kern/kern_thr.c Wed May 20 22:30:57 2009 (r192493) @@ -199,6 +199,7 @@ create_thread(struct thread *td, mcontex __rangeof(struct thread, td_startzero, td_endzero)); bcopy(&td->td_startcopy, &newtd->td_startcopy, __rangeof(struct thread, td_startcopy, td_endcopy)); + bzero(&newtd->td_osd, sizeof(struct osd)); newtd->td_proc = td->td_proc; newtd->td_ucred = crhold(td->td_ucred);