From owner-freebsd-current Tue Feb 11 0:56:26 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8AD8237B401; Tue, 11 Feb 2003 00:56:25 -0800 (PST) Received: from out014.verizon.net (out014pub.verizon.net [206.46.170.46]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8744443F75; Tue, 11 Feb 2003 00:56:24 -0800 (PST) (envelope-from mtm@identd.net) Received: from kokeb.ambesa.net ([138.88.50.112]) by out002.verizon.net (InterMail vM.5.01.05.20 201-253-122-126-120-20021101) with ESMTP id <20030210041249.VPEI7656.out002.verizon.net@kokeb.ambesa.net>; Sun, 9 Feb 2003 22:12:49 -0600 Date: Sun, 9 Feb 2003 23:12:44 -0500 From: Mike Makonnen To: Tim Robbins Cc: phk@phk.freebsd.dk, current@freebsd.org Subject: Re: MSDOSFS wastes 256k when nothing is mounted! In-Reply-To: <20030210133148.A17199@dilbert.robbins.dropbear.id.au> References: <31456.1044819599@critter.freebsd.dk> <20030209230848.VZI7113.pop015.verizon.net@kokeb.ambesa.net> <20030210133148.A17199@dilbert.robbins.dropbear.id.au> X-Mailer: Sylpheed version 0.8.10 (GTK+ 1.2.10; i386-portbld-freebsd5.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Authentication-Info: Submitted using SMTP AUTH at out002.verizon.net from [138.88.50.112] at Sun, 9 Feb 2003 22:12:45 -0600 Message-Id: <20030210041249.VPEI7656.out002.verizon.net@kokeb.ambesa.net> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, 10 Feb 2003 13:31:48 +1100 Tim Robbins wrote: > > hashinit() can sleep, and I don't think it's safe to sleep here > (msdosfs_hashget() and msdosfs_hashins()) with dehash_mtx and > sometimes a vnode lock held. Doh! I should have noticed that. > > It might be better to initialise the table the first time an > msdosfs filesystem is mounted. > Sounds reasonable enough. So, maybe allocate it in msdosfs_mount or mountmsdosfs and deallocate it in msdosfs_unmount? If there isn't an easy way to tell if you're on the last mounted msdos filesystem, it might be better to just leave the deallocation in msdosfs_uninit. Is that basically what you're saying? Cheers. -- Mike Makonnen | GPG-KEY: http://www.identd.net/~mtm/mtm.asc mtm@identd.net | Fingerprint: D228 1A6F C64E 120A A1C9 A3AA DAE1 E2AF DBCC 68B9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message