blob: 720af782e19ea49f1a29e9ceb3f55352821cdd4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
$NetBSD: patch-aj,v 1.1 2001/03/16 13:59:54 wiz Exp $
--- port.c.orig Wed Apr 10 12:52:15 1996
+++ port.c
@@ -63,7 +63,7 @@
goto bad;
}
while (cnt--) {
- ioports[port/32] |= (1 << (port%32));
+ ioports[port/32] &= ~(1 << (port%32));
port++;
}
if (i386_set_ioperm(ioports) < 0) {
@@ -82,7 +82,7 @@
goto bad;
}
while (cnt--) {
- ioports[port/32] &= ~(1 << (port%32));
+ ioports[port/32] |= (1 << (port%32));
port++;
}
if (i386_set_ioperm(ioports) < 0) {
@@ -169,6 +169,10 @@
portsw[i].p_inb = inb_nullport;
if (portsw[i].p_outb == 0)
portsw[i].p_outb = outb_nullport;
+ }
+
+ for (i = 0; i < MAXPORT/32; i++) {
+ ioports[i] = 0xffffffff;
}
}
|