From owner-cvs-all Fri May 7 0: 2:52 1999 Delivered-To: cvs-all@freebsd.org Received: from allegro.lemis.com (allegro.lemis.com [192.109.197.134]) by hub.freebsd.org (Postfix) with ESMTP id 9BCB7153D2; Fri, 7 May 1999 00:02:45 -0700 (PDT) (envelope-from grog@freebie.lemis.com) Received: from freebie.lemis.com (freebie.lemis.com [192.109.197.137]) by allegro.lemis.com (8.9.1/8.9.0) with ESMTP id QAA28728; Fri, 7 May 1999 16:32:44 +0930 (CST) Received: (from grog@localhost) by freebie.lemis.com (8.9.3/8.9.0) id QAA30042; Fri, 7 May 1999 16:32:38 +0930 (CST) Date: Fri, 7 May 1999 16:32:37 +0930 From: Greg Lehey To: Bruce Evans Cc: phk@critter.freebsd.dk, cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org Subject: Re: cvs commit: src/sys/sys disk.h Message-ID: <19990507163237.R40359@freebie.lemis.com> References: <199905070654.QAA18942@godzilla.zeta.org.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.4i In-Reply-To: <199905070654.QAA18942@godzilla.zeta.org.au>; from Bruce Evans on Fri, May 07, 1999 at 04:54:10PM +1000 WWW-Home-Page: http://www.lemis.com/~grog X-PGP-Fingerprint: 6B 7B C3 8C 61 CD 54 AF 13 24 52 F8 6D A4 95 EF Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-41-739-7062 Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk On Friday, 7 May 1999 at 16:54:10 +1000, Bruce Evans wrote: >> Funny, I thought the documentation went into /usr/src/share/doc, and >> old, no longer used files went to Attic. What am I missing? > > Most documentation goes into cvs history. Most unused kernel files > don't get put into the attic unless they are superseded by something > better. Small is beautiful. One less header file is good. disk.h got superseded by nothing :-) >> The only thing that will happen if the cruft is left in -CURRENT is >> that people like me will use the stuff. An #error in the file would > > What documentation or examples say to use it? :-) Novice hacker goes to guru. NH: Guru, I want to write a driver. G: RTFM. NH: Which FM? G: Read the source code of another driver, then WTFM. Guess which driver I read? >> just confuse the issue. As phk has pointed out, struct buf contains a >> whole lot of fields which never got used, but which countless >> generations of driver programmers religiously initialized. Cleaning >> this stuff up is good. > > They all got used but a few (2 or 3) recently became unused and fewer > (1 or 2) haven't been used for some time. Countless generations of > driver authors should have known to not even look at most fields in > struct buf. Only vfs_bio and meta-drivers like ccd and vinum need to > know about them. If these countless generations have known about it, how come buf(9) is still so woefully inadequate? I had a crack at it a while back, but it was almost impossible to write anything that I was certain about. I think you'll find that phk will drag up and eliminate a whole lot more cruft before he's done. I would have thought that you'd applaud his actions. Greg -- See complete headers for address, home page and phone numbers finger grog@lemis.com for PGP public key To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message