From owner-svn-src-all@FreeBSD.ORG Sun Nov 16 15:45:42 2008 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 357EC1065674; Sun, 16 Nov 2008 15:45:42 +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 28A178FC1A; Sun, 16 Nov 2008 15:45:42 +0000 (UTC) (envelope-from kib@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 mAGFjfG4057852; Sun, 16 Nov 2008 15:45:41 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id mAGFjfkH057849; Sun, 16 Nov 2008 15:45:41 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <200811161545.mAGFjfkH057849@svn.freebsd.org> From: Konstantin Belousov Date: Sun, 16 Nov 2008 15:45:41 +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: r185002 - in head/sys: amd64/linux32 compat/linux i386/linux 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: Sun, 16 Nov 2008 15:45:42 -0000 Author: kib Date: Sun Nov 16 15:45:41 2008 New Revision: 185002 URL: http://svn.freebsd.org/changeset/base/185002 Log: In the robust futexes list head, futex_offset shall be signed, and glibc actually supplies negative offsets. Change l_ulong to l_long. Submitted by: dchagin Modified: head/sys/amd64/linux32/linux.h head/sys/compat/linux/linux_futex.c head/sys/i386/linux/linux.h Modified: head/sys/amd64/linux32/linux.h ============================================================================== --- head/sys/amd64/linux32/linux.h Sun Nov 16 14:55:58 2008 (r185001) +++ head/sys/amd64/linux32/linux.h Sun Nov 16 15:45:41 2008 (r185002) @@ -892,7 +892,7 @@ struct linux_robust_list { struct linux_robust_list_head { struct linux_robust_list list; - l_ulong futex_offset; + l_long futex_offset; l_uintptr_t pending_list; }; Modified: head/sys/compat/linux/linux_futex.c ============================================================================== --- head/sys/compat/linux/linux_futex.c Sun Nov 16 14:55:58 2008 (r185001) +++ head/sys/compat/linux/linux_futex.c Sun Nov 16 15:45:41 2008 (r185002) @@ -652,7 +652,7 @@ release_futexes(struct proc *p) struct linux_robust_list *entry, *next_entry, *pending; unsigned int limit = 2048, pi, next_pi, pip; struct linux_emuldata *em; - l_ulong futex_offset; + l_long futex_offset; int rc; em = em_find(p, EMUL_DONTLOCK); @@ -664,7 +664,7 @@ release_futexes(struct proc *p) if (fetch_robust_entry(&entry, PTRIN(&head->list.next), &pi)) return; - if (copyin(&head->futex_offset, &futex_offset, sizeof(l_ulong))) + if (copyin(&head->futex_offset, &futex_offset, sizeof(futex_offset))) return; if (fetch_robust_entry(&pending, PTRIN(&head->pending_list), &pip)) Modified: head/sys/i386/linux/linux.h ============================================================================== --- head/sys/i386/linux/linux.h Sun Nov 16 14:55:58 2008 (r185001) +++ head/sys/i386/linux/linux.h Sun Nov 16 15:45:41 2008 (r185002) @@ -862,7 +862,7 @@ struct linux_robust_list { struct linux_robust_list_head { struct linux_robust_list list; - l_ulong futex_offset; + l_long futex_offset; struct linux_robust_list *pending_list; };