summaryrefslogtreecommitdiffstats
path: root/sys/dev/aic7xxx
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-09-02 17:30:40 +0000
committerjhb <jhb@FreeBSD.org>2003-09-02 17:30:40 +0000
commitdc11e45b68dec5003e226a26f7fa2ee9a1e351c2 (patch)
tree1a7743437055722d93fce73b145dde1eb1915e7f /sys/dev/aic7xxx
parent480ed8b5934d938866a31bd84aa636de31845487 (diff)
downloadFreeBSD-src-dc11e45b68dec5003e226a26f7fa2ee9a1e351c2.zip
FreeBSD-src-dc11e45b68dec5003e226a26f7fa2ee9a1e351c2.tar.gz
Use PCIR_BAR(x) instead of PCIR_MAPS.
Glanced over by: imp, gibbs Tested by: i386 LINT
Diffstat (limited to 'sys/dev/aic7xxx')
-rw-r--r--sys/dev/aic7xxx/ahc_pci.c4
-rw-r--r--sys/dev/aic7xxx/ahd_pci.c6
-rw-r--r--sys/dev/aic7xxx/aic79xx.h6
-rw-r--r--sys/dev/aic7xxx/aic7xxx_pci.c4
4 files changed, 10 insertions, 10 deletions
diff --git a/sys/dev/aic7xxx/ahc_pci.c b/sys/dev/aic7xxx/ahc_pci.c
index 5d22f5e..84c96d4 100644
--- a/sys/dev/aic7xxx/ahc_pci.c
+++ b/sys/dev/aic7xxx/ahc_pci.c
@@ -36,8 +36,8 @@ __FBSDID("$FreeBSD$");
#include <dev/aic7xxx/aic7xxx_osm.h>
-#define AHC_PCI_IOADDR PCIR_MAPS /* I/O Address */
-#define AHC_PCI_MEMADDR (PCIR_MAPS + 4) /* Mem I/O Address */
+#define AHC_PCI_IOADDR PCIR_BAR(0) /* I/O Address */
+#define AHC_PCI_MEMADDR PCIR_BAR(1) /* Mem I/O Address */
static int ahc_pci_probe(device_t dev);
static int ahc_pci_attach(device_t dev);
diff --git a/sys/dev/aic7xxx/ahd_pci.c b/sys/dev/aic7xxx/ahd_pci.c
index 09ea819..d3cdab0 100644
--- a/sys/dev/aic7xxx/ahd_pci.c
+++ b/sys/dev/aic7xxx/ahd_pci.c
@@ -36,9 +36,9 @@ __FBSDID("$FreeBSD$");
#include <dev/aic7xxx/aic79xx_osm.h>
-#define AHD_PCI_IOADDR0 PCIR_MAPS /* Primary I/O BAR */
-#define AHD_PCI_MEMADDR (PCIR_MAPS + 4) /* Mem I/O Address */
-#define AHD_PCI_IOADDR1 (PCIR_MAPS + 12)/* Secondary I/O BAR */
+#define AHD_PCI_IOADDR0 PCIR_BAR(0) /* Primary I/O BAR */
+#define AHD_PCI_MEMADDR PCIR_BAR(1) /* Mem I/O Address */
+#define AHD_PCI_IOADDR1 PCIR_BAR(3) /* Secondary I/O BAR */
static int ahd_pci_probe(device_t dev);
static int ahd_pci_attach(device_t dev);
diff --git a/sys/dev/aic7xxx/aic79xx.h b/sys/dev/aic7xxx/aic79xx.h
index 2b758bc..16706e3 100644
--- a/sys/dev/aic7xxx/aic79xx.h
+++ b/sys/dev/aic7xxx/aic79xx.h
@@ -1298,9 +1298,9 @@ struct ahd_devinfo {
};
/****************************** PCI Structures ********************************/
-#define AHD_PCI_IOADDR0 PCIR_MAPS /* I/O BAR*/
-#define AHD_PCI_MEMADDR (PCIR_MAPS + 4) /* Memory BAR */
-#define AHD_PCI_IOADDR1 (PCIR_MAPS + 12)/* Second I/O BAR */
+#define AHD_PCI_IOADDR0 PCIR_BAR(0) /* I/O BAR*/
+#define AHD_PCI_MEMADDR PCIR_BAR(1) /* Memory BAR */
+#define AHD_PCI_IOADDR1 PCIR_BAR(3) /* Second I/O BAR */
typedef int (ahd_device_setup_t)(struct ahd_softc *);
diff --git a/sys/dev/aic7xxx/aic7xxx_pci.c b/sys/dev/aic7xxx/aic7xxx_pci.c
index 8f87524..9e1e81e 100644
--- a/sys/dev/aic7xxx/aic7xxx_pci.c
+++ b/sys/dev/aic7xxx/aic7xxx_pci.c
@@ -55,8 +55,8 @@ __FBSDID("$FreeBSD$");
#include <dev/aic7xxx/aic7xxx_93cx6.h>
#endif
-#define AHC_PCI_IOADDR PCIR_MAPS /* I/O Address */
-#define AHC_PCI_MEMADDR (PCIR_MAPS + 4) /* Mem I/O Address */
+#define AHC_PCI_IOADDR PCIR_BAR(0) /* I/O Address */
+#define AHC_PCI_MEMADDR PCIR_BAR(1) /* Mem I/O Address */
static __inline uint64_t
ahc_compose_id(u_int device, u_int vendor, u_int subdevice, u_int subvendor)
OpenPOWER on IntegriCloud