diff options
author | Peter Wemm <peter@FreeBSD.org> | 2002-07-23 06:31:45 +0000 |
---|---|---|
committer | Peter Wemm <peter@FreeBSD.org> | 2002-07-23 06:31:45 +0000 |
commit | 65c4663d5f730e2cb891ac1274519b85f570740e (patch) | |
tree | 0363ea3d3ab8f0863e7c70731d7f34068c604f52 /sys/dev/aic7xxx | |
parent | 4d01a8fb5f783afbc4f35481970b8a7c6d22ca06 (diff) | |
download | src-65c4663d5f730e2cb891ac1274519b85f570740e.tar.gz src-65c4663d5f730e2cb891ac1274519b85f570740e.zip |
Minimal tweak to not depend on NPCI, but still maintain portability
to 4.x which still does need it (since pci_if.h isn't generated without
pci being present)
Notes
Notes:
svn path=/head/; revision=100548
Diffstat (limited to 'sys/dev/aic7xxx')
-rw-r--r-- | sys/dev/aic7xxx/aic79xx_osm.h | 9 | ||||
-rw-r--r-- | sys/dev/aic7xxx/aic7xxx_osm.h | 9 |
2 files changed, 12 insertions, 6 deletions
diff --git a/sys/dev/aic7xxx/aic79xx_osm.h b/sys/dev/aic7xxx/aic79xx_osm.h index 83c1706c7182..cc4edad5de10 100644 --- a/sys/dev/aic7xxx/aic79xx_osm.h +++ b/sys/dev/aic7xxx/aic79xx_osm.h @@ -38,9 +38,6 @@ #define _AIC79XX_FREEBSD_H_ #include <opt_aic79xx.h> /* for config options */ -#ifndef NPCI -#include <pci.h> -#endif #include <sys/param.h> #include <sys/systm.h> @@ -50,6 +47,12 @@ #include <sys/malloc.h> #include <sys/queue.h> +#if __FreeBSD_version < 500000 +#include <pci.h> +#else +#define NPCI 1 +#endif + #define AHD_PCI_CONFIG 1 #include <machine/bus_memio.h> #include <machine/bus_pio.h> diff --git a/sys/dev/aic7xxx/aic7xxx_osm.h b/sys/dev/aic7xxx/aic7xxx_osm.h index 86361ab3cef2..c81a1b2b301d 100644 --- a/sys/dev/aic7xxx/aic7xxx_osm.h +++ b/sys/dev/aic7xxx/aic7xxx_osm.h @@ -38,9 +38,6 @@ #define _AIC7XXX_FREEBSD_H_ #include <opt_aic7xxx.h> /* for config options */ -#ifndef NPCI -#include <pci.h> -#endif #include <sys/param.h> #include <sys/systm.h> @@ -51,6 +48,12 @@ #include <sys/malloc.h> #include <sys/queue.h> +#if __FreeBSD_version < 500000 +#include <pci.h> +#else +#define NPCI 1 +#endif + #if NPCI > 0 #define AHC_PCI_CONFIG 1 #ifdef AHC_ALLOW_MEMIO |