linux_dummy.c revision 51569
1/*-
2 * Copyright (c) 1994-1995 S�ren Schmidt
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 *    notice, this list of conditions and the following disclaimer
10 *    in this position and unchanged.
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. The name of the author may not be used to endorse or promote products
15 *    derived from this software withough specific prior written permission
16 *
17 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 *
28 * $FreeBSD: head/sys/i386/linux/linux_dummy.c 51569 1999-09-22 22:01:51Z luoqi $
29 */
30
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/proc.h>
34
35#include <i386/linux/linux.h>
36#include <i386/linux/linux_proto.h>
37
38#define DUMMY(s) 							\
39int									\
40linux_ ## s(struct proc *p, struct linux_ ## s ## _args *args)		\
41{									\
42	return (unsupported_msg(p, #s));				\
43}									\
44struct __hack
45
46static int
47unsupported_msg(struct proc *p, const char *fname)
48{
49	printf("linux: syscall %s is obsoleted or not implemented (pid=%ld)\n",
50	       fname, (long)p->p_pid);
51	return (ENOSYS);
52}
53
54DUMMY(setup);
55DUMMY(break);
56DUMMY(stat);
57DUMMY(mount);
58DUMMY(umount);
59DUMMY(stime);
60DUMMY(ptrace);
61DUMMY(fstat);
62DUMMY(stty);
63DUMMY(gtty);
64DUMMY(ftime);
65DUMMY(prof);
66DUMMY(umount2);
67DUMMY(lock);
68DUMMY(mpx);
69DUMMY(ulimit);
70DUMMY(olduname);
71DUMMY(ustat);
72DUMMY(ksyslog);
73DUMMY(uname);
74DUMMY(vhangup);
75DUMMY(idle);
76DUMMY(vm86old);
77DUMMY(swapoff);
78DUMMY(sysinfo);
79DUMMY(adjtimex);
80DUMMY(create_module);
81DUMMY(init_module);
82DUMMY(delete_module);
83DUMMY(get_kernel_syms);
84DUMMY(quotactl);
85DUMMY(bdflush);
86DUMMY(sysfs);
87DUMMY(afs_syscall);
88DUMMY(setfsuid);
89DUMMY(setfsgid);
90DUMMY(getsid);
91DUMMY(fdatasync);
92DUMMY(sysctl);
93DUMMY(setresuid);
94DUMMY(getresuid);
95DUMMY(vm86);
96DUMMY(query_module);
97DUMMY(nfsservctl);
98DUMMY(setresgid);
99DUMMY(getresgid);
100DUMMY(prctl);
101DUMMY(rt_sigreturn);
102DUMMY(rt_sigpending);
103DUMMY(rt_sigtimedwait);
104DUMMY(rt_sigqueueinfo);
105DUMMY(rt_sigsuspend);
106DUMMY(pread);
107DUMMY(pwrite);
108DUMMY(capget);
109DUMMY(capset);
110DUMMY(sigaltstack);
111DUMMY(sendfile);
112DUMMY(getpmsg);
113DUMMY(putpmsg);
114