diff options
Diffstat (limited to 'sys/arch/aviion/dev/vme.c')
-rw-r--r-- | sys/arch/aviion/dev/vme.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/arch/aviion/dev/vme.c b/sys/arch/aviion/dev/vme.c index 51af775adbc..90fc6b86e6f 100644 --- a/sys/arch/aviion/dev/vme.c +++ b/sys/arch/aviion/dev/vme.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vme.c,v 1.14 2014/07/12 18:44:41 tedu Exp $ */ +/* $OpenBSD: vme.c,v 1.15 2014/11/16 12:30:56 deraadt Exp $ */ /* * Copyright (c) 2006, 2007, 2010 Miodrag Vallat. * @@ -477,7 +477,7 @@ vme_map(struct vme_softc *sc, struct extent *ext, u_int awidth, /* * Allocate virtual memory for the range and map it. */ - rc = vme_map_r(r, pa, len, flags, UVM_PROT_RW, rva); + rc = vme_map_r(r, pa, len, flags, PROT_READ | PROT_WRITE, rva); if (rc != 0) { if (ext != NULL) (void)extent_free(ext, atop(pa), atop(len), @@ -948,7 +948,8 @@ vmerw(struct vme_softc *sc, int awidth, int dwidth, struct uio *uio, int flags) /* len = min(len, (off_t)r->vr_end - uio->uio_offset); */ rc = vme_map_r(r, trunc_page(uio->uio_offset), PAGE_SIZE, 0, - uio->uio_rw == UIO_READ ? UVM_PROT_R : UVM_PROT_RW, &vmepg); + uio->uio_rw == UIO_READ ? PROT_READ : PROT_READ | PROT_WRITE, + &vmepg); if (rc != 0) break; |