From owner-freebsd-hackers Mon Oct 20 17:11:31 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id RAA01084 for hackers-outgoing; Mon, 20 Oct 1997 17:11:31 -0700 (PDT) (envelope-from owner-freebsd-hackers) Received: from smtp02.primenet.com (smtp02.primenet.com [206.165.5.83]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id RAA01077 for ; Mon, 20 Oct 1997 17:11:27 -0700 (PDT) (envelope-from tlambert@usr05.primenet.com) Received: (from daemon@localhost) by smtp02.primenet.com (8.8.7/8.8.5) id RAA01527; Mon, 20 Oct 1997 17:11:13 -0700 (MST) Received: from usr05.primenet.com(206.165.6.205) via SMTP by smtp02.primenet.com, id smtpd001515; Mon Oct 20 17:11:08 1997 Received: (from tlambert@localhost) by usr05.primenet.com (8.8.5/8.8.5) id RAA28373; Mon, 20 Oct 1997 17:11:05 -0700 (MST) From: Terry Lambert Message-Id: <199710210011.RAA28373@usr05.primenet.com> Subject: Re: FreeBSD 3.0 kernel API ?! To: darrenr@cyber.com.au (Darren Reed) Date: Tue, 21 Oct 1997 00:11:04 +0000 (GMT) Cc: tlambert@primenet.com, julian@whistle.com, hackers@FreeBSD.ORG In-Reply-To: <199710202357.JAA09206@plum.cyber.com.au> from "Darren Reed" at Oct 21, 97 09:57:17 am X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > Sigh. This is all very amusing, I guess. Here's a tip for you: > if you *really* want to separate what user programs can and can not > include (or should and should not), don't put any "kernel only" > include files under /usr/include and remove all references from > /usr/include files to anything that should only be in the kernel. The idea, I believe, is to clean up our own misuse of KVM as a non-procedural interface to kernel data. Non-procedural interfaces are bad because: 1) You can't hook them 2) A data version change equals an interface change, and requires you to rebuild everything that references the data 3) You can't "version" the interface so that the program using it can operate against both old and new versions. > Sure, you'll break lots of software out there, be totally > incompatible with everything else and annoy lots of 3rd party > software writers, but it _will_ achieve the goal you're aiming > for: - penalising anyone and everyone who makes use of a kernel > structure for non-kernel code, irrespective of its use. The only thing we intended to break was ourselves, because we knew we were engaging in bad programming habits. It's only your poor fortune to have *also* been engaging in bad programming habits. > Personally, I don't think any changes should be made for the > sake of making a change to hide structures but rather, effort > should be put into developing useful interfaces which software > can take advantage of. I agree. But how can we get a picture of the spanning set of new interfaces needed unless we take away all of the old interfaces, and log what fails? Sure, we could organically grow things, and let duplicate functionality (say like /procfs and sysinit) creep up on us, so that we can't really point at "here is the right way", but do we really want that? Brass tacks time: Why do *you, personally* need the kernel internal structure defined by struct ifnet? Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.