From owner-freebsd-current Sat Dec 11 14: 2:57 1999 Delivered-To: freebsd-current@freebsd.org Received: from server.baldwin.cx (jobaldwi.campus.vt.edu [198.82.67.146]) by hub.freebsd.org (Postfix) with ESMTP id C0BC514C4B for ; Sat, 11 Dec 1999 14:02:48 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: from john.baldwin.cx (john [10.0.0.2]) by server.baldwin.cx (8.9.3/8.9.3) with ESMTP id RAA76379; Sat, 11 Dec 1999 17:02:40 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-Id: <199912112202.RAA76379@server.baldwin.cx> X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <91986.944949603@zippy.cdrom.com> Date: Sat, 11 Dec 1999 17:02:40 -0500 (EST) From: John Baldwin To: "Jordan K. Hubbard" Subject: Re: Modules and sysctl tree Cc: freebsd-current@FreeBSD.org, abial@webgiro.com, Archie Cobbs Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 11-Dec-99 Jordan K. Hubbard wrote: >> In other words, it's not a problem specific to KLD's .. but >> it's still a problem :-) > > Which raises an important issue - other than walking the sysctl tree > regularly looking for changes, how does such an application become > aware that the sysctl space has changed? The same holds true for a > dynamic /dev, of course, though one assumes one can at least hack a > solution with devfs where you stat the directory and compare its > current mod time with a saved one, only walking the directory if you > see a change. I don't see any kind of mechanism for doing this > with sysctl, even as a gross hack. Perhaps a modtime on the sysctl tree as a gross hack? Inside of sysctl() and the SYSCTL() macros you would update the time every time a write was made, node added, node removed, etc. However, it is a gross hack. > - Jordan -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.cslab.vt.edu/~jobaldwi/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message