1 /* $NetBSD: linux32_missing.h,v 1.1 2006/02/09 19:18:57 manu Exp $ */ 2 3 /*- 4 * Copyright (c) 2006 Emmanuel Dreyfus, all rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: 9 * 1. Redistributions of source code must retain the above copyright 10 * notice, this list of conditions and the following disclaimer. 11 * 2. Redistributions in binary form must reproduce the above copyright 12 * notice, this list of conditions and the following disclaimer in the 13 * documentation and/or other materials provided with the distribution. 14 * 3. All advertising materials mentioning features or use of this software 15 * must display the following acknowledgement: 16 * This product includes software developed by Emmanuel Dreyfus 17 * 4. The name of the author may not be used to endorse or promote 18 * products derived from this software without specific prior written 19 * permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE THE AUTHOR AND CONTRIBUTORS ``AS IS'' 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 23 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 24 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 31 * POSSIBILITY OF SUCH DAMAGE. 32 */ 33 #ifndef _I386_LINUX32_MISSING_H 34 #define _I386_LINUX32_MISSING_H 35 36 /* 37 * system calls not defined for COMPAT_LINUX/amd64 38 * but needed for COMPAT_LINUX32 39 */ 40 struct linux_sys_old_mmap_args { 41 syscallarg(struct linux_oldmmap *) lmp; 42 }; 43 struct linux_sys_ugetrlimit_args { 44 syscallarg(int) which; 45 syscallarg(struct orlimit *) rlp; 46 }; 47 struct linux_sys_fcntl64_args { 48 syscallarg(int) fd; 49 syscallarg(int) cmd; 50 syscallarg(void *) arg; 51 }; 52 struct linux_sys_llseek_args { 53 syscallarg(int) fd; 54 syscallarg(u_int32_t) ohigh; 55 syscallarg(u_int32_t) olow; 56 syscallarg(caddr_t) res; 57 syscallarg(int) whence; 58 }; 59 60 struct linux_sys_setresgid16_args { 61 syscallarg(gid_t) rgid; 62 syscallarg(gid_t) egid; 63 syscallarg(gid_t) sgid; 64 }; 65 66 struct linux_sys_setresuid16_args { 67 syscallarg(uid_t) ruid; 68 syscallarg(uid_t) euid; 69 syscallarg(uid_t) suid; 70 }; 71 72 struct linux_sys_nice_args { 73 syscallarg(int) incr; 74 }; 75 76 struct linux_sys_getgroups16_args { 77 syscallarg(int) gidsetsize; 78 syscallarg(linux32_gid_t *) gidset; 79 }; 80 81 struct linux_sys_setgroups16_args { 82 syscallarg(int) gidsetsize; 83 syscallarg(linux32_gid_t *) gidset; 84 }; 85 86 #ifdef _KERNEL 87 __BEGIN_DECLS 88 int linux_sys_old_mmap(struct lwp *, void *, register_t *); 89 int linux_sys_ugetrlimit(struct lwp *, void *, register_t *); 90 int linux_sys_fcntl64(struct lwp *, void *, register_t *); 91 int linux_sys_llseek(struct lwp *, void *, register_t *); 92 int linux_sys_setresuid16(struct lwp *, void *, register_t *); 93 int linux_sys_setresgid16(struct lwp *, void *, register_t *); 94 int linux_sys_nice(struct lwp *, void *, register_t *); 95 int linux_sys_getgroups16(struct lwp *, void *, register_t *); 96 int linux_sys_setgroups16(struct lwp *, void *, register_t *); 97 __END_DECLS 98 #endif /* !_KERNEL */ 99 100 #endif /* _I386_LINUX32_MISSING_H */ 101