From owner-cvs-all Sun Aug 29 8:19:36 1999 Delivered-To: cvs-all@freebsd.org Received: from iaehv.iae.nl (iaehv.IAE.nl [194.151.64.2]) by hub.freebsd.org (Postfix) with ESMTP id 350AB1570F; Sun, 29 Aug 1999 08:19:26 -0700 (PDT) (envelope-from root@iae.nl) Received: by iaehv.iae.nl (Postfix, from userid 0) id F017620FB0; Sun, 29 Aug 1999 17:16:19 +0200 (CEST) To: ombre@iae.nl Received: from freebsd.iae.nl (freebsd.iae.nl [194.151.64.11]) by iaehv.iae.nl (Postfix) with ESMTP id 25FBB20F2A; Thu, 26 Aug 1999 08:39:57 +0200 (CEST) Received: from hub.freebsd.org (hub.FreeBSD.ORG [204.216.27.18]) by freebsd.iae.nl (Postfix) with ESMTP id 6EEBA5B8D; Thu, 26 Aug 1999 08:39:54 +0200 (CEST) Received: by hub.freebsd.org (Postfix, from userid 538) id 169151534B; Wed, 25 Aug 1999 23:39:46 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by hub.freebsd.org (Postfix) with SMTP id D874D1CD8C5; Wed, 25 Aug 1999 23:39:46 -0700 (PDT) (envelope-from owner-cvs-all) Received: by hub.freebsd.org (bulk_mailer v1.12); Wed, 25 Aug 1999 23:39:46 -0700 To: cvs-all@freebsd.org Received: from cs.rice.edu (cs.rice.edu [128.42.1.30]) by hub.freebsd.org (Postfix) with ESMTP id 60A1B1512F; Wed, 25 Aug 1999 23:39:39 -0700 (PDT) (envelope-from alc@cs.rice.edu) Received: (from alc@localhost) by cs.rice.edu (8.9.0/8.9.0) id BAA02564; Thu, 26 Aug 1999 01:39:21 -0500 (CDT) Date: Thu, 26 Aug 1999 01:39:21 -0500 From: Alan Cox X-Old-To: Stephen McKay Cc: cvs-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/vm vm_map.h Message-ID: <19990826013921.D27804@cs.rice.edu> References: <199908231808.LAA86314@freefall.freebsd.org> <199908250703.RAA14106@nymph.detir.qld.gov.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.5us In-Reply-To: <199908250703.RAA14106@nymph.detir.qld.gov.au>; from Stephen McKay on Wed, Aug 25, 1999 at 05:03:24PM +1000 Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk On Wed, Aug 25, 1999 at 05:03:24PM +1000, Stephen McKay wrote: > On Monday, 23rd August 1999, Alan Cox wrote: > > >alc 1999/08/23 11:08:35 PDT > > > > Modified files: > > sys/vm vm_map.h > > Log: > > struct vm_map: > > The lock structure cannot be the first element of the vm_map > > because this can result in livelock between two or more system > > processes trying to kmem_alloc_wait. > > Wouldn't it have been better to change the lock code to sleep on a field > within the lock structure, rather than the first byte? > Yes and no. :-) Doing as you suggest is a great idea because it could reduce the chance of this same problem happening elsewhere in the kernel. (So, I would welcome a patch that implements it.) On the other hand, this patch fixes the problem at hand and has a near-zero chance of causing any new problems. I don't feel the same way about any changes to lockmgr, and since 3.x-STABLE is subject to the same problem, I wanted to try the simplest patch, that I wouldn't worry about MFC'ing, first. Alan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message