From owner-p4-projects@FreeBSD.ORG Fri Jun 26 06:21:42 2009 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DA91E1065673; Fri, 26 Jun 2009 06:21:40 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A5EB106564A for ; Fri, 26 Jun 2009 06:21:40 +0000 (UTC) (envelope-from mav@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 88EAF8FC08 for ; Fri, 26 Jun 2009 06:21:40 +0000 (UTC) (envelope-from mav@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n5Q6LeHj060603 for ; Fri, 26 Jun 2009 06:21:40 GMT (envelope-from mav@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n5Q6LeCv060601 for perforce@freebsd.org; Fri, 26 Jun 2009 06:21:40 GMT (envelope-from mav@freebsd.org) Date: Fri, 26 Jun 2009 06:21:40 GMT Message-Id: <200906260621.n5Q6LeCv060601@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mav@freebsd.org using -f From: Alexander Motin To: Perforce Change Reviews Cc: Subject: PERFORCE change 165238 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Jun 2009 06:21:43 -0000 http://perforce.freebsd.org/chv.cgi?CH=165238 Change 165238 by mav@mav_mavbook on 2009/06/26 06:21:14 Log real AHCI channel number inside controller. There can be holes from uniplemented ports. Affected files ... .. //depot/projects/scottl-camlock/src/sys/dev/ahci/ahci.c#37 edit Differences ... ==== //depot/projects/scottl-camlock/src/sys/dev/ahci/ahci.c#37 (text+ko) ==== @@ -468,6 +468,19 @@ return (0); } +static int +ahci_print_child(device_t dev, device_t child) +{ + int retval; + + retval = bus_print_child_header(dev, child); + retval += printf(" at channel %d", + (int)(intptr_t)device_get_ivars(child)); + retval += bus_print_child_footer(dev, child); + + return (retval); +} + devclass_t ahci_devclass; static device_method_t ahci_methods[] = { DEVMETHOD(device_probe, ahci_probe), @@ -475,6 +488,7 @@ DEVMETHOD(device_detach, ahci_detach), DEVMETHOD(device_suspend, ahci_suspend), DEVMETHOD(device_resume, ahci_resume), + DEVMETHOD(bus_print_child, ahci_print_child), DEVMETHOD(bus_alloc_resource, ahci_alloc_resource), DEVMETHOD(bus_release_resource, ahci_release_resource), DEVMETHOD(bus_setup_intr, ahci_setup_intr),