Home
last modified time | relevance | path

Searched refs:syscall (Results 1 – 195 of 195) sorted by relevance

/linux-4.4.14/arch/x86/um/shared/sysdep/
Dstub_32.h15 static inline long stub_syscall0(long syscall) in stub_syscall0() argument
19 __asm__ volatile ("int $0x80" : "=a" (ret) : "0" (syscall)); in stub_syscall0()
24 static inline long stub_syscall1(long syscall, long arg1) in stub_syscall1() argument
28 __asm__ volatile ("int $0x80" : "=a" (ret) : "0" (syscall), "b" (arg1)); in stub_syscall1()
33 static inline long stub_syscall2(long syscall, long arg1, long arg2) in stub_syscall2() argument
37 __asm__ volatile ("int $0x80" : "=a" (ret) : "0" (syscall), "b" (arg1), in stub_syscall2()
43 static inline long stub_syscall3(long syscall, long arg1, long arg2, long arg3) in stub_syscall3() argument
47 __asm__ volatile ("int $0x80" : "=a" (ret) : "0" (syscall), "b" (arg1), in stub_syscall3()
53 static inline long stub_syscall4(long syscall, long arg1, long arg2, long arg3, in stub_syscall4() argument
58 __asm__ volatile ("int $0x80" : "=a" (ret) : "0" (syscall), "b" (arg1), in stub_syscall4()
[all …]
Dstub_64.h18 static inline long stub_syscall0(long syscall) in stub_syscall0() argument
24 : "0" (syscall) : __syscall_clobber ); in stub_syscall0()
29 static inline long stub_syscall2(long syscall, long arg1, long arg2) in stub_syscall2() argument
35 : "0" (syscall), "D" (arg1), "S" (arg2) : __syscall_clobber ); in stub_syscall2()
40 static inline long stub_syscall3(long syscall, long arg1, long arg2, long arg3) in stub_syscall3() argument
46 : "0" (syscall), "D" (arg1), "S" (arg2), "d" (arg3) in stub_syscall3()
52 static inline long stub_syscall4(long syscall, long arg1, long arg2, long arg3, in stub_syscall4() argument
59 : "0" (syscall), "D" (arg1), "S" (arg2), "d" (arg3), in stub_syscall4()
66 static inline long stub_syscall5(long syscall, long arg1, long arg2, long arg3, in stub_syscall5() argument
73 : "0" (syscall), "D" (arg1), "S" (arg2), "d" (arg3), in stub_syscall5()
Dsyscalls_32.h13 #define EXECUTE_SYSCALL(syscall, regs) \ argument
15 (*sys_call_table[syscall]))(SYSCALL_ARGS(&regs->regs))
Dsyscalls_64.h17 #define EXECUTE_SYSCALL(syscall, regs) \ argument
19 (*sys_call_table[syscall]))(UPT_SYSCALL_ARG1(&regs->regs), \
Dptrace.h62 long syscall; member
68 #define UPT_SYSCALL_NR(r) ((r)->syscall)
/linux-4.4.14/arch/um/os-Linux/skas/
Dmem.c53 unsigned long * syscall; in do_syscall_stub() local
84 syscall = (unsigned long *)((unsigned long)data + data[0]); in do_syscall_stub()
87 syscall[0], ret, syscall[7]); in do_syscall_stub()
90 syscall[1], syscall[2], syscall[3], in do_syscall_stub()
91 syscall[4], syscall[5], syscall[6]); in do_syscall_stub()
110 long run_syscall_stub(struct mm_id * mm_idp, int syscall, in run_syscall_stub() argument
119 *stack++ = syscall; in run_syscall_stub()
/linux-4.4.14/samples/bpf/
Dlibbpf.c31 return syscall(__NR_bpf, BPF_MAP_CREATE, &attr, sizeof(attr)); in bpf_create_map()
43 return syscall(__NR_bpf, BPF_MAP_UPDATE_ELEM, &attr, sizeof(attr)); in bpf_update_elem()
54 return syscall(__NR_bpf, BPF_MAP_LOOKUP_ELEM, &attr, sizeof(attr)); in bpf_lookup_elem()
64 return syscall(__NR_bpf, BPF_MAP_DELETE_ELEM, &attr, sizeof(attr)); in bpf_delete_elem()
75 return syscall(__NR_bpf, BPF_MAP_GET_NEXT_KEY, &attr, sizeof(attr)); in bpf_get_next_key()
103 return syscall(__NR_bpf, BPF_PROG_LOAD, &attr, sizeof(attr)); in bpf_prog_load()
113 return syscall(__NR_bpf, BPF_OBJ_PIN, &attr, sizeof(attr)); in bpf_obj_pin()
122 return syscall(__NR_bpf, BPF_OBJ_GET, &attr, sizeof(attr)); in bpf_obj_get()
152 return syscall(__NR_perf_event_open, attr, pid, cpu, in perf_event_open()
/linux-4.4.14/arch/um/kernel/skas/
Dsyscall.c17 int syscall; in handle_syscall() local
24 syscall = get_syscall(r); in handle_syscall()
26 if ((syscall > __NR_syscall_max) || syscall < 0) in handle_syscall()
29 result = EXECUTE_SYSCALL(syscall, regs); in handle_syscall()
DMakefile6 obj-y := clone.o mmu.o process.o syscall.o uaccess.o
/linux-4.4.14/arch/arm/kernel/
Dentry-common.S38 ldr r1, [tsk, #TI_FLAGS] @ re-check for syscall tracing
64 ldr r1, [tsk, #TI_FLAGS] @ re-check for syscall tracing
202 adr tbl, sys_call_table @ load syscall table pointer
220 ldr r10, [tsk, #TI_FLAGS] @ check for syscall tracing
226 cmp scno, #NR_syscalls @ check upper syscall limit
234 mov why, #0 @ no longer a real syscall
263 mov scno, r0 @ syscall number (possibly new)
265 cmp scno, #NR_syscalls @ check upper syscall limit
269 cmp scno, #-1 @ skip the syscall?
300 #define OBSOLETE(syscall) sys_ni_syscall argument
[all …]
Dentry-header.S21 @ the addition of 8 bytes for storing syscall args 5 and 6.
380 scno .req r7 @ syscall number
381 tbl .req r8 @ syscall table pointer
382 why .req r8 @ Linux syscall (!= 0)
Dsignal.c502 static int do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
511 if (syscall) { in do_signal()
566 do_work_pending(struct pt_regs *regs, unsigned int thread_flags, int syscall) in do_work_pending() argument
582 int restart = do_signal(regs, syscall); in do_work_pending()
591 syscall = 0; in do_work_pending()
Dptrace.c857 task_thread_info(child)->syscall = data; in arch_ptrace()
926 current_thread_info()->syscall = -1; in tracehook_report_syscall()
933 current_thread_info()->syscall = scno; in syscall_trace_enter()
947 scno = current_thread_info()->syscall; in syscall_trace_enter()
/linux-4.4.14/tools/testing/selftests/powerpc/tm/
DMakefile1 TEST_PROGS := tm-resched-dscr tm-syscall
7 tm-syscall: tm-syscall-asm.S
8 tm-syscall: CFLAGS += -mhtm -I../../../../../usr/include
D.gitignore2 tm-syscall
/linux-4.4.14/samples/seccomp/
Dbpf-direct.c64 int syscall; in emulator() local
72 syscall = ctx->uc_mcontext.gregs[REG_SYSCALL]; in emulator()
76 if (syscall != __NR_write) in emulator()
171 syscall(__NR_write, STDOUT_FILENO, in main()
173 bytes = syscall(__NR_read, STDIN_FILENO, buf, sizeof(buf)); in main()
174 syscall(__NR_write, STDOUT_FILENO, payload("HELLO, ")); in main()
175 syscall(__NR_write, STDOUT_FILENO, buf, bytes); in main()
176 syscall(__NR_write, STDERR_FILENO, in main()
Dbpf-fancy.c96 syscall(__NR_write, STDOUT_FILENO, msg1, strlen(msg1)); in main()
97 bytes = syscall(__NR_read, STDIN_FILENO, buf, sizeof(buf)-1); in main()
99 syscall(__NR_write, STDERR_FILENO, msg2, strlen(msg2)); in main()
100 syscall(__NR_write, STDERR_FILENO, buf, bytes); in main()
102 syscall(__NR_write, STDERR_FILENO, msg2, strlen(msg2)+2); in main()
/linux-4.4.14/arch/powerpc/platforms/cell/
Dspu_callbacks.c55 long (*syscall)(u64 a1, u64 a2, u64 a3, u64 a4, u64 a5, u64 a6); in spu_sys_callback() local
62 syscall = spu_syscall_table[s->nr_ret]; in spu_sys_callback()
66 syscall, in spu_sys_callback()
71 return syscall(s->parm[0], s->parm[1], s->parm[2], in spu_sys_callback()
/linux-4.4.14/tools/testing/selftests/seccomp/
Dseccomp_bpf.c110 syscall(__NR_exit, 1); in TEST()
121 syscall(__NR_prctl, PR_SET_SECCOMP, SECCOMP_MODE_FILTER, in TEST_SIGNAL()
361 EXPECT_EQ(0, syscall(__NR_getpid)) { in TEST_SIGNAL()
383 EXPECT_EQ(0, syscall(__NR_getpid)) { in TEST_SIGNAL()
428 EXPECT_EQ(parent, syscall(__NR_getppid)); in TEST_SIGNAL()
430 EXPECT_EQ(0, syscall(__NR_getpid)); in TEST_SIGNAL()
463 EXPECT_EQ(parent, syscall(__NR_getppid)); in TEST_SIGNAL()
464 EXPECT_LE(clock, syscall(__NR_times, &timebuf)); in TEST_SIGNAL()
466 EXPECT_EQ(0, syscall(__NR_times, &fatal_address)); in TEST_SIGNAL()
508 EXPECT_EQ(parent, syscall(__NR_getppid)); in TEST_SIGNAL()
[all …]
/linux-4.4.14/arch/x86/entry/vsyscall/
Dvsyscall_emu_64.S22 syscall
27 syscall
32 syscall
/linux-4.4.14/arch/sh/kernel/vsyscall/
DMakefile1 obj-y += vsyscall.o vsyscall-syscall.o
3 $(obj)/vsyscall-syscall.o: \
24 $(call if_changed,syscall)
36 $(call if_changed,syscall)
/linux-4.4.14/arch/cris/kernel/
Dptrace.c46 void do_work_pending(int syscall, struct pt_regs *regs, in do_work_pending() argument
57 do_signal(syscall, regs); in do_work_pending()
58 syscall = 0; in do_work_pending()
/linux-4.4.14/arch/s390/kernel/
Daudit.c41 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
45 return s390_classify_syscall(syscall); in audit_classify_syscall()
47 switch(syscall) { in audit_classify_syscall()
Dcompat_audit.c30 int s390_classify_syscall(unsigned syscall) in s390_classify_syscall() argument
32 switch(syscall) { in s390_classify_syscall()
/linux-4.4.14/arch/sparc/kernel/
Daudit.c42 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
46 return sparc32_classify_syscall(syscall); in audit_classify_syscall()
48 switch(syscall) { in audit_classify_syscall()
Dcompat_audit.c30 int sparc32_classify_syscall(unsigned syscall) in sparc32_classify_syscall() argument
32 switch(syscall) { in sparc32_classify_syscall()
Dkernel.h62 int sparc32_classify_syscall(unsigned syscall);
/linux-4.4.14/arch/avr32/kernel/
Dsignal.c207 handle_signal(struct ksignal *ksig, struct pt_regs *regs, int syscall) in handle_signal() argument
232 static void do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
245 if (syscall) { in do_signal()
271 handle_signal(&ksig, regs, syscall); in do_signal()
276 int syscall = 0; in do_notify_resume() local
279 syscall = 1; in do_notify_resume()
282 do_signal(regs, syscall); in do_notify_resume()
DMakefile8 obj-y += syscall_table.o syscall-stubs.o irq.o
/linux-4.4.14/arch/metag/kernel/
Dsignal.c226 static int do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
238 if (syscall == __NR_rt_sigreturn) in do_signal()
239 syscall = -1; in do_signal()
242 if (syscall >= 0) { in do_signal()
305 int syscall) in do_work_pending() argument
315 int restart = do_signal(regs, syscall); in do_work_pending()
324 syscall = -1; in do_work_pending()
Dtraps.c312 TBIRES tail_end_sys(TBIRES State, int syscall, int *restart) in tail_end_sys() argument
322 do_work_pending(regs, flags, syscall)) { in tail_end_sys()
/linux-4.4.14/lib/
Daudit.c39 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
42 return audit_classify_compat_syscall(abi, syscall); in audit_classify_syscall()
44 switch(syscall) { in audit_classify_syscall()
Dcompat_audit.c30 int audit_classify_compat_syscall(int abi, unsigned syscall) in audit_classify_compat_syscall() argument
32 switch (syscall) { in audit_classify_compat_syscall()
DMakefile129 obj-$(CONFIG_HAVE_ARCH_TRACEHOOK) += syscall.o
/linux-4.4.14/Documentation/ABI/stable/
Dsyscalls1 What: The kernel syscall interface
9 documentation for details on the syscall numbers that are to be
10 mapped to each syscall.
/linux-4.4.14/arch/powerpc/kernel/
Daudit.c40 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
45 return ppc32_classify_syscall(syscall); in audit_classify_syscall()
47 switch(syscall) { in audit_classify_syscall()
Dcompat_audit.c29 int ppc32_classify_syscall(unsigned syscall) in ppc32_classify_syscall() argument
31 switch(syscall) { in ppc32_classify_syscall()
Dsignal_64.c568 static long setup_trampoline(unsigned int syscall, unsigned int __user *tramp) in setup_trampoline() argument
576 err |= __put_user(0x38000000UL | (syscall & 0xffff), &tramp[1]); in setup_trampoline()
/linux-4.4.14/arch/x86/kernel/
Daudit_64.c40 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
45 return ia32_classify_syscall(syscall); in audit_classify_syscall()
47 switch(syscall) { in audit_classify_syscall()
/linux-4.4.14/arch/parisc/kernel/
Daudit.c40 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
45 return parisc32_classify_syscall(syscall); in audit_classify_syscall()
47 switch (syscall) { in audit_classify_syscall()
Dcompat_audit.c28 int parisc32_classify_syscall(unsigned syscall) in parisc32_classify_syscall() argument
30 switch (syscall) { in parisc32_classify_syscall()
DMakefile8 pa7300lc.o syscall.o entry.o sys_parisc.o firmware.o \
/linux-4.4.14/arch/c6x/kernel/
Dentry.S121 ;; a syscall. It is cleared here, but the syscall handler
124 STW .D2T2 B1,*+SP(REGS__END+8) ; clear syscall flag
204 ;; Called before syscall handler when process is being debugged
218 ;; tracing returns (possibly new) syscall number
226 ;; reload syscall args from (possibly modified) stack frame
227 ;; and get syscall handler addr from sys_call_table:
240 BNOP .S2 B0,5 ; branch to syscall handler
322 ;; B0 = syscall number (in sys_call_table)
323 ;; A4,B4,A6,B6,A8,B8 = arguments of the syscall function
328 STW .D2T2 B2,*+SP(REGS__END+8) ; set syscall flag
[all …]
Dsignal.c239 int syscall) in handle_signal() argument
244 if (syscall) { in handle_signal()
273 static void do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
283 handle_signal(&ksig, regs, syscall); in do_signal()
288 if (syscall) { in do_signal()
316 int syscall) in do_notify_resume() argument
320 do_signal(regs, syscall); in do_notify_resume()
/linux-4.4.14/arch/x86/ia32/
Daudit.c28 int ia32_classify_syscall(unsigned syscall) in ia32_classify_syscall() argument
30 switch (syscall) { in ia32_classify_syscall()
/linux-4.4.14/arch/openrisc/kernel/
Dsignal.c231 int do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
239 if (syscall) { in do_signal()
297 do_work_pending(struct pt_regs *regs, unsigned int thread_flags, int syscall) in do_work_pending() argument
307 int restart = do_signal(regs, syscall); in do_work_pending()
316 syscall = 0; in do_work_pending()
/linux-4.4.14/arch/mips/kernel/
Dscall32-o32.S36 lw t1, PT_EPC(sp) # skip syscall on return
38 subu v0, v0, __NR_O32_Linux # check syscall number
42 sw a3, PT_R26(sp) # save a3 for syscall restarting
87 lw t0, TI_FLAGS($28) # syscall tracing enabled?
98 lw t2, (t1) # syscall routine
109 lw t1, PT_R2(sp) # syscall number
111 sw t1, PT_R0(sp) # save it for syscall restarting
134 bltz v0, 1f # seccomp failed? Skip syscall
136 move v0, s0 # restore syscall
188 subu t0, a0, __NR_O32_Linux # check syscall number
[all …]
Dscall64-o32.S34 ld t1, PT_EPC(sp) # skip syscall on return
36 dsubu t0, v0, __NR_O32_Linux # check syscall number
58 sd a3, PT_R26(sp) # save a3 for syscall restarting
86 LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
98 ld t1, PT_R2(sp) # syscall number
100 sd t1, PT_R0(sp) # save it for syscall restarting
115 move s0, t2 # Save syscall pointer
134 bltz v0, 1f # seccomp failed? Skip syscall
191 subu t0, a0, __NR_O32_Linux # check syscall number
196 ld t2, sys32_call_table(t1) # syscall routine
[all …]
Dscall64-n32.S35 dsubu t0, v0, __NR_N32_Linux # check syscall number
39 ld t1, PT_EPC(sp) # skip syscall on return
48 sd a3, PT_R26(sp) # save a3 for syscall restarting
51 LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
63 ld t1, PT_R2(sp) # syscall number
65 sd t1, PT_R0(sp) # save it for syscall restarting
79 bltz v0, 1f # seccomp failed? Skip syscall
Dscall64-64.S43 ld t1, PT_EPC(sp) # skip syscall on return
48 sd a3, PT_R26(sp) # save a3 for syscall restarting
51 LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
63 ld t2, (t0) # syscall routine
73 ld t1, PT_R2(sp) # syscall number
75 sd t1, PT_R0(sp) # save it for syscall restarting
90 bltz v0, 1f # seccomp failed? Skip syscall
Dptrace.c891 asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall) in syscall_trace_enter() argument
896 current_thread_info()->syscall = syscall; in syscall_trace_enter()
908 audit_syscall_entry(syscall, regs->regs[4], regs->regs[5], in syscall_trace_enter()
910 return syscall; in syscall_trace_enter()
Dentry.S147 # other than syscall tracing?
DMakefile9 syscall.o time.o topology.o traps.o unaligned.o watch.o \
/linux-4.4.14/tools/perf/Documentation/
Dperf-script-python.txt32 'syscall-counts' script you see when you list the available perf script
37 The syscall-counts script is a simple script, but demonstrates all the
39 of its output (syscall names are not yet supported, they will appear
43 syscall events:
73 Basically our task is to keep a per-syscall tally that gets updated
81 allowable by perf. These individual syscall events will however be
88 'id' field can be used to distinguish between individual syscall
91 For this script, we only need to know that a syscall was entered; we
102 The options basically say to collect data for every syscall event
192 # mv perf-script.py syscall-counts.py
[all …]
Dperf-bench.txt158 Use perf's cpu-cycles event instead of gettimeofday syscall.
182 Use perf's cpu-cycles event instead of gettimeofday syscall.
Dperf-trace.txt38 List of syscalls to show, currently only syscall names.
110 hooking the open syscall return + vfs_getname or via reading /proc/pid/fd, etc.
Dexamples.txt204 0.00 : 31a2e95607: 0f 05 syscall
/linux-4.4.14/arch/alpha/kernel/
Daudit.c36 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
38 switch(syscall) { in audit_classify_syscall()
/linux-4.4.14/arch/ia64/kernel/
Daudit.c36 int audit_classify_syscall(int abi, unsigned syscall) in audit_classify_syscall() argument
38 switch(syscall) { in audit_classify_syscall()
/linux-4.4.14/arch/mips/vdso/
Dsigreturn.S29 syscall
44 syscall
/linux-4.4.14/Documentation/mn10300/
DABI.txt141 A0 1st syscall argument Saved
142 D1 2nd syscall argument Saved
143 A3 3rd syscall argument Saved
144 A2 4th syscall argument Saved
145 D3 5th syscall argument Saved
146 D2 6th syscall argument Saved
/linux-4.4.14/tools/testing/selftests/x86/
Dldt_gdt.c119 int ret = syscall(SYS_modify_ldt, oldmode ? 1 : 0x11, in install_valid_mode()
152 int ret = syscall(SYS_modify_ldt, oldmode ? 1 : 0x11, in install_invalid()
174 int ret = syscall(SYS_modify_ldt, 0x11, ptr, bytecount); in safe_modify_ldt()
377 syscall(SYS_futex, &ftx, FUTEX_WAIT, 0, NULL, NULL, 0); in threadproc()
385 if (syscall(SYS_modify_ldt, 1, &desc, sizeof(desc)) != 0) in threadproc()
480 syscall(SYS_futex, &ftx, FUTEX_WAKE, 0, NULL, NULL, 0); in do_multicpu_tests()
500 syscall(SYS_futex, &ftx, FUTEX_WAKE, 0, NULL, NULL, 0); in do_multicpu_tests()
Dsingle_step_syscall.c161 syscall(SYS_getpid); /* Force symbol binding without TF set. */ in main()
164 syscall(SYS_getpid); in main()
Dunwind_vdso.c182 syscall(SYS_getpid); /* Force symbol binding without TF set. */ in main()
185 syscall(SYS_getpid, 1, 2, 3, 4, 5, 6); in main()
Dsyscall_nt.c46 syscall(SYS_getpid); in main()
Dsigreturn.c146 if (syscall(SYS_modify_ldt, 1, desc, sizeof(*desc)) == 0) { in add_ldt()
227 if (syscall(SYS_set_thread_area, &gdt_data16_desc) == 0) { in setup_ldt()
252 if (syscall(SYS_set_thread_area, &gdt_npdata32_desc) == 0) { in setup_ldt()
Dptrace_syscall.c176 syscall(SYS_gettid, 10, 11, 12, 13, 14, 15); in test_ptrace_syscall_restart()
/linux-4.4.14/arch/score/kernel/
Dentry.S312 # other than syscall tracing?
409 sw r4, [r0, PT_ORIG_R4] #for restart syscall
410 sw r7, [r0, PT_ORIG_R7] #for restart syscall
411 sw r27, [r0, PT_IS_SYSCALL] # it from syscall
413 lw r9, [r0, PT_EPC] # skip syscall on return
417 cmpi.c r27, __NR_syscalls # check syscall number
420 slli r8, r27, 2 # get syscall routine
423 lw r10, [r11] # get syscall entry
477 sw r4, [r0, PT_R0] # set flag for syscall
/linux-4.4.14/include/linux/
Daudit.h91 extern int audit_classify_syscall(int abi, unsigned syscall);
100 extern int audit_classify_compat_syscall(int abi, unsigned syscall);
143 extern void __audit_seccomp(unsigned long syscall, long signr, int code);
213 static inline void audit_seccomp(unsigned long syscall, long signr, int code) in audit_seccomp() argument
217 __audit_seccomp(syscall, signr, code); in audit_seccomp()
382 static inline void __audit_seccomp(unsigned long syscall, long signr, int code) in __audit_seccomp() argument
384 static inline void audit_seccomp(unsigned long syscall, long signr, int code) in audit_seccomp() argument
/linux-4.4.14/Documentation/prctl/
Dseccomp_filter.txt101 syscall was attempted. The program counter will be as though
102 the syscall happened (i.e. it will not point to the syscall
129 The tracer can skip the system call by changing the syscall number
131 requested by changing the system call to a valid syscall number. If
197 'syscall' instruction. Any code which wants to restart the call
199 trying to resume the syscall will again trigger the standard vsyscall
200 emulation security checks, making resuming the syscall mostly
204 but the syscall may not be changed to another system call using the
207 The rip value seen by the tracer will be the syscall entry address;
210 They might work. For example, on some kernels, choosing a syscall
/linux-4.4.14/kernel/trace/
Dtrace_syscalls.c80 find_syscall_meta(unsigned long syscall) in find_syscall_meta() argument
89 kallsyms_lookup(syscall, NULL, NULL, NULL, str); in find_syscall_meta()
118 int i, syscall; in print_syscall_enter() local
121 syscall = trace->nr; in print_syscall_enter()
122 entry = syscall_nr_to_meta(syscall); in print_syscall_enter()
163 int syscall; in print_syscall_exit() local
167 syscall = trace->nr; in print_syscall_exit()
168 entry = syscall_nr_to_meta(syscall); in print_syscall_exit()
DKconfig239 Basic tracer to catch the syscall entry and exit events.
507 bool "Run selftest on syscall events"
510 This option will also enable testing every syscall event.
/linux-4.4.14/tools/perf/tests/
DBuild6 perf-y += openat-syscall.o
7 perf-y += openat-syscall-all-cpus.o
8 perf-y += openat-syscall-tp-fields.o
Dmmap-thread-lookup.c42 td->tid = syscall(SYS_gettid); in thread_init()
/linux-4.4.14/tools/testing/selftests/ptrace/
Dpeeksiginfo.c16 return syscall(SYS_rt_sigqueueinfo, tgid, sig, uinfo); in sys_rt_sigqueueinfo()
22 return syscall(SYS_rt_tgsigqueueinfo, tgid, tid, sig, uinfo); in sys_rt_tgsigqueueinfo()
27 return syscall(SYS_ptrace, request, pid, addr, data); in sys_ptrace()
/linux-4.4.14/arch/xtensa/kernel/
Dsignal.c195 regs->syscall = -1; /* disable syscall checks */ in restore_sigcontext()
429 if ((signed)regs->syscall >= 0) { in do_signal()
446 regs->areg[2] = regs->syscall; in do_signal()
468 if ((signed) regs->syscall >= 0) { in do_signal()
474 regs->areg[2] = regs->syscall; in do_signal()
DMakefile8 ptrace.o setup.o signal.o stacktrace.o syscall.o time.o traps.o \
Dptrace.c233 tmp = regs->syscall; in ptrace_peekusr()
261 regs->syscall = val; in ptrace_pokeusr()
Dasm-offsets.c43 DEFINE(PT_SYSCALL, offsetof (struct pt_regs, syscall)); in main()
Dtraps.c445 regs->syscall); in show_regs()
Dentry.S975 rsr a0, depc # get syscall-nr
994 rsr a0, depc # get syscall-nr
/linux-4.4.14/arch/cris/arch-v32/kernel/
Dentry.S95 moveq 0, $r9 ; no syscall restarts, TYVM...
102 moveq 0, $r9 ; not a syscall
137 ;; In r9 we have the wanted syscall number. Arguments come in r10,r11,r12,
271 ;; We get here after doing a syscall if extra work might need to be done
272 ;; perform syscall exit tracing if needed.
304 ;; We get here as a sidetrack when we've entered a syscall with the
314 ;; Now re-enter the syscall code to do the syscall itself. We need to
315 ;; restore R9 here to contain the wanted syscall, and the other
/linux-4.4.14/arch/unicore32/kernel/
Dentry.S26 @ the addition of 8 bytes for storing syscall args 5 and 6.
75 add sp, sp, #\offset + S_R1 @ r0 is syscall return value
136 scno .req r21 @ syscall number
137 tbl .req r22 @ syscall table pointer
138 why .req r22 @ Linux syscall (!= 0)
618 ldw tbl, =sys_call_table @ load syscall table pointer
624 ldw ip, [tsk+], #TI_FLAGS @ check for syscall tracing
628 csub.a scno, #__NR_syscalls @ check upper syscall limit
634 2: mov why, #0 @ no longer a real syscall
648 mov scno, r0 @ syscall number (possibly new)
[all …]
Dptrace.c131 current_thread_info()->syscall = scno; in syscall_trace()
148 return current_thread_info()->syscall; in syscall_trace()
Dsignal.c305 int syscall) in handle_signal() argument
315 if (syscall) { in handle_signal()
357 static void do_signal(struct pt_regs *regs, int syscall) in do_signal() argument
371 handle_signal(&ksig, regs, syscall); in do_signal()
378 if (syscall) { in do_signal()
405 unsigned int thread_flags, int syscall) in do_notify_resume() argument
408 do_signal(regs, syscall); in do_notify_resume()
/linux-4.4.14/Documentation/x86/
Dentry_64.txt12 syscall entry points and thus provides for 32-bit processes the
19 - system_call: syscall instruction from 64-bit code.
21 - entry_INT80_compat: int 0x80 from 32-bit or 64-bit code; compat syscall
24 - entry_INT80_compat, ia32_sysenter: syscall and sysenter from 32-bit
39 have different calling conventions. The syscall and sysenter
Dintel_mpx.txt119 memory. Any direct kernel involvement (like a syscall) to access the
147 allocation syscall. This can be done for small, constrained applications.
/linux-4.4.14/arch/um/os-Linux/
Dstart_up.c261 int pid, syscall, n, status; in check_ptrace() local
283 syscall = ptrace(PTRACE_PEEKUSER, pid, PT_SYSCALL_NR_OFFSET, in check_ptrace()
285 if (syscall == __NR_getpid) { in check_ptrace()
Daio.c38 return syscall(__NR_io_setup, n, ctxp); in io_setup()
43 return syscall(__NR_io_submit, ctx, nr, iocbpp); in io_submit()
49 return syscall(__NR_io_getevents, ctx_id, min_nr, nr, events, timeout); in io_getevents()
Dprocess.c130 return syscall(__NR_getpid); in os_getpid()
/linux-4.4.14/arch/hexagon/kernel/
Dtraps.c361 syscall_fn syscall; in do_trap0() local
398 syscall = (syscall_fn) in do_trap0()
400 regs->r00 = syscall(regs->r00, regs->r01, in do_trap0()
/linux-4.4.14/tools/perf/scripts/python/bin/
Dsyscall-counts-report10 perf script $@ -s "$PERF_EXEC_PATH"/scripts/python/syscall-counts.py $comm
Dsyscall-counts-by-pid-report10 perf script $@ -s "$PERF_EXEC_PATH"/scripts/python/syscall-counts-by-pid.py $comm
/linux-4.4.14/kernel/bpf/
DMakefile3 obj-$(CONFIG_BPF_SYSCALL) += syscall.o verifier.o inode.o helpers.o
/linux-4.4.14/arch/x86/entry/vdso/
D.gitignore3 vdso32-syscall-syms.lds
/linux-4.4.14/Documentation/vm/
Dremap_file_pages.txt16 It's only known that one enterprise RDBMS implementation uses the syscall
21 The syscall is deprecated and replaced it with an emulation now. The
Duserfaultfd.txt14 Userfaults are delivered and resolved through the userfaultfd syscall.
36 The userfaultfd once opened by invoking the syscall, can also be
86 QEMU/KVM is using the userfaultfd syscall to implement postcopy live
/linux-4.4.14/tools/lib/lockdep/
Dcommon.c29 current_obj.pid = syscall(__NR_gettid); in __curr()
/linux-4.4.14/tools/testing/selftests/powerpc/syscalls/
Dipc_unmuxed.c28 rc = syscall(_num, -1, 0, 0, 0, 0, 0); \
/linux-4.4.14/ipc/
DMakefile6 obj-$(CONFIG_SYSVIPC) += util.o msgutil.o msg.o sem.o shm.o syscall.o
/linux-4.4.14/arch/metag/include/asm/
Dsyscalls.h37 int syscall);
/linux-4.4.14/arch/x86/um/
Dstub_64.S38 syscall
Dptrace_32.c112 child->thread.regs.regs.syscall = value; in putreg()
147 return child->thread.regs.regs.syscall; in getreg()
Dldt.c17 return syscall(__NR_modify_ldt, func, ptr, bytecount); in modify_ldt()
/linux-4.4.14/arch/x86/um/os-Linux/
Dtls.c31 if (syscall(__NR_get_thread_area, &info) == 0) { in check_host_supports_tls()
/linux-4.4.14/arch/um/kernel/
Dksyms.c46 EXPORT_SYMBOL(syscall);
DMakefile15 signal.o syscall.o sysrq.o time.o tlb.o trap.o \
/linux-4.4.14/arch/xtensa/include/asm/
Dptrace.h38 unsigned long syscall; /* 56 */ member
/linux-4.4.14/tools/perf/
Dperf-sys.h109 fd = syscall(__NR_perf_event_open, attr, pid, cpu, in sys_perf_event_open()
Dbuiltin-trace.c1307 struct syscall { struct
1408 struct syscall *table;
1660 static int syscall__set_arg_fmts(struct syscall *sc) in syscall__set_arg_fmts()
1686 struct syscall *sc; in trace__read_syscall_info()
1693 struct syscall *nsyscalls = realloc(trace->syscalls.table, (id + 1) * sizeof(*sc)); in trace__read_syscall_info()
1793 static size_t syscall__scnprintf_args(struct syscall *sc, char *bf, size_t size, in syscall__scnprintf_args()
1865 static struct syscall *trace__syscall_info(struct trace *trace, in trace__syscall_info()
1966 struct syscall *sc = trace__syscall_info(trace, evsel, id); in trace__sys_enter()
2024 struct syscall *sc = trace__syscall_info(trace, evsel, id); in trace__sys_exit()
2844 struct syscall *sc; in thread__dump_stats()
Ddesign.txt28 The syscall returns the new fd. The fd can be used via the normal
96 * parameter of the sys_perf_event_open() syscall:
/linux-4.4.14/arch/arm64/kernel/
Dsignal.c335 int syscall = (int)regs->syscallno; in do_signal() local
341 if (syscall >= 0) { in do_signal()
393 if (syscall >= 0 && regs->pc == restart_addr) { in do_signal()
Dentry.S37 .macro ct_user_exit, syscall = 0
40 .if \syscall == 1
/linux-4.4.14/arch/cris/arch-v10/kernel/
Dentry.S127 ;; In r9 we have the wanted syscall number. Arguments come in r10,r11,r12,r13,mof,srp
224 ;; We get here after doing a syscall if extra work might need to be done
225 ;; perform syscall exit tracing if needed
275 ;; We get here as a sidetrack when we've entered a syscall with the
284 ;; now re-enter the syscall code to do the syscall itself
285 ;; we need to restore $r9 here to contain the wanted syscall, and
/linux-4.4.14/Documentation/
Dadding-syscalls.txt56 (The syscall table is littered with historical examples where this wasn't done,
203 Some architectures (e.g. x86) have their own architecture-specific syscall
204 tables, but several other architectures share a generic syscall table. Add your
213 your new syscall number may get adjusted to resolve conflicts.
245 master syscall tables. Assuming your new system call isn't special in some
348 the entries in the syscall tables need to be adjusted.
399 arch/x86/entry/entry_64.S, and the entry in the syscall table
406 with the corresponding syscall table adjustment in
414 implementation is not common with the x86_64 version, then its syscall
419 still works -- its syscall table will reference stub_xyzzy, but the UML build
[all …]
Drobust-futexes.txt15 syscall is used to wait for the other guy to release it. The kernel
20 sys_futex(FUTEX_WAKE) syscall to wake them up. Once all waiters have
53 syscall variants to sys_futex(): FUTEX_REGISTER, FUTEX_DEREGISTER and
87 userspace list is registered with the kernel via a new syscall [this
179 for new threads, without the need of another syscall.]
182 and even for robust futex users, there is only one extra syscall per
Ddontdiff234 vdso32-syscall-syms.lds
Dstable_api_nonsense.txt10 the one that application programs use, the syscall interface. That
Dkernel-parameters.txt4055 native Vsyscalls are native syscall instructions.
/linux-4.4.14/tools/perf/bench/
Dfutex.h36 syscall(SYS_futex, uaddr, op | opflags, val, timeout, uaddr2, val3)
/linux-4.4.14/tools/testing/selftests/membarrier/
Dmembarrier_test.c18 return syscall(__NR_membarrier, cmd, flags); in sys_membarrier()
/linux-4.4.14/arch/m68k/kernel/
Dentry.S159 jcs syscall
200 | syscall trace?
205 syscall: label
/linux-4.4.14/arch/mn10300/kernel/
Dentry.S132 # is there any work to be done other than syscall tracing?
148 # perform syscall entry tracing
153 call syscall_trace_entry[],0 # returns the syscall number to actually use
164 # userspace resumption stub bypassing syscall exit tracing
/linux-4.4.14/arch/mips/include/asm/
Dsyscall.h32 return current_thread_info()->syscall; in syscall_get_nr()
Dthread_info.h37 long syscall; /* syscall number */ member
Dptrace.h164 extern asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall);
/linux-4.4.14/tools/testing/selftests/kcmp/
Dkcmp_test.c24 return syscall(__NR_kcmp, pid1, pid2, type, fd1, fd2); in sys_kcmp()
/linux-4.4.14/Documentation/zh_CN/arm64/
Dtagged-pointers.txt39 这意味着任何携带用户空间虚拟地址的系统调用(syscall
/linux-4.4.14/arch/
DKconfig198 # asm/syscall.h supplying asm-generic/syscall.h interface
336 - seccomp syscall wired up
347 to the syscall_xyz helpers for every syscall.
518 normal C parameter passing, rather than extracting the syscall
549 Architecture has old sigsuspend(2) syscall, of one-argument variety
559 Architecture has old sigaction(2) syscall. Nope, not the same
/linux-4.4.14/arch/arm/include/asm/
Dsyscall.h24 return task_thread_info(task)->syscall; in syscall_get_nr()
Dthread_info.h57 __u32 syscall; /* syscall number */ member
/linux-4.4.14/tools/lib/bpf/
Dbpf.c40 return syscall(__NR_bpf, cmd, attr, size); in sys_bpf()
/linux-4.4.14/arch/um/include/shared/
Dos.h258 int syscall, unsigned long *args, long expected,
313 long syscall(long number, ...);
/linux-4.4.14/arch/unicore32/include/asm/
Dthread_info.h75 __u32 syscall; /* syscall number */ member
/linux-4.4.14/Documentation/ko_KR/
Dstable_api_nonsense.txt31 인터페이스는 응용프로그램이 사용하는 syscall 인터페이스이다. 그 인터페이스는
/linux-4.4.14/drivers/pci/
DMakefile53 obj-$(CONFIG_PCI_SYSCALL) += syscall.o
/linux-4.4.14/tools/testing/selftests/powerpc/pmu/
Devent.c19 return syscall(__NR_perf_event_open, attr, pid, cpu, in perf_event_open()
/linux-4.4.14/Documentation/block/
Dioprio.txt91 return syscall(__NR_ioprio_set, which, who, ioprio);
96 return syscall(__NR_ioprio_get, which, who);
/linux-4.4.14/tools/testing/selftests/powerpc/mm/
Dsubpage_prot.c111 err = syscall(__NR_subpage_prot, addr, size, map); in run_test()
/linux-4.4.14/Documentation/arm64/
Dtagged-pointers.txt17 are tagged with tag 0x00. This means that any syscall
/linux-4.4.14/arch/xtensa/
DKconfig246 fast_syscall_xtensa is a syscall that can make atomic operations
249 This syscall is deprecated. It may have issues when called with
256 bool "Enable spill registers syscall"
259 fast_syscall_spill_registers is a syscall that spills all active
262 This syscall is deprecated. It may have issues when called with
/linux-4.4.14/tools/testing/selftests/futex/include/
Dfutextest.h75 syscall(SYS_futex, uaddr, op | opflags, val, timeout, uaddr2, val3)
/linux-4.4.14/arch/arc/kernel/
Dentry.S173 ; Tracing code now returns the syscall num (orig or modif)
184 ; have deliberately changed the syscall args: r0-r7
Dentry-compact.S174 ; -preemption off IRQ, user task in syscall picked to run
/linux-4.4.14/arch/m32r/kernel/
Dentry.S151 ; userspace resumption stub bypassing syscall exit tracing
/linux-4.4.14/tools/testing/selftests/memfd/
Dfuse_test.c41 return syscall(__NR_memfd_create, name, flags); in sys_memfd_create()
Dmemfd_test.c27 return syscall(__NR_memfd_create, name, flags); in sys_memfd_create()
/linux-4.4.14/arch/sh/kernel/
Dentry-common.S235 syscall_badsys: ! Bad syscall number
/linux-4.4.14/kernel/
Dauditfilter.c197 int audit_match_class(int class, unsigned syscall) in audit_match_class() argument
199 if (unlikely(syscall >= AUDIT_BITMASK_SIZE * 32)) in audit_match_class()
203 return classes[class][AUDIT_WORD(syscall)] & AUDIT_BIT(syscall); in audit_match_class()
Dseccomp.c497 static void seccomp_send_sigsys(int syscall, int reason) in seccomp_send_sigsys() argument
506 info.si_syscall = syscall; in seccomp_send_sigsys()
Daudit.h230 extern int audit_match_class(int class, unsigned syscall);
Dauditsc.c2406 void __audit_seccomp(unsigned long syscall, long signr, int code) in __audit_seccomp() argument
2415 signr, syscall_get_arch(), syscall, is_compat_task(), in __audit_seccomp()
/linux-4.4.14/tools/testing/selftests/net/
Dpsock_fanout.c125 pfd = syscall(__NR_bpf, BPF_PROG_LOAD, &attr, sizeof(attr)); in sock_fanout_set_ebpf()
/linux-4.4.14/Documentation/ABI/testing/
Dsysfs-bus-event_source-devices-events60 to the perf_open syscall.
Ddev-kmsg99 console, /proc/kmsg or the syslog() syscall.
/linux-4.4.14/arch/m32r/include/asm/
Dassembler.h151 addi r15, #4 ; Skip syscall number
/linux-4.4.14/Documentation/powerpc/
Dtransactional_memory.txt83 kernel does to perform the syscall may result in the transaction being doomed
84 by the hardware. The syscall is performed in suspended mode so any side
Dcxl.txt98 userspace by a read syscall documented below.
/linux-4.4.14/arch/frv/kernel/
Dentry.S1135 # perform syscall entry tracing
1149 # perform syscall exit tracing
/linux-4.4.14/fs/hostfs/
Dhostfs_user.c373 err = syscall(SYS_renameat2, AT_FDCWD, from, AT_FDCWD, to, flags); in rename2_file()
/linux-4.4.14/Documentation/ptp/
Dtestptp.c56 return syscall(__NR_clock_adjtime, id, tx); in clock_adjtime()
/linux-4.4.14/tools/testing/selftests/exec/
Dexecveat.c31 return syscall(__NR_execveat, fd, path, argv, envp, flags); in execveat_()
/linux-4.4.14/Documentation/networking/
Dnfc.txt114 NFC_SOCKPROTO_RAW socket and call the 'connect' syscall with the sockaddr_nfc
Dfilter.txt1103 The maps are accessed from user space via BPF syscall, which has commands:
1126 userspace programs use this syscall to create/access maps that eBPF programs
1285 Also trinity, the Linux syscall fuzzer, has built-in support for BPF and
Dcan.txt606 The CAN device MTU can be retrieved e.g. with a SIOCGIFMTU ioctl() syscall.
694 CAN interface unless the sendto() syscall is used to overrule the 'any' CAN
1187 The CAN device MTU can be retrieved e.g. with a SIOCGIFMTU ioctl() syscall.
/linux-4.4.14/Documentation/scheduler/
Dsched-deadline.txt542 #include <sys/syscall.h>
545 #define gettid() syscall(__NR_gettid)
549 /* XXX use the proper syscall numbers */
589 return syscall(__NR_sched_setattr, pid, attr, flags);
597 return syscall(__NR_sched_getattr, pid, attr, size, flags);
Dsched-nice-design.txt69 (the first one is the glibc API, the second one is the syscall API.)
/linux-4.4.14/arch/x86/entry/
Dentry_32.S249 # userspace resumption stub bypassing syscall exit tracing
933 movl $-1, PT_ORIG_EAX(%esp) # no syscall to restart
/linux-4.4.14/arch/sh/kernel/cpu/sh3/
Dentry.S250 add #4, r15 ! Skip syscall number
/linux-4.4.14/tools/testing/selftests/vm/
Duserfaultfd.c439 uffd = syscall(__NR_userfaultfd, O_CLOEXEC | O_NONBLOCK); in userfaultfd_stress()
Dmlock2-tests.c25 return syscall(__NR_mlock2, start, len, flags); in mlock2_()
/linux-4.4.14/drivers/uio/
DKconfig36 interrupts in the interrupt controller using the write() syscall.
/linux-4.4.14/arch/microblaze/kernel/
Dentry.S337 # do_syscall_trace_enter returns the new syscall nr.
371 # Find and jump into the syscall handler.
/linux-4.4.14/Documentation/ia64/
Dfsys.txt212 fsyscall-handler, at which point, by definition, a syscall
261 mov r15 = 1087 // gettimeofday syscall
/linux-4.4.14/Documentation/nfc/
Dnfc-hci.txt213 will be the syscall context. skb will return the result that was received in
235 The completion callback will then wake the syscall context.
/linux-4.4.14/Documentation/arm/
Dkernel_user_helpers.txt98 Get the TLS value as previously set via the __ARM_NR_set_tls syscall.
/linux-4.4.14/Documentation/sysctl/
Dkernel.txt358 A toggle indicating if the kexec_load syscall has been disabled. This
362 loaded before disabling the syscall, allowing a system to set up (and
810 Each write syscall must fully contain the sysctl value to be
820 fully contained in the buffer sent in the write syscall.
/linux-4.4.14/Documentation/early-userspace/
DREADME137 filesystem via linuxrc and use the pivot_root syscall. The initrd is
/linux-4.4.14/Documentation/security/
Dkeys-request-key.txt76 (1) Process A calls request_key() [the userspace syscall calls the kernel
Dkeys.txt454 The keyctl syscall functions are:
/linux-4.4.14/arch/tile/kernel/
Dintvec_32.S683 .ifc \kind,syscall
1199 check_single_stepping syscall, .Ldispatch_syscall
/linux-4.4.14/init/
DKconfig287 bool "uselib syscall"
290 This option enables the uselib syscall, a system call used in the
293 earlier, you may need to enable this syscall. Current systems
1370 This enables the legacy 16-bit UID syscall wrappers.
1397 bool "Sysfs syscall support" if EXPERT
1407 bool "Sysctl syscall support" if EXPERT
1549 # syscall, maps, verifier
/linux-4.4.14/Documentation/DocBook/
Dkernel-api.xml.db566 API---audit-syscall-entry
567 API---audit-syscall-exit
Ddevice-drivers.xml.db161 API-sys-restart-syscall
603 API-mptctl-syscall-down
/linux-4.4.14/Documentation/scsi/
Dadvansys.txt127 syscall(103, 7, 0, 0);
/linux-4.4.14/Documentation/filesystems/nfs/
Drpc-cache.txt172 (which propagates back to the write syscall) or 0.
/linux-4.4.14/Documentation/hid/
Duhid.txt41 If you want to handle multiple events in a single syscall, then use vectored
/linux-4.4.14/Documentation/filesystems/
DLocking156 by resolving the pathname passed to syscall.
293 ->writepages() is used for periodic writeback and for syscall-initiated
/linux-4.4.14/Documentation/filesystems/caching/
Dcachefiles.txt417 process issued the original syscall on the netfs.
/linux-4.4.14/Documentation/virtual/uml/
DUserModeLinux-HOWTO.txt2707 411 else res = EXECUTE_SYSCALL(syscall, regs);
3061 kernel_stack_page = 0, signal_stack = 1342627840, syscall = {id = 4, args = {
3073 The interesting things here are the fact that its .thread.syscall.id
3145 #17 0x1006d5b3 in execute_syscall (syscall=4, args=0x5006ef08)
3524 #9 0x1006d603 in execute_syscall (syscall=4, args=0x5006ef08)
/linux-4.4.14/Documentation/s390/
DDebugging390.txt1065 opcode and the second byte being the syscall number. They are traced using the
1070 TR SVC 5 ( as this is the syscall number of open )
1116 e.g. consider tracing an open syscall
/linux-4.4.14/arch/arm/
DKconfig1616 option also changes the kernel syscall calling convention to
1626 This option preserves the old syscall interface along with the
/linux-4.4.14/arch/x86/
DKconfig1773 bool "Verify kernel signature during kexec_file_load() syscall"
1777 the kexec_file_load() syscall.
/linux-4.4.14/
DCREDITS1275 D: prctl() syscall
DMAINTAINERS8587 F: include/asm-generic/syscall.h