summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2007-10-10 15:31:00 -0700
committerEric Anholt <eric@anholt.net>2007-10-10 15:32:05 -0700
commitf0fd53f86b30e230f3f34b49b54392d20f053a89 (patch)
tree909cee66e7641408b89bf63096bc46a9849166d8
parentfc7d4d19d36b6a12ed23d4d9e50826346258299f (diff)
FreeBSD: Fill in domain field when supported.
-rw-r--r--bsd-core/drm_drv.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bsd-core/drm_drv.c b/bsd-core/drm_drv.c
index afd90351..c36b78aa 100644
--- a/bsd-core/drm_drv.c
+++ b/bsd-core/drm_drv.c
@@ -516,8 +516,11 @@ static int drm_load(drm_device_t *dev)
DRM_DEBUG( "\n" );
dev->irq = pci_get_irq(dev->device);
- /* XXX Fix domain number (alpha hoses) */
+#if defined(__FreeBSD__) && __FreeBSD_version >= 700053
+ dev->pci_domain = pci_get_domain(dev->device);
+#else
dev->pci_domain = 0;
+#endif
dev->pci_bus = pci_get_bus(dev->device);
dev->pci_slot = pci_get_slot(dev->device);
dev->pci_func = pci_get_function(dev->device);