summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>2003-08-06 11:05:42 +0000
committerBruce Evans <bde@FreeBSD.org>2003-08-06 11:05:42 +0000
commit1c5fa550e8f82e480cd487758be243b90403af3e (patch)
tree37fed1ab1f7dac569a1e4e569877dfdc709ed06c
parentded45a40b0d1c07c572627602358262a2199d71a (diff)
Notes
-rw-r--r--sys/i386/isa/cxreg.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/sys/i386/isa/cxreg.h b/sys/i386/isa/cxreg.h
index c0206370551a..4102f2f8776f 100644
--- a/sys/i386/isa/cxreg.h
+++ b/sys/i386/isa/cxreg.h
@@ -428,3 +428,26 @@
#define CSRA_TXFLOFF 0x04 /* transmitter flow off */
#define CSRA_TXFLON 0x02 /* transmitter flow on */
#define CSRA_BITS "\20\2txflon\3txfloff\4txen\6rxflon\7rxfloff\10rxen"
+
+/*
+ * Hacks to avoid inb() and outb()'s checks that the port type is not
+ * pessimal.
+ */
+
+static __inline u_char
+xinb(u_int port)
+{
+ return (inb(port));
+}
+
+#undef inb
+#define inb(port) xinb(port)
+
+static __inline void
+xoutb(u_int port, u_char data)
+{
+ outb(port, data);
+}
+
+#undef outb
+#define outb(port, data) xoutb((port), (data))