Date: Mon, 14 May 2007 21:50:31 GMT From: Bruce M Simpson <bms@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 119856 for review Message-ID: <200705142150.l4ELoVSR066366@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=119856 Change 119856 by bms@bms_anglepoise on 2007/05/14 21:50:17 Really be more like pci in output. Affected files ... .. //depot/projects/mips2/src/sys/dev/siba/siba.c#6 edit .. //depot/projects/mips2/src/sys/dev/siba/sibavar.h#3 edit Differences ... ==== //depot/projects/mips2/src/sys/dev/siba/siba.c#6 (text+ko) ==== @@ -565,6 +565,9 @@ case SIBA_IVAR_REVID: *result = sdi->sdi_rev; break; + case SIBA_IVAR_CORE_INDEX: + *result = sdi->sdi_idx; + break; default: return (ENOENT); } @@ -588,12 +591,19 @@ */ if (siba_debug) { struct siba_devid *sd; + sd = siba_dev_match(siba_get_vendor(child), siba_get_device(child), SIBA_REV_ANY); - device_printf(dev, - "<0x%04x, 0x%04x \"%s\"> (driver not attached)\n", - siba_get_vendor(child), siba_get_device(child), - sd != NULL ? sd->sd_desc : "unknown"); + if (sd != NULL && sd->sd_desc != NULL) { + device_printf(dev, "<%s> " + "at device %d (no driver attached)\n", + sd->sd_desc, siba_get_core_index(child)); + } else { + device_printf(dev, "<0x%04x, 0x%04x> " + "at device %d (no driver attached)\n", + siba_get_vendor(child), siba_get_device(child), + siba_get_core_index(child)); + } } } ==== //depot/projects/mips2/src/sys/dev/siba/sibavar.h#3 (text+ko) ==== @@ -73,15 +73,17 @@ enum siba_device_ivars { SIBA_IVAR_VENDOR, SIBA_IVAR_DEVICE, - SIBA_IVAR_REVID + SIBA_IVAR_REVID, + SIBA_IVAR_CORE_INDEX }; #define SIBA_ACCESSOR(var, ivar, type) \ __BUS_ACCESSOR(siba, var, SIBA, ivar, type) -SIBA_ACCESSOR(vendor, VENDOR, uint16_t) -SIBA_ACCESSOR(device, DEVICE, uint16_t) -SIBA_ACCESSOR(revid, REVID, uint8_t) +SIBA_ACCESSOR(vendor, VENDOR, uint16_t) +SIBA_ACCESSOR(device, DEVICE, uint16_t) +SIBA_ACCESSOR(revid, REVID, uint8_t) +SIBA_ACCESSOR(core_index, CORE_INDEX, uint8_t) #undef SIBA_ACCESSOR
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200705142150.l4ELoVSR066366>