From owner-freebsd-arch@FreeBSD.ORG Thu May 13 05:34:40 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 D401A16A4CE; Thu, 13 May 2004 05:34:40 -0700 (PDT) Received: from mail.qubesoft.com (gate.qubesoft.com [217.169.36.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id E9E8543D2F; Thu, 13 May 2004 05:34:39 -0700 (PDT) (envelope-from dfr@nlsystems.com) Received: from bluebottle.qubesoft.com (bluebottle.qubesoft.com [192.168.1.2]) by mail.qubesoft.com (8.12.9/8.12.9) with ESMTP id i4DCYXkM021633; Thu, 13 May 2004 13:34:33 +0100 (BST) (envelope-from dfr@nlsystems.com) Received: from builder02.qubesoft.com (builder02.qubesoft.com [192.168.1.8]) i4DCYWON067231; Thu, 13 May 2004 13:34:32 +0100 (BST) (envelope-from dfr@nlsystems.com) From: Doug Rabson To: Dag-Erling =?ISO-8859-1?Q?Sm=F8rgrav?= In-Reply-To: References: <20040512175351.GF601@funkthat.com> <200405130927.01034.dfr@nlsystems.com> Content-Type: text/plain; charset=UTF-8 Message-Id: <1084451672.14878.5.camel@builder02.qubesoft.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Thu, 13 May 2004 13:34:32 +0100 Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV version 'clamd / ClamAV version 0.65', clamav-milter version '0.60p' cc: arch@freebsd.org cc: dfr@freebsd.org Subject: Re: newbus flaw 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: Thu, 13 May 2004 12:34:40 -0000 On Thu, 2004-05-13 at 11:46, Dag-Erling Smørgrav wrote: > Doug Rabson writes: > > When the old module unloaded, its driver will have detached from the > > device which it created. There is no reference to an old driver_t. Its > > perfectly safe for the new driver to use the old device. > > so why do you say I "shouldn't reset the old driver and desc"? I didn't say that (that was John-Mark). When you create a device using something like device_add_child(parent, "foo", unit), the new device is just labelled as a 'fooN' - it has no reference to any 'foo' driver and should have since there may be several. The 'foo'ness of the device is used to match the device against a suitable driver at probe time.