1 /*
2 * Copyright (C) 2023 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 #include "runtime_bridge.h"
18
19 #include <cstdlib>
20
21 #include "berberis/base/checks.h"
22
23 namespace berberis {
24
RunGuestSyscall___NR_rt_sigaction(long,long,long,long)25 long RunGuestSyscall___NR_rt_sigaction(long, long, long, long) {
26 FATAL("unimplemented syscall rt_sigaction");
27 return -1;
28 }
29
RunGuestSyscall___NR_sigaltstack(long,long)30 long RunGuestSyscall___NR_sigaltstack(long, long) {
31 FATAL("unimplemented syscall sigaltstack");
32 return -1;
33 }
34
RunGuestSyscall___NR_timer_create(long,long,long)35 long RunGuestSyscall___NR_timer_create(long, long, long) {
36 FATAL("unimplemented syscall create");
37 return -1;
38 }
39
RunGuestSyscall___NR_exit(long code)40 long RunGuestSyscall___NR_exit(long code) {
41 _exit(code);
42 return 0;
43 }
44
RunGuestSyscall___NR_clone(long,long,long,long,long)45 long RunGuestSyscall___NR_clone(long, long, long, long, long) {
46 FATAL("unimplemented syscall clone");
47 return -1;
48 }
49
RunGuestSyscall___NR_mmap(long,long,long,long,long,long)50 long RunGuestSyscall___NR_mmap(long, long, long, long, long, long) {
51 FATAL("unimplemented syscall mmap");
52 return -1;
53 }
54
RunGuestSyscall___NR_mmap2(long,long,long,long,long,long)55 long RunGuestSyscall___NR_mmap2(long, long, long, long, long, long) {
56 FATAL("unimplemented syscall mmap2");
57 return -1;
58 }
59
RunGuestSyscall___NR_munmap(long,long)60 long RunGuestSyscall___NR_munmap(long, long) {
61 FATAL("unimplemented syscall munmap");
62 return -1;
63 }
64
RunGuestSyscall___NR_mprotect(long,long,long)65 long RunGuestSyscall___NR_mprotect(long, long, long) {
66 FATAL("unimplemented syscall mprotect");
67 return -1;
68 }
69
RunGuestSyscall___NR_mremap(long,long,long,long,long)70 long RunGuestSyscall___NR_mremap(long, long, long, long, long) {
71 FATAL("unimplemented syscall mremap");
72 return -1;
73 }
74
75 } // namespace berberis
76