From owner-cvs-src@FreeBSD.ORG Thu Jan 8 07:37:13 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BA42C16A4CE; Thu, 8 Jan 2004 07:37:13 -0800 (PST) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3D0F543D39; Thu, 8 Jan 2004 07:37:10 -0800 (PST) (envelope-from deischen@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.10/8.12.10) with ESMTP id i08Fb90B030255; Thu, 8 Jan 2004 07:37:09 -0800 (PST) (envelope-from deischen@repoman.freebsd.org) Received: (from deischen@localhost) by repoman.freebsd.org (8.12.10/8.12.10/Submit) id i08Fb9rW030254; Thu, 8 Jan 2004 07:37:09 -0800 (PST) (envelope-from deischen) Message-Id: <200401081537.i08Fb9rW030254@repoman.freebsd.org> From: Daniel Eischen Date: Thu, 8 Jan 2004 07:37:09 -0800 (PST) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/lib/libpthread/thread thr_create.c thr_private.h thr_rwlock.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 15:37:13 -0000 deischen 2004/01/08 07:37:09 PST FreeBSD src repository Modified files: lib/libpthread/thread thr_create.c thr_private.h thr_rwlock.c Log: Add a simple work-around for deadlocking on recursive read locks on a rwlock while there are writers waiting. We normally favor writers but when a reader already has at least one other read lock, we favor the reader. We don't track all the rwlocks owned by a thread, nor all the threads that own a rwlock -- we just keep a count of all the read locks owned by a thread. PR: 24641 Revision Changes Path 1.53 +1 -0 src/lib/libpthread/thread/thr_create.c 1.112 +4 -1 src/lib/libpthread/thread/thr_private.h 1.14 +81 -47 src/lib/libpthread/thread/thr_rwlock.c