summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDale Rahn <drahn@cvs.openbsd.org>2003-04-25 18:30:19 +0000
committerDale Rahn <drahn@cvs.openbsd.org>2003-04-25 18:30:19 +0000
commit8841d81531b38e0ec365213db0159742de302e6a (patch)
tree347da186972c9f7b017672935e5023ef3390cb6d /lib
parenta5d055cd3e7192e8ab92e3d23f447d6e7e92855e (diff)
change mquery() function call signature to be the same a mmap(). It
needs the prot/flags info and passing the addresses via arg/return allows it to be traced via ktrace better than an in/out paramter. This adds a new mquery syscall and renames the old one to omquery. New kernel _MUST_ be built and installed before building ld.so with this change. ok millert@ tedu@
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/sys/mquery.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/libc/sys/mquery.c b/lib/libc/sys/mquery.c
index 2cb28e27a9b..92856a2c70a 100644
--- a/lib/libc/sys/mquery.c
+++ b/lib/libc/sys/mquery.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mquery.c,v 1.1 2003/04/14 04:53:50 art Exp $ */
+/* $OpenBSD: mquery.c,v 1.2 2003/04/25 18:30:18 drahn Exp $ */
/*
* Written by Artur Grabowski <art@openbsd.org> Public Domain
*/
@@ -10,8 +10,9 @@
/*
* This function provides 64-bit offset padding.
*/
-int
-mquery(int flags, void **addr, size_t size, int fd, off_t off)
+void *
+mquery(void *addr, size_t len, int prot, int flags, int fd, off_t offset)
{
- return(__syscall((quad_t)SYS_mquery, flags, addr, size, fd, off));
+ return((void *)(long)__syscall((quad_t)SYS_mquery, addr, len, prot,
+ flags, fd, 0, offset));
}