FreeBSD/sys/dev/drm2/drm_os_freebsd.c
/*
 * drm_attach_helper: called by a driver at the end of its attach
 * method.
 */
called by a driver at the end of its attach
method.
called by a driver at the end of its attach method .
int
drm_attach_helper(device_t kdev, const drm_pci_id_list_t *idlist,
    struct drm_driver *driver)
{
	struct drm_device *dev;
	int vendor, device;
	int ret;
	dev = device_get_softc(kdev);
	vendor = pci_get_vendor(kdev);
	device = pci_get_device(kdev);
	dev->id_entry = drm_find_description(vendor, device, idlist);
	ret = drm_get_pci_dev(kdev, dev, driver);
	return (ret);
}
int drm_attach_helper ( device_t kdev , const drm_pci_id_list_t * idlist , struct drm_driver * driver ) { struct drm_device * dev ; int vendor , device ; int ret ; dev = device_get_softc ( kdev ) ; vendor = pci_get_vendor ( kdev ) ; device = pci_get_device ( kdev ) ; dev -> id_entry = drm_find_description ( vendor , device , idlist ) ; ret = drm_get_pci_dev ( kdev , dev , driver ) ; return ( ret ) ; }
drm_attach_helper: called by a driver at the end of its attach
 method.
drm_attach_helper : called by a driver at the end of its attach method .