From owner-cvs-all@FreeBSD.ORG Sat May 24 14:51:30 2008 Return-Path: Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 91BE6106567B; Sat, 24 May 2008 14:51:30 +0000 (UTC) (envelope-from lulf@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 921918FC1B; Sat, 24 May 2008 14:51:30 +0000 (UTC) (envelope-from lulf@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m4OEpUFe053112; Sat, 24 May 2008 14:51:30 GMT (envelope-from lulf@repoman.freebsd.org) Received: (from lulf@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m4OEpU1r053111; Sat, 24 May 2008 14:51:30 GMT (envelope-from lulf) Message-Id: <200805241451.m4OEpU1r053111@repoman.freebsd.org> From: Ulf Lilleengen Date: Sat, 24 May 2008 14:51:30 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/fs/fdescfs fdesc.h fdesc_vfsops.c fdesc_vnops.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 24 May 2008 14:51:30 -0000 lulf 2008-05-24 14:51:30 UTC FreeBSD src repository Modified files: sys/fs/fdescfs fdesc.h fdesc_vfsops.c fdesc_vnops.c Log: - Add locking to all filesystem operations in fdescfs and flag it as MPSAFE. - Use proper synhronization primitives to protect the internal fdesc node cache used in fdescfs. - Properly initialize and uninitalize hash. - Remove unused functions. Since fdescfs might recurse on itself, adding proper locking to it needed some tricky workarounds in some parts to make it work. For instance, a descriptor in fdescfs could refer to an open descriptor to itself, thus forcing the thread to recurse on vnode locks. Because of this, other race conditions also had to be fixed. Tested by: pho Reviewed by: kib (mentor) Approved by: kib (mentor) Revision Changes Path 1.21 +7 -2 src/sys/fs/fdescfs/fdesc.h 1.59 +34 -10 src/sys/fs/fdescfs/fdesc_vfsops.c 1.109 +158 -72 src/sys/fs/fdescfs/fdesc_vnops.c