[BACK]Return to linux_dummy.c CVS log [TXT][DIR] Up to [local] / sys / compat / linux

Annotation of sys/compat/linux/linux_dummy.c, Revision 1.1.1.1

1.1       nbrk        1: /*     $OpenBSD: linux_dummy.c,v 1.16 2004/10/27 13:23:38 niklas Exp $ */
                      2:
                      3: /*-
                      4:  * Copyright (c) 1994-1995 Søren Schmidt
                      5:  * All rights reserved.
                      6:  *
                      7:  * Redistribution and use in source and binary forms, with or without
                      8:  * modification, are permitted provided that the following conditions
                      9:  * are met:
                     10:  * 1. Redistributions of source code must retain the above copyright
                     11:  *    notice, this list of conditions and the following disclaimer
                     12:  *    in this position and unchanged.
                     13:  * 2. Redistributions in binary form must reproduce the above copyright
                     14:  *    notice, this list of conditions and the following disclaimer in the
                     15:  *    documentation and/or other materials provided with the distribution.
                     16:  * 3. The name of the author may not be used to endorse or promote products
                     17:  *    derived from this software without specific prior written permission
                     18:  *
                     19:  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
                     20:  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
                     21:  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
                     22:  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
                     23:  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
                     24:  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
                     25:  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
                     26:  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
                     27:  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
                     28:  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
                     29:  *
                     30:  * $FreeBSD: src/sys/i386/linux/linux_dummy.c,v 1.21 2000/01/29 12:45:35 peter Exp $
                     31:  */
                     32:
                     33: #include <sys/param.h>
                     34: #include <sys/systm.h>
                     35: #include <sys/proc.h>
                     36:
                     37: #include <compat/linux/linux_types.h>
                     38: #include <compat/linux/linux_signal.h>
                     39: #include <compat/linux/linux_syscallargs.h>
                     40:
                     41: #define DUMMY(s)                                                       \
                     42: int                                                                    \
                     43: linux_sys_ ## s(p, v, retval)                                          \
                     44:        struct proc *p;                                                 \
                     45:        void *v;                                                        \
                     46:        register_t *retval;                                             \
                     47: {                                                                      \
                     48:        return (unsupported_msg(p, #s));                                \
                     49: }
                     50:
                     51: static int
                     52: unsupported_msg(struct proc *p, const char *fname)
                     53: {
                     54:        printf("linux: syscall %s is obsolete or not implemented (pid=%ld)\n",
                     55:            fname, (long)p->p_pid);
                     56:        return (ENOSYS);
                     57: }
                     58:
                     59: DUMMY(ostat);                  /* #18 */
                     60: #ifdef PTRACE
                     61: DUMMY(ptrace);                 /* #26 */
                     62: #endif
                     63: DUMMY(ofstat);                 /* #28 */
                     64: DUMMY(stty);                   /* #31 */
                     65: DUMMY(gtty);                   /* #32 */
                     66: DUMMY(ftime);                  /* #35 */
                     67: DUMMY(prof);                   /* #44 */
                     68: DUMMY(phys);                   /* #52 */
                     69: DUMMY(lock);                   /* #53 */
                     70: DUMMY(mpx);                    /* #56 */
                     71: DUMMY(ulimit);                 /* #58 */
                     72: DUMMY(ustat);                  /* #62 */
                     73: #ifndef __i386__
                     74: DUMMY(ioperm);                 /* #101 */
                     75: #endif
                     76: DUMMY(klog);                   /* #103 */
                     77: #ifndef __i386__
                     78: DUMMY(iopl);                   /* #110 */
                     79: #endif
                     80: DUMMY(vhangup);                        /* #111 */
                     81: DUMMY(idle);                   /* #112 */
                     82: DUMMY(vm86old);                        /* #113 */
                     83: DUMMY(swapoff);                        /* #115 */
                     84: #ifndef __i386__
                     85: DUMMY(modify_ldt);             /* #123 */
                     86: #endif
                     87: DUMMY(adjtimex);               /* #124 */
                     88: DUMMY(create_module);          /* #127 */
                     89: DUMMY(init_module);            /* #128 */
                     90: DUMMY(delete_module);          /* #129 */
                     91: DUMMY(get_kernel_syms);                /* #130 */
                     92: DUMMY(quotactl);               /* #131 */
                     93: DUMMY(bdflush);                        /* #134 */
                     94: DUMMY(sysfs);                  /* #135 */
                     95: DUMMY(afs_syscall);            /* #137 */
                     96: DUMMY(mlockall);               /* #152 */
                     97: DUMMY(munlockall);             /* #153 */
                     98: DUMMY(sched_rr_get_interval);  /* #161 */
                     99: DUMMY(vm86);                   /* #166 */
                    100: DUMMY(query_module);           /* #167 */
                    101: DUMMY(nfsservctl);             /* #169 */
                    102: DUMMY(prctl);                  /* #172 */
                    103: DUMMY(rt_sigtimedwait);                /* #177 */
                    104: DUMMY(rt_queueinfo);           /* #178 */
                    105: DUMMY(capget);                 /* #184 */
                    106: DUMMY(capset);                 /* #185 */
                    107: DUMMY(sendfile);               /* #187 */
                    108: DUMMY(getpmsg);                        /* #188 */
                    109: DUMMY(putpmsg);                        /* #189 */
                    110: DUMMY(lchown);                 /* #198 */
                    111: DUMMY(fchown);                 /* #207 */
                    112: DUMMY(chown);                  /* #212 */
                    113: DUMMY(setfsgid);               /* #216 */
                    114: DUMMY(pivot_root);             /* #217 */
                    115: DUMMY(mincore);                        /* #218 */
                    116: DUMMY(fadvise64);              /* #250 */
                    117:
                    118: #define DUMMY_XATTR(s)                                                 \
                    119: int                                                                    \
                    120: linux_sys_ ## s ## xattr(p, v, retval)                                         \
                    121:        struct proc *p;                                                 \
                    122:        void *v;                                                        \
                    123:        register_t *retval;                                             \
                    124: {                                                                      \
                    125:        return (ENOATTR);                                               \
                    126: }
                    127: DUMMY_XATTR(set);
                    128: DUMMY_XATTR(lset);
                    129: DUMMY_XATTR(fset);
                    130: DUMMY_XATTR(get);
                    131: DUMMY_XATTR(lget);
                    132: DUMMY_XATTR(fget);
                    133: DUMMY_XATTR(list);
                    134: DUMMY_XATTR(llist);
                    135: DUMMY_XATTR(flist);
                    136: DUMMY_XATTR(remove);
                    137: DUMMY_XATTR(lremove);
                    138: DUMMY_XATTR(fremove);

CVSweb