summaryrefslogtreecommitdiff
path: root/sys/arch/alpha/pci
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2009-07-30 21:39:16 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2009-07-30 21:39:16 +0000
commitfe9ba901e1c6eddcdc81f086b39a0601fba19162 (patch)
tree2a68f88e407e57212c01b91db0a8b642f1bf69ff /sys/arch/alpha/pci
parent5a581115d78443c677ad9a44c9df9fe385c650fb (diff)
Get rid of the obsolet BUS_BARRIER_xxx constants for bus_space_barrier(), only
provide and use BUS_SPACE_BARRIER_xxx.
Diffstat (limited to 'sys/arch/alpha/pci')
-rw-r--r--sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c18
-rw-r--r--sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c18
-rw-r--r--sys/arch/alpha/pci/pci_swiz_bus_io_chipdep.c18
-rw-r--r--sys/arch/alpha/pci/pci_swiz_bus_mem_chipdep.c18
4 files changed, 40 insertions, 32 deletions
diff --git a/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c b/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c
index 89f84f9f152..7c3590184fb 100644
--- a/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c
+++ b/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_bwx_bus_io_chipdep.c,v 1.6 2009/07/26 18:48:54 miod Exp $ */
+/* $OpenBSD: pci_bwx_bus_io_chipdep.c,v 1.7 2009/07/30 21:39:15 miod Exp $ */
/* $NetBSD: pcs_bus_io_common.c,v 1.14 1996/12/02 22:19:35 cgd Exp $ */
/*
@@ -381,9 +381,9 @@ __C(CHIP,_io_barrier)(v, h, o, l, f)
int f;
{
- if ((f & BUS_BARRIER_READ) != 0)
+ if ((f & BUS_SPACE_BARRIER_READ) != 0)
alpha_mb();
- else if ((f & BUS_BARRIER_WRITE) != 0)
+ else if ((f & BUS_SPACE_BARRIER_WRITE) != 0)
alpha_wmb();
}
@@ -458,7 +458,7 @@ __C(__C(CHIP,_io_read_multi_),BYTES)(v, h, o, a, c) \
\
while (c-- > 0) { \
__C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_READ); \
+ BUS_SPACE_BARRIER_READ); \
*a++ = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
} \
}
@@ -563,7 +563,7 @@ __C(__C(CHIP,_io_write_multi_),BYTES)(v, h, o, a, c) \
while (c-- > 0) { \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, *a++); \
__C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_io_write_multi_N(1,u_int8_t)
@@ -602,7 +602,7 @@ __C(__C(CHIP,_io_set_multi_),BYTES)(v, h, o, val, c) \
while (c-- > 0) { \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, val); \
__C(CHIP,_io_barrier)(v, h, o, sizeof val, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_io_set_multi_N(1,u_int8_t)
@@ -659,7 +659,8 @@ __C(__C(CHIP,_io_read_raw_multi_),BYTES)(v, h, o, a, c) \
int i; \
\
while (c > 0) { \
- __C(CHIP,_io_barrier)(v, h, o, BYTES, BUS_BARRIER_READ); \
+ __C(CHIP,_io_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_READ); \
temp = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
i = MIN(c, BYTES); \
c -= i; \
@@ -692,7 +693,8 @@ __C(__C(CHIP,_io_write_raw_multi_),BYTES)(v, h, o, a, c) \
temp |= *(a + i); \
} \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, temp); \
- __C(CHIP,_io_barrier)(v, h, o, BYTES, BUS_BARRIER_WRITE); \
+ __C(CHIP,_io_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_WRITE); \
i = MIN(c, BYTES); \
c -= i; \
a += i; \
diff --git a/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c b/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c
index b5c5c3e3dbb..9e57698f998 100644
--- a/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c
+++ b/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_bwx_bus_mem_chipdep.c,v 1.7 2009/07/26 18:48:54 miod Exp $ */
+/* $OpenBSD: pci_bwx_bus_mem_chipdep.c,v 1.8 2009/07/30 21:39:15 miod Exp $ */
/* $NetBSD: pcs_bus_mem_common.c,v 1.15 1996/12/02 22:19:36 cgd Exp $ */
/*
@@ -415,9 +415,9 @@ __C(CHIP,_mem_barrier)(v, h, o, l, f)
int f;
{
- if ((f & BUS_BARRIER_READ) != 0)
+ if ((f & BUS_SPACE_BARRIER_READ) != 0)
alpha_mb();
- else if ((f & BUS_BARRIER_WRITE) != 0)
+ else if ((f & BUS_SPACE_BARRIER_WRITE) != 0)
alpha_wmb();
}
@@ -494,7 +494,7 @@ __C(__C(CHIP,_mem_read_multi_),BYTES)(v, h, o, a, c) \
\
while (c-- > 0) { \
__C(CHIP,_mem_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_READ); \
+ BUS_SPACE_BARRIER_READ); \
*a++ = __C(__C(CHIP,_mem_read_),BYTES)(v, h, o); \
} \
}
@@ -599,7 +599,7 @@ __C(__C(CHIP,_mem_write_multi_),BYTES)(v, h, o, a, c) \
while (c-- > 0) { \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, *a++); \
__C(CHIP,_mem_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_mem_write_multi_N(1,u_int8_t)
@@ -638,7 +638,7 @@ __C(__C(CHIP,_mem_set_multi_),BYTES)(v, h, o, val, c) \
while (c-- > 0) { \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, val); \
__C(CHIP,_mem_barrier)(v, h, o, sizeof val, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_mem_set_multi_N(1,u_int8_t)
@@ -706,7 +706,8 @@ __C(__C(CHIP,_mem_read_raw_multi_),BYTES)(v, h, o, a, c) \
int i; \
\
while (c > 0) { \
- __C(CHIP,_mem_barrier)(v, h, o, BYTES, BUS_BARRIER_READ); \
+ __C(CHIP,_mem_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_READ); \
temp = __C(__C(CHIP,_mem_read_),BYTES)(v, h, o); \
i = MIN(c, BYTES); \
c -= i; \
@@ -739,7 +740,8 @@ __C(__C(CHIP,_mem_write_raw_multi_),BYTES)(v, h, o, a, c) \
temp |= *(a + i); \
} \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, temp); \
- __C(CHIP,_mem_barrier)(v, h, o, BYTES, BUS_BARRIER_WRITE); \
+ __C(CHIP,_mem_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_WRITE); \
i = MIN(c, BYTES); \
c -= i; \
a += i; \
diff --git a/sys/arch/alpha/pci/pci_swiz_bus_io_chipdep.c b/sys/arch/alpha/pci/pci_swiz_bus_io_chipdep.c
index 3a41b3e98f6..d694c97af79 100644
--- a/sys/arch/alpha/pci/pci_swiz_bus_io_chipdep.c
+++ b/sys/arch/alpha/pci/pci_swiz_bus_io_chipdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_swiz_bus_io_chipdep.c,v 1.6 2009/07/26 18:48:54 miod Exp $ */
+/* $OpenBSD: pci_swiz_bus_io_chipdep.c,v 1.7 2009/07/30 21:39:15 miod Exp $ */
/* $NetBSD: pcs_bus_io_common.c,v 1.14 1996/12/02 22:19:35 cgd Exp $ */
/*
@@ -464,9 +464,9 @@ __C(CHIP,_io_barrier)(v, h, o, l, f)
int f;
{
- if ((f & BUS_BARRIER_READ) != 0)
+ if ((f & BUS_SPACE_BARRIER_READ) != 0)
alpha_mb();
- else if ((f & BUS_BARRIER_WRITE) != 0)
+ else if ((f & BUS_SPACE_BARRIER_WRITE) != 0)
alpha_wmb();
}
@@ -562,7 +562,7 @@ __C(__C(CHIP,_io_read_multi_),BYTES)(v, h, o, a, c) \
\
while (c-- > 0) { \
__C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_READ); \
+ BUS_SPACE_BARRIER_READ); \
*a++ = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
} \
}
@@ -672,7 +672,7 @@ __C(__C(CHIP,_io_write_multi_),BYTES)(v, h, o, a, c) \
while (c-- > 0) { \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, *a++); \
__C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_io_write_multi_N(1,u_int8_t)
@@ -711,7 +711,7 @@ __C(__C(CHIP,_io_set_multi_),BYTES)(v, h, o, val, c) \
while (c-- > 0) { \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, val); \
__C(CHIP,_io_barrier)(v, h, o, sizeof val, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_io_set_multi_N(1,u_int8_t)
@@ -768,7 +768,8 @@ __C(__C(CHIP,_io_read_raw_multi_),BYTES)(v, h, o, a, c) \
int i; \
\
while (c > 0) { \
- __C(CHIP,_io_barrier)(v, h, o, BYTES, BUS_BARRIER_READ); \
+ __C(CHIP,_io_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_READ); \
temp = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
i = MIN(c, BYTES); \
c -= i; \
@@ -801,7 +802,8 @@ __C(__C(CHIP,_io_write_raw_multi_),BYTES)(v, h, o, a, c) \
temp |= *(a + i); \
} \
__C(__C(CHIP,_io_write_),BYTES)(v, h, o, temp); \
- __C(CHIP,_io_barrier)(v, h, o, BYTES, BUS_BARRIER_WRITE); \
+ __C(CHIP,_io_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_WRITE); \
i = MIN(c, BYTES); \
c -= i; \
a += i; \
diff --git a/sys/arch/alpha/pci/pci_swiz_bus_mem_chipdep.c b/sys/arch/alpha/pci/pci_swiz_bus_mem_chipdep.c
index dfeee2283cc..b4fda0fd8c1 100644
--- a/sys/arch/alpha/pci/pci_swiz_bus_mem_chipdep.c
+++ b/sys/arch/alpha/pci/pci_swiz_bus_mem_chipdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_swiz_bus_mem_chipdep.c,v 1.5 2009/07/26 18:48:54 miod Exp $ */
+/* $OpenBSD: pci_swiz_bus_mem_chipdep.c,v 1.6 2009/07/30 21:39:15 miod Exp $ */
/* $NetBSD: pcs_bus_mem_common.c,v 1.15 1996/12/02 22:19:36 cgd Exp $ */
/*
@@ -697,9 +697,9 @@ __C(CHIP,_mem_barrier)(v, h, o, l, f)
int f;
{
- if ((f & BUS_BARRIER_READ) != 0)
+ if ((f & BUS_SPACE_BARRIER_READ) != 0)
alpha_mb();
- else if ((f & BUS_BARRIER_WRITE) != 0)
+ else if ((f & BUS_SPACE_BARRIER_WRITE) != 0)
alpha_wmb();
}
@@ -809,7 +809,7 @@ __C(__C(CHIP,_mem_read_multi_),BYTES)(v, h, o, a, c) \
\
while (c-- > 0) { \
__C(CHIP,_mem_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_READ); \
+ BUS_SPACE_BARRIER_READ); \
*a++ = __C(__C(CHIP,_mem_read_),BYTES)(v, h, o); \
} \
}
@@ -936,7 +936,7 @@ __C(__C(CHIP,_mem_write_multi_),BYTES)(v, h, o, a, c) \
while (c-- > 0) { \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, *a++); \
__C(CHIP,_mem_barrier)(v, h, o, sizeof *a, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_mem_write_multi_N(1,u_int8_t)
@@ -975,7 +975,7 @@ __C(__C(CHIP,_mem_set_multi_),BYTES)(v, h, o, val, c) \
while (c-- > 0) { \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, val); \
__C(CHIP,_mem_barrier)(v, h, o, sizeof val, \
- BUS_BARRIER_WRITE); \
+ BUS_SPACE_BARRIER_WRITE); \
} \
}
CHIP_mem_set_multi_N(1,u_int8_t)
@@ -1043,7 +1043,8 @@ __C(__C(CHIP,_mem_read_raw_multi_),BYTES)(v, h, o, a, c) \
int i; \
\
while (c > 0) { \
- __C(CHIP,_mem_barrier)(v, h, o, BYTES, BUS_BARRIER_READ); \
+ __C(CHIP,_mem_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_READ); \
temp = __C(__C(CHIP,_mem_read_),BYTES)(v, h, o); \
i = MIN(c, BYTES); \
c -= i; \
@@ -1076,7 +1077,8 @@ __C(__C(CHIP,_mem_write_raw_multi_),BYTES)(v, h, o, a, c) \
temp |= *(a + i); \
} \
__C(__C(CHIP,_mem_write_),BYTES)(v, h, o, temp); \
- __C(CHIP,_mem_barrier)(v, h, o, BYTES, BUS_BARRIER_WRITE); \
+ __C(CHIP,_mem_barrier)(v, h, o, BYTES, \
+ BUS_SPACE_BARRIER_WRITE); \
i = MIN(c, BYTES); \
c -= i; \
a += i; \