From owner-freebsd-arch@FreeBSD.ORG Sat Mar 27 00:55:47 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 954D516A4CF for ; Sat, 27 Mar 2004 00:55:47 -0800 (PST) Received: from crf-consulting.co.uk (82-44-220-218.cable.ubr10.haye.blueyonder.co.uk [82.44.220.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 83B1C43D39 for ; Sat, 27 Mar 2004 00:55:45 -0800 (PST) (envelope-from nik@crf-consulting.co.uk) Received: from clan.nothing-going-on.org (clan.nothing-going-on.org [192.168.1.20])i2R8td5U055886 for ; Sat, 27 Mar 2004 08:55:39 GMT (envelope-from nik@catkin) Received: from clan.nothing-going-on.org (localhost [127.0.0.1]) i2R8tcIq026205 for ; Sat, 27 Mar 2004 08:55:38 GMT (envelope-from nik@clan.nothing-going-on.org) Received: (from nik@localhost)i2R8tb5Z026204 for arch@freebsd.org; Sat, 27 Mar 2004 08:55:37 GMT (envelope-from nik) Date: Sat, 27 Mar 2004 08:55:37 +0000 From: Nik Clayton To: arch@freebsd.org Message-ID: <20040327085537.GC33016@clan.nothing-going-on.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="p2kqVDKq5asng8Dg" Content-Disposition: inline User-Agent: Mutt/1.4.2.1i Organization: FreeBSD Project Subject: Where should devctl notifications be sent from? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 27 Mar 2004 08:55:47 -0000 --p2kqVDKq5asng8Dg Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Apologies in advance if this is too trivial for -arch. I'm trying to work out where it's appropriate to add devctl notifications. The specific problem I'm trying to solve involves an iPod connected through firewire. I'd like to be able to have devd be notified when the iPod arrives, so that various processes can kick off automatically. In an ideal world, I'll drop the iPod in the dock, and some backup processes start, thereby allowing me to justify the purchase of a model several sizes larger than I actually need :-) It looks like there are several places where the devctl_queue_data() and related calls could be placed: firewire(4) -- when the device is plugged in fwohci(4) -- when the interface arrives sbp(4) -- when it's recognised as a mass storage device geom(4) -- when geom creates the device (/dev/da2 (and da2s2) in my case). Robert Watson has a patch that implements this. devfs -- specifically, in make_dev(9) and destroy_dev(9) The limited research that I've done suggests that the most generic place to put this code is inside make_dev(9) and destroy_dev(9). But this seems so trivial that I can't believe no one else hasn't done the work, so I figure there's probably something important that I'm missing. N --=20 FreeBSD: The Power to Serve http://www.freebsd.org/ (__) FreeBSD Documentation Project http://www.freebsd.org/docproj/ \\\'',) \/ \= ^ --- 15B8 3FFC DDB4 34B0 AA5F 94B7 93A8 0764 2C37 E375 --- .\._/= _) --p2kqVDKq5asng8Dg Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAZUGIk6gHZCw343URAjfSAJwIlysRuXL+loo40w5we/W4eB1nzACcCikR G9vlmYB7V9Wcl8XbuUjdaKI= =7Qmf -----END PGP SIGNATURE----- --p2kqVDKq5asng8Dg--