svn commit: r208441 - head/sys/dev/mmc
Alexander Motin
mav at FreeBSD.org
Sun May 23 09:44:48 UTC 2010
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),
More information about the svn-src-all
mailing list