From owner-p4-projects@FreeBSD.ORG Fri Dec 31 15:08:26 2004 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 04B7716A4D0; Fri, 31 Dec 2004 15:08:26 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CD3FF16A4CE for ; Fri, 31 Dec 2004 15:08:25 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B9F6843D1F for ; Fri, 31 Dec 2004 15:08:25 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id iBVF8PZE009728 for ; Fri, 31 Dec 2004 15:08:25 GMT (envelope-from davidxu@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id iBVF8P0L009725 for perforce@freebsd.org; Fri, 31 Dec 2004 15:08:25 GMT (envelope-from davidxu@freebsd.org) Date: Fri, 31 Dec 2004 15:08:25 GMT Message-Id: <200412311508.iBVF8P0L009725@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to davidxu@freebsd.org using -f From: David Xu To: Perforce Change Reviews Subject: PERFORCE change 67992 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 Dec 2004 15:08:26 -0000 http://perforce.freebsd.org/chv.cgi?CH=67992 Change 67992 by davidxu@davidxu_tiger on 2004/12/31 15:07:44 use THREAD_LIST_LOCK, THREAD_LIST_UNLOCK macro. Affected files ... .. //depot/projects/davidxu_thread/src/lib/libthread/thread/thr_stack.c#3 edit Differences ... ==== //depot/projects/davidxu_thread/src/lib/libthread/thread/thr_stack.c#3 (text+ko) ==== @@ -152,7 +152,7 @@ * Use the garbage collector lock for synchronization of the * spare stack lists and allocations from usrstack. */ - THR_LOCK_ACQUIRE(curthread, &_thread_list_lock); + THREAD_LIST_LOCK(curthread); /* * If the stack and guard sizes are default, try to allocate a stack * from the default-size stack cache: @@ -182,7 +182,7 @@ } if (attr->stackaddr_attr != NULL) { /* A cached stack was found. Release the lock. */ - THR_LOCK_RELEASE(curthread, &_thread_list_lock); + THREAD_LIST_UNLOCK(curthread); } else { /* Allocate a stack from usrstack. */ @@ -203,7 +203,7 @@ last_stack -= (stacksize + guardsize); /* Release the lock before mmap'ing it. */ - THR_LOCK_RELEASE(curthread, &_thread_list_lock); + THREAD_LIST_UNLOCK(curthread); /* Map the stack and guard page together, and split guard page from allocated space: */