summaryrefslogtreecommitdiff
path: root/sys/dev/isa
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2014-11-16 12:31:02 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2014-11-16 12:31:02 +0000
commit84110ac1ecd0b90236884f584c62f0aba5630fc2 (patch)
treefad09b733c1e1122314b073b82f6d36a1024e050 /sys/dev/isa
parentcbbf1bf46622bbdb478ef4df4e4e027e0b83fc62 (diff)
Replace a plethora of historical protection options with just
PROT_NONE, PROT_READ, PROT_WRITE, and PROT_EXEC from mman.h. PROT_MASK is introduced as the one true way of extracting those bits. Remove UVM_ADV_* wrapper, using the standard names. ok doug guenther kettenis
Diffstat (limited to 'sys/dev/isa')
-rw-r--r--sys/dev/isa/aha.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/isa/aha.c b/sys/dev/isa/aha.c
index 3b142cbaa37..a2e3e6f1e8a 100644
--- a/sys/dev/isa/aha.c
+++ b/sys/dev/isa/aha.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aha.c,v 1.77 2014/09/14 14:17:25 jsg Exp $ */
+/* $OpenBSD: aha.c,v 1.78 2014/11/16 12:31:00 deraadt Exp $ */
/* $NetBSD: aha.c,v 1.11 1996/05/12 23:51:23 mycroft Exp $ */
#undef AHADIAG
@@ -1079,15 +1079,15 @@ aha_init(sc)
TAILQ_INIT(&pglist);
if (uvm_pglistalloc(size, 0, 0xffffff, PAGE_SIZE, 0, &pglist, 1,
UVM_PLA_NOWAIT) || uvm_map(kernel_map, &va, size, NULL,
- UVM_UNKNOWN_OFFSET, 0, UVM_MAPFLAG(UVM_PROT_ALL, UVM_PROT_ALL,
- UVM_INH_NONE, UVM_ADV_RANDOM, 0)))
+ UVM_UNKNOWN_OFFSET, 0, UVM_MAPFLAG(PROT_MASK, PROT_MASK,
+ UVM_INH_NONE, POSIX_MADV_RANDOM, 0)))
panic("aha_init: could not allocate mailbox");
wmbx = (struct aha_mbx *)va;
for (pg = TAILQ_FIRST(&pglist); pg != NULL;
pg = TAILQ_NEXT(pg, pageq)) {
pmap_kenter_pa(va, VM_PAGE_TO_PHYS(pg),
- VM_PROT_READ|VM_PROT_WRITE);
+ PROT_READ | PROT_WRITE);
va += PAGE_SIZE;
}
pmap_update(pmap_kernel());