From owner-svn-src-all@FreeBSD.ORG Sun May 23 09:44:48 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AB0BD106566B; Sun, 23 May 2010 09:44:48 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (unknown [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9B0AA8FC1C; Sun, 23 May 2010 09:44:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o4N9imfp036857; Sun, 23 May 2010 09:44:48 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o4N9imO9036855; Sun, 23 May 2010 09:44:48 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201005230944.o4N9imO9036855@svn.freebsd.org> From: Alexander Motin Date: Sun, 23 May 2010 09:44:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r208441 - head/sys/dev/mmc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 May 2010 09:44:48 -0000 Author: mav Date: Sun May 23 09:44:48 2010 New Revision: 208441 URL: http://svn.freebsd.org/changeset/base/208441 Log: Report relative card address to NewBus as location string. Modified: head/sys/dev/mmc/mmc.c Modified: head/sys/dev/mmc/mmc.c ============================================================================== --- head/sys/dev/mmc/mmc.c Sun May 23 09:28:55 2010 (r208440) +++ head/sys/dev/mmc/mmc.c Sun May 23 09:44:48 2010 (r208441) @@ -1500,6 +1500,15 @@ mmc_delayed_attach(void *xsc) config_intrhook_disestablish(&sc->config_intrhook); } +static int +mmc_child_location_str(device_t dev, device_t child, char *buf, + size_t buflen) +{ + + snprintf(buf, buflen, "rca=0x%04x", mmc_get_rca(child)); + return (0); +} + static device_method_t mmc_methods[] = { /* device_if */ DEVMETHOD(device_probe, mmc_probe), @@ -1511,6 +1520,7 @@ static device_method_t mmc_methods[] = { /* Bus interface */ DEVMETHOD(bus_read_ivar, mmc_read_ivar), DEVMETHOD(bus_write_ivar, mmc_write_ivar), + DEVMETHOD(bus_child_location_str, mmc_child_location_str), /* MMC Bus interface */ DEVMETHOD(mmcbus_wait_for_request, mmc_wait_for_request),