summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorJason Wright <jason@cvs.openbsd.org>2002-02-19 05:03:43 +0000
committerJason Wright <jason@cvs.openbsd.org>2002-02-19 05:03:43 +0000
commitf036314cd6f9fc62f27e25e489ffdd6757eaf683 (patch)
tree446f95ab716897d555b9e074d3edead574aa6426 /sys/arch
parentd7b1c731b1a053e0e3513049eb169d8d05a742bc (diff)
From NetBSD:
change some debug printfs to make gcc happy
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/sparc64/include/bus.h142
1 files changed, 71 insertions, 71 deletions
diff --git a/sys/arch/sparc64/include/bus.h b/sys/arch/sparc64/include/bus.h
index ee9455a5f67..f33550d500f 100644
--- a/sys/arch/sparc64/include/bus.h
+++ b/sys/arch/sparc64/include/bus.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: bus.h,v 1.8 2002/02/05 18:34:39 jason Exp $ */
+/* $OpenBSD: bus.h,v 1.9 2002/02/19 05:03:42 jason Exp $ */
/* $NetBSD: bus.h,v 1.31 2001/09/21 15:30:41 wiz Exp $ */
/*-
@@ -418,8 +418,8 @@ int bus_space_probe __P((
unsigned char __bv = \
lduba((h) + (o), bus_type_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr1(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsr1(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], (unsigned int) __bv); \
__bv; })
@@ -427,8 +427,8 @@ int bus_space_probe __P((
unsigned short __bv = \
lduha((h) + (o), bus_type_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr2(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsr2(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], (unsigned int)__bv); \
__bv; })
@@ -436,8 +436,8 @@ int bus_space_probe __P((
unsigned int __bv = \
lda((h) + (o), bus_type_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr4(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsr4(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], __bv); \
__bv; })
@@ -445,9 +445,9 @@ int bus_space_probe __P((
u_int64_t __bv = \
ldxa((h) + (o), bus_type_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr8(%llx + %llx, %x) -> %llx\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_type_asi[(t)->type], __bv); \
+ printf("bsr8(%llx + %llx, %x) -> %llx\n", (long long)(h), \
+ (long long)(o), \
+ bus_type_asi[(t)->type], (long long)__bv); \
__bv; })
#endif
/*
@@ -510,30 +510,30 @@ int bus_space_probe __P((
#else
#define bus_space_write_1(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw1(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw1(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], (unsigned int) v); \
((void)(stba((h) + (o), bus_type_asi[(t)->type], (v)))); })
#define bus_space_write_2(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw2(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw2(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], (unsigned int) v); \
((void)(stha((h) + (o), bus_type_asi[(t)->type], (v)))); })
#define bus_space_write_4(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw4(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw4(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_type_asi[(t)->type], (unsigned int) v); \
((void)(sta((h) + (o), bus_type_asi[(t)->type], (v)))); })
#define bus_space_write_8(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw8(%llx + %llx, %x) <- %llx\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_type_asi[(t)->type], (u_int64_t) v); \
+ printf("bsw8(%llx + %llx, %x) <- %llx\n", (long long)(h), \
+ (long long)(o), \
+ bus_type_asi[(t)->type], (long long) v); \
((void)(stxa((h) + (o), bus_type_asi[(t)->type], (v)))); })
#endif
/*
@@ -918,38 +918,38 @@ bus_space_copy_region_8(t, h1, o1, h2, o2, c)
#else
#define bus_space_read_stream_1(t, h, o) ({ \
unsigned char __bv = \
- lduba((h) + (o), bus_stream_asi[(t)->type]); \
+ lduba((h) + (o), bus_stream_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr1(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_stream_asi[(t)->type], (unsigned int) __bv); \
+ printf("bsr1(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
+ bus_stream_asi[(t)->type], (unsigned int) __bv); \
__bv; })
#define bus_space_read_stream_2(t, h, o) ({ \
unsigned short __bv = \
- lduha((h) + (o), bus_stream_asi[(t)->type]); \
+ lduha((h) + (o), bus_stream_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr2(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsr2(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
bus_stream_asi[(t)->type], (unsigned int)__bv); \
__bv; })
-#define bus_space_read_stream_4(t, h, o) ({ \
+#define bus_space_read_stream_4(t, h, o) ({ \
unsigned int __bv = \
lda((h) + (o), bus_stream_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr4(%llx + %llx, %x) -> %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_stream_asi[(t)->type], __bv); \
+ printf("bsr4(%llx + %llx, %x) -> %x\n", (long long)(h), \
+ (long long)(o), \
+ bus_stream_asi[(t)->type], __bv); \
__bv; })
-#define bus_space_read_stream_8(t, h, o) ({ \
+#define bus_space_read_stream_8(t, h, o) ({ \
u_int64_t __bv = \
ldxa((h) + (o), bus_stream_asi[(t)->type]); \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsr8(%llx + %llx, %x) -> %llx\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_stream_asi[(t)->type], __bv); \
+ printf("bsr8(%llx + %llx, %x) -> %llx\n", (long long)(h), \
+ (long long)(o), \
+ bus_stream_asi[(t)->type], (long long)__bv); \
__bv; })
#endif
/*
@@ -961,32 +961,32 @@ bus_space_copy_region_8(t, h1, o1, h2, o2, c)
* described by tag/handle/offset and copy into buffer provided.
*/
-#define bus_space_read_multi_stream_1(t, h, o, a, c) do { \
+#define bus_space_read_multi_stream_1(t, h, o, a, c) do { \
int i = c; \
u_int8_t *p = (u_int8_t *)a; \
while (i-- > 0) \
- *p++ = bus_space_read_stream_1(t, h, o); \
+ *p++ = bus_space_read_stream_1(t, h, o); \
} while (0)
-#define bus_space_read_multi_stream_2(t, h, o, a, c) do { \
+#define bus_space_read_multi_stream_2(t, h, o, a, c) do { \
int i = c; \
u_int16_t *p = (u_int16_t *)a; \
while (i-- > 0) \
- *p++ = bus_space_read_stream_2(t, h, o); \
+ *p++ = bus_space_read_stream_2(t, h, o); \
} while (0)
-#define bus_space_read_multi_stream_4(t, h, o, a, c) do { \
+#define bus_space_read_multi_stream_4(t, h, o, a, c) do { \
int i = c; \
u_int32_t *p = (u_int32_t *)a; \
while (i-- > 0) \
- *p++ = bus_space_read_stream_4(t, h, o); \
+ *p++ = bus_space_read_stream_4(t, h, o); \
} while (0)
-#define bus_space_read_multi_stream_8(t, h, o, a, c) do { \
+#define bus_space_read_multi_stream_8(t, h, o, a, c) do { \
int i = c; \
u_int64_t *p = (u_int64_t *)a; \
while (i-- > 0) \
- *p++ = bus_space_read_stream_8(t, h, o); \
+ *p++ = bus_space_read_stream_8(t, h, o); \
} while (0)
/*
@@ -998,44 +998,44 @@ bus_space_copy_region_8(t, h1, o1, h2, o2, c)
* described by tag/handle/offset.
*/
#ifndef BUS_SPACE_DEBUG
-#define bus_space_write_stream_1(t, h, o, v) \
+#define bus_space_write_stream_1(t, h, o, v) \
((void)(stba((h) + (o), bus_stream_asi[(t)->type], (v))))
-#define bus_space_write_stream_2(t, h, o, v) \
+#define bus_space_write_stream_2(t, h, o, v) \
((void)(stha((h) + (o), bus_stream_asi[(t)->type], (v))))
-#define bus_space_write_stream_4(t, h, o, v) \
+#define bus_space_write_stream_4(t, h, o, v) \
((void)(sta((h) + (o), bus_stream_asi[(t)->type], (v))))
-#define bus_space_write_stream_8(t, h, o, v) \
+#define bus_space_write_stream_8(t, h, o, v) \
((void)(stxa((h) + (o), bus_stream_asi[(t)->type], (v))))
#else
#define bus_space_write_stream_1(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw1(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw1(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_stream_asi[(t)->type], (unsigned int) v); \
((void)(stba((h) + (o), bus_stream_asi[(t)->type], (v)))); })
#define bus_space_write_stream_2(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw2(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw2(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_stream_asi[(t)->type], (unsigned int) v); \
((void)(stha((h) + (o), bus_stream_asi[(t)->type], (v)))); })
#define bus_space_write_stream_4(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw4(%llx + %llx, %x) <- %x\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
+ printf("bsw4(%llx + %llx, %x) <- %x\n", (long long)(h), \
+ (long long)(o), \
bus_stream_asi[(t)->type], (unsigned int) v); \
((void)(sta((h) + (o), bus_stream_asi[(t)->type], (v)))); })
#define bus_space_write_stream_8(t, h, o, v) ({ \
if (bus_space_debug & BSDB_ACCESS) \
- printf("bsw8(%llx + %llx, %x) <- %llx\n", (u_int64_t)(h), \
- (u_int64_t)(o), \
- bus_stream_asi[(t)->type], (u_int64_t) v); \
+ printf("bsw8(%llx + %llx, %x) <- %llx\n", (long long)(h), \
+ (long long)(o), \
+ bus_stream_asi[(t)->type], (long long) v); \
((void)(stxa((h) + (o), bus_stream_asi[(t)->type], (v)))); })
#endif
/*
@@ -1047,32 +1047,32 @@ bus_space_copy_region_8(t, h1, o1, h2, o2, c)
* provided to bus space described by tag/handle/offset.
*/
-#define bus_space_write_multi_stream_1(t, h, o, a, c) do { \
+#define bus_space_write_multi_stream_1(t, h, o, a, c) do { \
int i = c; \
u_int8_t *p = (u_int8_t *)a; \
while (i-- > 0) \
- bus_space_write_stream_1(t, h, o, *p++); \
+ bus_space_write_stream_1(t, h, o, *p++); \
} while (0)
-#define bus_space_write_multi_stream_2(t, h, o, a, c) do { \
+#define bus_space_write_multi_stream_2(t, h, o, a, c) do { \
int i = c; \
u_int16_t *p = (u_int16_t *)a; \
while (i-- > 0) \
- bus_space_write_stream_2(t, h, o, *p++); \
+ bus_space_write_stream_2(t, h, o, *p++); \
} while (0)
-#define bus_space_write_multi_stream_4(t, h, o, a, c) do { \
+#define bus_space_write_multi_stream_4(t, h, o, a, c) do { \
int i = c; \
u_int32_t *p = (u_int32_t *)a; \
while (i-- > 0) \
- bus_space_write_stream_4(t, h, o, *p++); \
+ bus_space_write_stream_4(t, h, o, *p++); \
} while (0)
-#define bus_space_write_multi_stream_8(t, h, o, a, c) do { \
+#define bus_space_write_multi_stream_8(t, h, o, a, c) do { \
int i = c; \
u_int64_t *p = (u_int64_t *)a; \
while (i-- > 0) \
- bus_space_write_stream_8(t, h, o, *p++); \
+ bus_space_write_stream_8(t, h, o, *p++); \
} while (0)
/*
@@ -1084,28 +1084,28 @@ bus_space_copy_region_8(t, h1, o1, h2, o2, c)
* by tag/handle/offset `count' times.
*/
-#define bus_space_set_multi_stream_1(t, h, o, v, c) do { \
+#define bus_space_set_multi_stream_1(t, h, o, v, c) do { \
int i = c; \
while (i-- > 0) \
- bus_space_write_stream_1(t, h, o, v); \
+ bus_space_write_stream_1(t, h, o, v); \
} while (0)
-#define bus_space_set_multi_stream_2(t, h, o, v, c) do { \
+#define bus_space_set_multi_stream_2(t, h, o, v, c) do { \
int i = c; \
while (i-- > 0) \
- bus_space_write_stream_2(t, h, o, v); \
+ bus_space_write_stream_2(t, h, o, v); \
} while (0)
-#define bus_space_set_multi_stream_4(t, h, o, v, c) do { \
+#define bus_space_set_multi_stream_4(t, h, o, v, c) do { \
int i = c; \
while (i-- > 0) \
- bus_space_write_stream_4(t, h, o, v); \
+ bus_space_write_stream_4(t, h, o, v); \
} while (0)
-#define bus_space_set_multi_stream_8(t, h, o, v, c) do { \
+#define bus_space_set_multi_stream_8(t, h, o, v, c) do { \
int i = c; \
while (i-- > 0) \
- bus_space_write_stream_8(t, h, o, v); \
+ bus_space_write_stream_8(t, h, o, v); \
} while (0)
/*