summaryrefslogtreecommitdiff
path: root/sys/arch/mac68k/dev/if_sn.c
diff options
context:
space:
mode:
authorbriggs <briggs@cvs.openbsd.org>1996-09-21 03:34:56 +0000
committerbriggs <briggs@cvs.openbsd.org>1996-09-21 03:34:56 +0000
commit4425a3aa85bdd55a5459ba66b763531dc113c5c5 (patch)
tree9588254bad901413293e1723d2c7e933a88d9890 /sys/arch/mac68k/dev/if_sn.c
parent7d82fb366b13b065764f874ce876eba4cb546404 (diff)
Remove include of assert.h and fix a format error in debug camdump() code.
Diffstat (limited to 'sys/arch/mac68k/dev/if_sn.c')
-rw-r--r--sys/arch/mac68k/dev/if_sn.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/sys/arch/mac68k/dev/if_sn.c b/sys/arch/mac68k/dev/if_sn.c
index f86fbcde992..bdd88d64351 100644
--- a/sys/arch/mac68k/dev/if_sn.c
+++ b/sys/arch/mac68k/dev/if_sn.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sn.c,v 1.5 1996/05/26 18:35:25 briggs Exp $ */
+/* $OpenBSD: if_sn.c,v 1.6 1996/09/21 03:34:55 briggs Exp $ */
/*
* National Semiconductor SONIC Driver
@@ -131,7 +131,21 @@ struct cfdriver sn_cd = {
NULL, "sn", DV_IFNET
};
-#include <assert.h>
+#undef assert
+#undef _assert
+
+#ifdef NDEBUG
+#define assert(e) ((void)0)
+#define _assert(e) ((void)0)
+#else
+#define _assert(e) assert(e)
+#ifdef __STDC__
+#define assert(e) ((e) ? (void)0 : __assert(__FILE__, __LINE__, #e))
+#else /* PCC */
+#define assert(e) ((e) ? (void)0 : __assert(__FILE__, __LINE__, "e"))
+#endif
+#endif
+
void
__assert(file, line, failedexpr)
const char *file, *failedexpr;
@@ -841,7 +855,7 @@ camdump(sc)
ap0 = csr->s_cap0;
printf("%d: ap2=0x%x ap1=0x%x ap0=0x%x\n", i, ap2, ap1, ap0);
}
- printf("CAM enable 0x%x\n", csr->s_cep);
+ printf("CAM enable 0x%lx\n", csr->s_cep);
csr->s_cr = 0;
wbflush();