diff options
author | Jon Smirl <jonsmirl@yahoo.com> | 2004-09-10 16:44:28 +0000 |
---|---|---|
committer | Jon Smirl <jonsmirl@yahoo.com> | 2004-09-10 16:44:28 +0000 |
commit | e6d468ad7f398a72e8be227564f3a450de873cc6 (patch) | |
tree | 214046d093e641f91bfc8d962d7f9c303382488f /linux | |
parent | 1fb27632c3338ff974c27fd88e2098a5193bb145 (diff) |
More general patch to mark resources in use by all DRM drivers. Makes the
code Linux specific.
Diffstat (limited to 'linux')
-rw-r--r-- | linux/drm_drv.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/linux/drm_drv.h b/linux/drm_drv.h index 12d2a5329..09e503823 100644 --- a/linux/drm_drv.h +++ b/linux/drm_drv.h @@ -464,8 +464,10 @@ static int drm_probe(struct pci_dev *pdev, const struct pci_device_id *ent) return -ENODEV; dev = &(DRM(device)[DRM(numdevs)]); - if (DRM(fb_loaded)==0) + if (DRM(fb_loaded)==0) { pci_set_drvdata(pdev, dev); + pci_request_regions(pdev, DRIVER_NAME); + } memset( (void *)dev, 0, sizeof(*dev) ); dev->count_lock = SPIN_LOCK_UNLOCKED; @@ -568,6 +570,7 @@ static void __exit drm_cleanup_pci(struct pci_dev *pdev) pci_set_drvdata(pdev, NULL); drm_cleanup(dev); + pci_release_regions(pdev); } static struct pci_driver drm_driver = { |