summaryrefslogtreecommitdiff
path: root/linux-core/drmP.h
diff options
context:
space:
mode:
authorDave Airlie <airlied@linux.ie>2006-08-19 16:55:00 +1000
committerDave Airlie <airlied@linux.ie>2006-08-19 16:55:00 +1000
commit3a681bb4c12ee1042eb31ec565a3eb2ecccddd3d (patch)
treed4cc3b0f3b10cd4ebd24f3b9721b7f83ad089783 /linux-core/drmP.h
parentcc71393559b94ba491059822d7cad388460a0ddf (diff)
remove local copies of pci domain/bus/slot/num
Diffstat (limited to 'linux-core/drmP.h')
-rw-r--r--linux-core/drmP.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/linux-core/drmP.h b/linux-core/drmP.h
index 6cbb810f..642ab4b0 100644
--- a/linux-core/drmP.h
+++ b/linux-core/drmP.h
@@ -747,10 +747,6 @@ typedef struct drm_device {
drm_agp_head_t *agp; /**< AGP data */
struct pci_dev *pdev; /**< PCI device structure */
- int pci_domain; /**< PCI bus domain number */
- int pci_bus; /**< PCI bus number */
- int pci_slot; /**< PCI slot number */
- int pci_func; /**< PCI function number */
#ifdef __alpha__
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,3)
struct pci_controler *hose;
@@ -776,6 +772,12 @@ static __inline__ int drm_core_check_feature(struct drm_device *dev,
return ((dev->driver->driver_features & feature) ? 1 : 0);
}
+#ifdef __alpha__
+#define drm_get_pci_domain(dev) dev->hose->bus->number
+#else
+#define drm_get_pci_domain(dev) pci_domain_nr(dev->pdev->bus)
+#endif
+
#if __OS_HAS_AGP
static inline int drm_core_has_AGP(struct drm_device *dev)
{