summaryrefslogtreecommitdiff
path: root/sys/dev/pci/brooktree848.c
diff options
context:
space:
mode:
authorJason Wright <jason@cvs.openbsd.org>2001-01-31 22:39:46 +0000
committerJason Wright <jason@cvs.openbsd.org>2001-01-31 22:39:46 +0000
commita38d8533b3aa82f6262c91f32abc928a5f07c4aa (patch)
tree41a4e0e6536bc62976871cd488d78d7096f55a0d /sys/dev/pci/brooktree848.c
parent90ee86a428707f4f1f502ddab8da4100aa71e976 (diff)
based on art's sparc patch:
mmap should return -1 on failure, not EOPNOTSUPP. As it was now, an mmap of /dev/mem always returned page 45.
Diffstat (limited to 'sys/dev/pci/brooktree848.c')
-rw-r--r--sys/dev/pci/brooktree848.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/pci/brooktree848.c b/sys/dev/pci/brooktree848.c
index d6463808791..bfb0e1d65a0 100644
--- a/sys/dev/pci/brooktree848.c
+++ b/sys/dev/pci/brooktree848.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: brooktree848.c,v 1.17 2000/11/13 22:16:21 aaron Exp $ */
+/* $OpenBSD: brooktree848.c,v 1.18 2001/01/31 22:39:45 jason Exp $ */
/* $Roger: brooktree848.c,v 1.85 1999/06/12 14:54:54 roger Exp $ */
/* BT848 Driver for Brooktree's Bt848, Bt848A, Bt849A, Bt878, Bt879 based cards.
@@ -7354,7 +7354,7 @@ bktr_mmap( dev_t dev, vm_offset_t offset, int nprot )
bktr = (struct bktr_softc*)devclass_get_softc(bktr_devclass, unit);
if (bktr == NULL) {
/* the device is no longer valid/functioning */
- return (ENXIO);
+ return ( -1 );
}
if (nprot & PROT_EXEC)