From owner-freebsd-hackers Sat Sep 26 14:28:32 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA20499 for freebsd-hackers-outgoing; Sat, 26 Sep 1998 14:28:32 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from IAEhv.nl (iaehv.IAEhv.nl [194.151.64.2]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA20494 for ; Sat, 26 Sep 1998 14:28:29 -0700 (PDT) (envelope-from wjw@surf.IAE.nl) Received: from surf.IAE.nl (root@surf.IAEhv.nl [194.151.66.2]) by IAEhv.nl (8.8.7/8.8.7) with ESMTP id XAA09390; Sat, 26 Sep 1998 23:28:10 +0200 (CEST) Received: (from wjw@localhost) by surf.IAE.nl (8.8.7/8.8.7) id XAA03449; Sat, 26 Sep 1998 23:28:04 +0200 (MET DST) Date: Sat, 26 Sep 1998 23:28:04 +0200 (MET DST) From: Willem Jan Withagen Message-Id: <199809262128.XAA03449@surf.IAE.nl> To: mike@smith.net.au Subject: Re: sysctl descriptions.. sorta.. X-Newsgroups: list.freebsd.hackers In-Reply-To: <199809250748.AAA01220@word.smith.net.au> References: Organization: Internet Access Eindhoven, the Netherlands Cc: hackers@FreeBSD.ORG Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In article <199809250748.AAA01220@word.smith.net.au> you write: >> Welp, it's here.. I figured that the easiest way to go about adding some >> way to retreive descriptions for individual sysctls/mibs/whatever you want >> to call them was to add a syscall. >> >> So I've put some diffs that should add a new syscall (getsyscalldescr(2)) >> to achieve this (and also attempt to document a few more sysctls) at >> http://www.wenet.net/~garbanzo/junk. A small example of how to use this is >> also available at the afformentioned URL. > >Wrong way to do it. Use another "magic" method; see kern/kern_sysctl >for the existing "magic" methods. I'd use {0,5,...} in the same fashion >as {0,4,...} is already implemented. Should be very easy. Fortunately for me, is my dayjob so rewarding that I don't have time to complete the changes I had set for the sysctl-stuff. But I do know that I strongly agree with the comments in the files, that the interface should be riped out by its guts. And as such I strongly disagree with what Mike suggests. The smallest change to make te interface more "elegant", is to include a "opcode" parameter, instead of whacking it into the mib-id-field. And I still do not understand why some set of routines get to have unique system-calls where others are cramped into 1 omni-potent list of parameters. And yes, I do spent on and off time, to get done what I wanted to get done. --WjW -- Internet Access Eindhoven BV., voice: +31-40-2 393 393, data: +31-40-2 606 606 P.O. 928, 5600 AX Eindhoven, The Netherlands Full Internet connectivity for only fl 12.95 a month. Call now, and login as 'new'. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message