]> git.ipfire.org Git - thirdparty/pciutils.git/commitdiff
fbsd-device: Fix fbsd-device backend on DragonFly BSD.
authorImre Vadász <imrevdsz@gmail.com>
Fri, 14 Jul 2017 21:12:15 +0000 (23:12 +0200)
committerMartin Mares <mj@ucw.cz>
Fri, 17 Nov 2017 12:56:11 +0000 (13:56 +0100)
DragonFly also supports PCI domains same as FreeBSD.

Signed-off-by: Imre Vadász <imrevdsz@gmail.com>
lib/fbsd-device.c

index ab04954b6682a320e0b9215115a0801307ca3499..398fe680aacd60c82b41aa77080b9347f14bf296 100644 (file)
@@ -77,7 +77,7 @@ fbsd_read(struct pci_dev *d, int pos, byte *buf, int len)
   if (pos >= 256)
     return 0;
 
-#if __FreeBSD_version >= 700053
+#if __FreeBSD_version >= 700053 || defined(__DragonFly__)
   pi.pi_sel.pc_domain = d->domain;
 #endif
   pi.pi_sel.pc_bus = d->bus;
@@ -120,7 +120,7 @@ fbsd_write(struct pci_dev *d, int pos, byte *buf, int len)
   if (pos >= 256)
     return 0;
 
-#if __FreeBSD_version >= 700053
+#if __FreeBSD_version >= 700053 || defined(__DragonFly__)
   pi.pi_sel.pc_domain = d->domain;
 #endif
   pi.pi_sel.pc_bus = d->bus;