]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sys/amd64/linux32/linux32_dummy.c
MFV r336952: 9192 explicitly pass good_writes to vdev_uberblock/label_sync
[FreeBSD/FreeBSD.git] / sys / amd64 / linux32 / linux32_dummy.c
1 /*-
2  * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
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  * 2. Redistributions in binary form must reproduce the above copyright
13  *    notice, this list of conditions and the following disclaimer in the
14  *    documentation and/or other materials provided with the distribution.
15  *
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
17  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
20  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26  * SUCH DAMAGE.
27  */
28
29 #include <sys/cdefs.h>
30 __FBSDID("$FreeBSD$");
31
32 #include <sys/param.h>
33 #include <sys/kernel.h>
34 #include <sys/sdt.h>
35 #include <sys/systm.h>
36 #include <sys/proc.h>
37
38 #include <amd64/linux32/linux.h>
39 #include <amd64/linux32/linux32_proto.h>
40 #include <compat/linux/linux_dtrace.h>
41 #include <compat/linux/linux_util.h>
42
43 /* DTrace init */
44 LIN_SDT_PROVIDER_DECLARE(LINUX_DTRACE);
45
46 UNIMPLEMENTED(afs_syscall);
47 UNIMPLEMENTED(break);
48 UNIMPLEMENTED(create_module);   /* Added in Linux 1.0 removed in 2.6. */
49 UNIMPLEMENTED(ftime);
50 UNIMPLEMENTED(get_kernel_syms); /* Added in Linux 1.0 removed in 2.6. */
51 UNIMPLEMENTED(getpmsg);
52 UNIMPLEMENTED(gtty);
53 UNIMPLEMENTED(stty);
54 UNIMPLEMENTED(lock);
55 UNIMPLEMENTED(mpx);
56 UNIMPLEMENTED(nfsservctl);      /* Added in Linux 2.2 removed in 3.1. */
57 UNIMPLEMENTED(prof);
58 UNIMPLEMENTED(profil);
59 UNIMPLEMENTED(putpmsg);
60 UNIMPLEMENTED(query_module);    /* Added in Linux 2.2 removed in 2.6. */
61 UNIMPLEMENTED(ulimit);
62 UNIMPLEMENTED(vserver);
63
64 DUMMY(stime);
65 DUMMY(olduname);
66 DUMMY(syslog);
67 DUMMY(uname);
68 DUMMY(vhangup);
69 DUMMY(swapoff);
70 DUMMY(adjtimex);
71 DUMMY(init_module);
72 DUMMY(delete_module);
73 DUMMY(quotactl);
74 DUMMY(bdflush);
75 DUMMY(sysfs);
76 DUMMY(sendfile);
77 DUMMY(setfsuid);
78 DUMMY(setfsgid);
79 DUMMY(pivot_root);
80 DUMMY(ptrace);
81 DUMMY(lookup_dcookie);
82 DUMMY(remap_file_pages);
83 DUMMY(mbind);
84 DUMMY(get_mempolicy);
85 DUMMY(set_mempolicy);
86 DUMMY(mq_open);
87 DUMMY(mq_unlink);
88 DUMMY(mq_timedsend);
89 DUMMY(mq_timedreceive);
90 DUMMY(mq_notify);
91 DUMMY(mq_getsetattr);
92 DUMMY(kexec_load);
93 /* Linux 2.6.11: */
94 DUMMY(add_key);
95 DUMMY(request_key);
96 DUMMY(keyctl);
97 /* Linux 2.6.13: */
98 DUMMY(ioprio_set);
99 DUMMY(ioprio_get);
100 DUMMY(inotify_init);
101 DUMMY(inotify_add_watch);
102 DUMMY(inotify_rm_watch);
103 /* Linux 2.6.16: */
104 DUMMY(migrate_pages);
105 DUMMY(unshare);
106 /* Linux 2.6.17: */
107 DUMMY(splice);
108 DUMMY(sync_file_range);
109 DUMMY(tee);
110 DUMMY(vmsplice);
111 /* Linux 2.6.18: */
112 DUMMY(move_pages);
113 /* Linux 2.6.19: */
114 DUMMY(getcpu);
115 /* Linux 2.6.22: */
116 DUMMY(signalfd);
117 /* Linux 2.6.27: */
118 DUMMY(signalfd4);
119 DUMMY(inotify_init1);
120 /* Linux 2.6.31: */
121 DUMMY(perf_event_open);
122 /* Linux 2.6.33: */
123 DUMMY(fanotify_init);
124 DUMMY(fanotify_mark);
125 /* Linux 2.6.39: */
126 DUMMY(name_to_handle_at);
127 DUMMY(open_by_handle_at);
128 DUMMY(clock_adjtime);
129 /* Linux 3.0: */
130 DUMMY(setns);
131 /* Linux 3.2: */
132 DUMMY(process_vm_readv);
133 DUMMY(process_vm_writev);
134 /* Linux 3.5: */
135 DUMMY(kcmp);
136 /* Linux 3.8: */
137 DUMMY(finit_module);
138 DUMMY(sched_setattr);
139 DUMMY(sched_getattr);
140 /* Linux 3.14: */
141 DUMMY(renameat2);
142 /* Linux 3.15: */
143 DUMMY(seccomp);
144 DUMMY(memfd_create);
145 /* Linux 3.18: */
146 DUMMY(bpf);
147 /* Linux 3.19: */
148 DUMMY(execveat);
149 /* Linux 4.2: */
150 DUMMY(userfaultfd);
151 /* Linux 4.3: */
152 DUMMY(membarrier);
153 /* Linux 4.4: */
154 DUMMY(mlock2);
155 /* Linux 4.5: */
156 DUMMY(copy_file_range);
157 /* Linux 4.6: */
158 DUMMY(preadv2);
159 DUMMY(pwritev2);
160 /* Linux 4.8: */
161 DUMMY(pkey_mprotect);
162 DUMMY(pkey_alloc);
163 DUMMY(pkey_free);
164
165 #define DUMMY_XATTR(s)                                          \
166 int                                                             \
167 linux_ ## s ## xattr(                                           \
168     struct thread *td, struct linux_ ## s ## xattr_args *arg)   \
169 {                                                               \
170                                                                 \
171         return (ENOATTR);                                       \
172 }
173 DUMMY_XATTR(set);
174 DUMMY_XATTR(lset);
175 DUMMY_XATTR(fset);
176 DUMMY_XATTR(get);
177 DUMMY_XATTR(lget);
178 DUMMY_XATTR(fget);
179 DUMMY_XATTR(list);
180 DUMMY_XATTR(llist);
181 DUMMY_XATTR(flist);
182 DUMMY_XATTR(remove);
183 DUMMY_XATTR(lremove);
184 DUMMY_XATTR(fremove);