Date: Mon, 10 Jul 2006 23:02:55 GMT From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 101249 for review Message-ID: <200607102302.k6AN2tRH092184@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=101249 Change 101249 by imp@imp_lighthouse on 2006/07/10 23:02:29 Polish. We can implement wiring here in about 8 lines of code. Affected files ... .. //depot/projects/arm/src/sys/dev/pci/pci.c#10 edit Differences ... ==== //depot/projects/arm/src/sys/dev/pci/pci.c#10 (text+ko) ==== @@ -2005,17 +2005,15 @@ void pci_hint_device_unit(device_t bus, device_t child, int *unit) { - struct pci_devinfo *dinfo; - pcicfgregs *cfg; + struct pci_devinfo *dinfo = device_get_ivars(child); int i; char buf[10]; - dinfo = device_get_ivars(child); - cfg = &dinfo->cfg; + snprintf(buf, sizeof(buf), "%d:%d:%d", dinfo->cfg.bus, dinfo->cfg.slot, + dinfo->cfg.func); i = 0; - snprintf(buf, sizeof(buf), "%d:%d:%d", cfg->bus, cfg->slot, cfg->func); resource_find_dev(&i, device_get_name(child), unit, "location", buf); - device_printf(bus, "%s now %d\n", device_get_nameunit(child), *unit); + return; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200607102302.k6AN2tRH092184>