Date: Sun, 21 May 2006 06:03:32 GMT From: John-Mark Gurney <jmg@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 97554 for review Message-ID: <200605210603.k4L63W41049633@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=97554 Change 97554 by jmg@jmg_carbon-60 on 2006/05/21 06:02:36 use function to get the parent instead of knowing what a device_t looks like... Affected files ... .. //depot/projects/kmacy_sun4v/src/sys/kern/subr_bus.c#5 edit Differences ... ==== //depot/projects/kmacy_sun4v/src/sys/kern/subr_bus.c#5 (text+ko) ==== @@ -3624,10 +3624,12 @@ bus_dma_tag_t bus_get_dma_tag(device_t dev) { + device_t parent; - if (dev->parent == NULL) + parent = device_get_parent(child); + if (parent == NULL) return (NULL); - return (BUS_GET_DMA_TAG(dev->parent, dev)); + return (BUS_GET_DMA_TAG(parent, dev)); } /* Resume all devices and then notify userland that we're up again. */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200605210603.k4L63W41049633>