From owner-freebsd-hackers Sun Dec 14 22:35:38 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id WAA26197 for hackers-outgoing; Sun, 14 Dec 1997 22:35:38 -0800 (PST) (envelope-from owner-freebsd-hackers) Received: from smtp04.primenet.com (smtp04.primenet.com [206.165.6.134]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id WAA26192 for ; Sun, 14 Dec 1997 22:35:33 -0800 (PST) (envelope-from tlambert@usr09.primenet.com) Received: (from daemon@localhost) by smtp04.primenet.com (8.8.8/8.8.8) id XAA10599; Sun, 14 Dec 1997 23:38:45 -0700 (MST) Received: from usr09.primenet.com(206.165.6.209) via SMTP by smtp04.primenet.com, id smtpd010547; Sun Dec 14 23:38:32 1997 Received: (from tlambert@localhost) by usr09.primenet.com (8.8.5/8.8.5) id XAA25793; Sun, 14 Dec 1997 23:34:44 -0700 (MST) From: Terry Lambert Message-Id: <199712150634.XAA25793@usr09.primenet.com> Subject: Re: blocksize on devfs entries (and related) To: mike@smith.net.au (Mike Smith) Date: Mon, 15 Dec 1997 06:34:44 +0000 (GMT) Cc: tlambert@primenet.com, mike@smith.net.au, bgingery@gtcs.com, hackers@FreeBSD.ORG In-Reply-To: <199712140222.MAA04796@word.smith.net.au> from "Mike Smith" at Dec 14, 97 12:52:07 pm X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > > Consider the FFS directory management code. It has knowledge of > > physical blocks. In fact, it can not easily handle a directory > > block that is not exactly a physical block size. The current code > > can not be broken across block I/O's, nor can it handle partial > > block I/O's well (there are a number of failure modes). > > This sounds like a fault in the FFS design. Do you know of any work > that deals with this? I dealt with this when I changed the DIRBLKSZ from 512 to 1024 in the Windows95 port of FFS that Artisoft did. I had to do this to support a maximally-sized Unicode file name in the Unicode namespace required by Windows 95's IFS. > > For you to be able to fit a maximally-sized file name in a single > > directory block means your directory block must be over 512 bytes > > in length. > > Would you suggest upping the "fundamental" system blocksize? How would > FFS cope in the face of 2k blocks? It would have to set the DIRBLKSZ to the minimum of the amount required and the physical block size, and deal with agregating multiple blocks. This has implications for the atomicity of the directory operations, since metadata updates must be synchronus. It's messy without changes to namei() and the opacity of a cn_pnbuf structure (which must be opaque in order to be able to serve multiple namespaces at the same time... not just because making it opaque renders the interface reflexive. It's the sweater where you pul one thread... > > Consider a FAT FS. A FAT FS deals with 1K blocks. But these 1K blocks > > are not constrained to start at an even offset from the start of the > > disk, only from an even cylinder boundry. > > In the light of the nonexistence of "cylinders" in the proposed model, > it strikes me that this becomes an issue of synthesising a conforming > pseudo-geometry at filesystem creation time, and little more. > Compatability is likely an issue there. Page alignment must equal 1k block alignment for the 0th of 4 blocks; alternately, access will be... uh, slow. > > Ah, brave new world, that has such thing in't. 8-). > > Yeah. I bet the old farts are saying "good thing it's them windbags > discussin' this, if'n it were someone prone to doin' stuff we'd be in > serious shit, eh boys"? 8) Well, you have commit privs, right? I wouldn't be adverse to having a little code committed. ;-). Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.