FreeBSD/sys/dev/pci/pci_subr.c
/*
 * Return a pointer to a pretty name for a PCI device.  If the device
 * has a driver attached, the device's name is used, otherwise a name
 * is generated from the device's PCI address.
 */
Return a pointer to a pretty name for a PCI device.  If the device
has a driver attached, the device's name is used, otherwise a name
is generated from the device's PCI address.
Return a pointer to a pretty name for a PCI device . If the device has a driver attached the device ' s name is used otherwise a name is generated from the device ' s PCI address .
const char *
pcib_child_name(device_t child)
{
	static char buf[64];
	if (device_get_nameunit(child) != NULL)
		return (device_get_nameunit(child));
	snprintf(buf, sizeof(buf), "pci%d:%d:%d:%d", pci_get_domain(child),
	    pci_get_bus(child), pci_get_slot(child), pci_get_function(child));
	return (buf);
}
const char * pcib_child_name ( device_t child ) { static char buf [ 64 ] ; if ( device_get_nameunit ( child ) != NULL ) return ( device_get_nameunit ( child ) ) ; snprintf ( buf , sizeof ( buf ) , " " , pci_get_domain ( child ) , pci_get_bus ( child ) , pci_get_slot ( child ) , pci_get_function ( child ) ) ; return ( buf ) ; }
Return a pointer to a pretty name for a PCI device.
Return a pointer to a pretty name for a PCI device .