From owner-freebsd-hackers@FreeBSD.ORG Sun Jun 25 01:17:49 2006 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4A6A816A4CB for ; Sun, 25 Jun 2006 01:17:49 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (vc4-2-0-87.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id E75B843D45 for ; Sun, 25 Jun 2006 01:17:48 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (localhost.village.org [IPv6:::1] (may be forged)) by harmony.bsdimp.com (8.13.4/8.13.4) with ESMTP id k5P1Gv9h068790; Sat, 24 Jun 2006 19:16:58 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Sat, 24 Jun 2006 19:16:59 -0600 (MDT) Message-Id: <20060624.191659.1973602414.imp@bsdimp.com> To: zazubrik@mail.ru From: "M. Warner Losh" In-Reply-To: <922B6543-53D0-4877-9E97-B9ED1CDACFA8@mail.ru> References: <922B6543-53D0-4877-9E97-B9ED1CDACFA8@mail.ru> X-Mailer: Mew version 4.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: Buses, devices and modules X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Jun 2006 01:17:49 -0000 In message: <922B6543-53D0-4877-9E97-B9ED1CDACFA8@mail.ru> Artem Ignatiev writes: : When I do 'echo mydev_load="YES" >>/boot/loader.conf', loader loads : both mydev.ko and mybus.ko, and mybus.ko attaches properly, but : mydev.ko don't attach to anything. : : I suppose this happens because mydev happens to probe for devices : before mybus creates them, and fails to find anything to attach to. : : I'm looking for way to trigger the mydev driver to re-probe after the : mybus driver actually creates the devices, or may be I'm missing : something simple (like priority of module probing)? re-probing is automatic for all instances of bus FOO when a driver that has a FOO attachment is loaded. If the FOO bus driver creates a child device, then they are responsible for calling device_probe_and_attach on it. Warner