From owner-cvs-all@FreeBSD.ORG Mon Sep 11 19:41:32 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 22CA116A415; Mon, 11 Sep 2006 19:41:32 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E9A2B43D4C; Mon, 11 Sep 2006 19:41:31 +0000 (GMT) (envelope-from jhb@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8BJfVZ0089068; Mon, 11 Sep 2006 19:41:31 GMT (envelope-from jhb@repoman.freebsd.org) Received: (from jhb@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8BJfV8U089067; Mon, 11 Sep 2006 19:41:31 GMT (envelope-from jhb) Message-Id: <200609111941.k8BJfV8U089067@repoman.freebsd.org> From: John Baldwin Date: Mon, 11 Sep 2006 19:41:31 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/kern bus_if.m subr_bus.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Sep 2006 19:41:32 -0000 jhb 2006-09-11 19:41:31 UTC FreeBSD src repository Modified files: sys/kern bus_if.m subr_bus.c Log: Add a default method for BUS_ADD_CHILD() that just calls device_add_child_ordered(). Previously, a device driver that wanted to add a new child device in its identify routine had to know if the parent driver had a custom bus_add_child method and use BUS_ADD_CHILD() in that case, otherwise use device_add_child(). Getting it wrong in either direction would result in panics or failure to add the child device. Now, BUS_ADD_CHILD() always works isolating child drivers from having to know intimate details about the parent driver. Discussed with: imp MFC after: 1 week Revision Changes Path 1.32 +1 -1 src/sys/kern/bus_if.m 1.197 +7 -0 src/sys/kern/subr_bus.c