Home
last modified time | relevance | path

Searched refs:pid (Results 1 – 25 of 225) sorted by relevance

123456789

/arch/x86/um/os-Linux/
Dregisters.c21 int save_i387_registers(int pid, unsigned long *fp_regs) in save_i387_registers() argument
23 if (ptrace(PTRACE_GETFPREGS, pid, 0, fp_regs) < 0) in save_i387_registers()
28 int save_fp_registers(int pid, unsigned long *fp_regs) in save_fp_registers() argument
36 if (ptrace(PTRACE_GETREGSET, pid, NT_X86_XSTATE, &iov) < 0) in save_fp_registers()
41 return save_i387_registers(pid, fp_regs); in save_fp_registers()
44 int restore_i387_registers(int pid, unsigned long *fp_regs) in restore_i387_registers() argument
46 if (ptrace(PTRACE_SETFPREGS, pid, 0, fp_regs) < 0) in restore_i387_registers()
51 int restore_fp_registers(int pid, unsigned long *fp_regs) in restore_fp_registers() argument
58 if (ptrace(PTRACE_SETREGSET, pid, NT_X86_XSTATE, &iov) < 0) in restore_fp_registers()
63 return restore_i387_registers(pid, fp_regs); in restore_fp_registers()
[all …]
Dtls.c48 int os_set_thread_area(user_desc_t *info, int pid) in os_set_thread_area() argument
52 ret = ptrace(PTRACE_SET_THREAD_AREA, pid, info->entry_number, in os_set_thread_area()
59 int os_get_thread_area(user_desc_t *info, int pid) in os_get_thread_area() argument
63 ret = ptrace(PTRACE_GET_THREAD_AREA, pid, info->entry_number, in os_get_thread_area()
/arch/powerpc/mm/
Dtlb-radix.c26 static inline void __tlbie_va(unsigned long va, unsigned long pid, in __tlbie_va() argument
33 rs = pid << PPC_BITLSHIFT(31); in __tlbie_va()
43 static inline void fixup_tlbie_va(unsigned long va, unsigned long pid, in fixup_tlbie_va() argument
53 __tlbie_va(va, pid, ap, RIC_FLUSH_TLB); in fixup_tlbie_va()
57 static inline void __tlbiel_pid(unsigned long pid, int set, in __tlbiel_pid() argument
64 rs = ((unsigned long)pid) << PPC_BITLSHIFT(31); in __tlbiel_pid()
76 static inline void _tlbiel_pid(unsigned long pid, unsigned long ric) in _tlbiel_pid() argument
86 __tlbiel_pid(pid, 0, ric); in _tlbiel_pid()
96 __tlbiel_pid(pid, set, RIC_FLUSH_TLB); in _tlbiel_pid()
102 static inline void __tlbie_pid(unsigned long pid, unsigned long ric) in __tlbie_pid() argument
[all …]
Dmmu_decl.h35 static inline void _tlbil_pid(unsigned int pid) in _tlbil_pid() argument
39 #define _tlbil_pid_noind(pid) _tlbil_pid(pid) argument
43 extern void _tlbil_pid(unsigned int pid);
45 extern void _tlbil_pid_noind(unsigned int pid);
47 #define _tlbil_pid_noind(pid) _tlbil_pid(pid) argument
55 static inline void _tlbil_va(unsigned long address, unsigned int pid, in _tlbil_va() argument
61 extern void _tlbil_va(unsigned long address, unsigned int pid,
64 extern void __tlbil_va(unsigned long address, unsigned int pid);
65 static inline void _tlbil_va(unsigned long address, unsigned int pid, in _tlbil_va() argument
68 __tlbil_va(address, pid); in _tlbil_va()
[all …]
Dtlb_nohash.c201 unsigned int pid; in local_flush_tlb_mm() local
204 pid = mm->context.id; in local_flush_tlb_mm()
205 if (pid != MMU_NO_CONTEXT) in local_flush_tlb_mm()
206 _tlbil_pid(pid); in local_flush_tlb_mm()
214 unsigned int pid; in __local_flush_tlb_page() local
217 pid = mm ? mm->context.id : 0; in __local_flush_tlb_page()
218 if (pid != MMU_NO_CONTEXT) in __local_flush_tlb_page()
219 _tlbil_va(vmaddr, pid, tsize, ind); in __local_flush_tlb_page()
239 unsigned int pid; member
248 _tlbil_pid(p ? p->pid : 0); in do_flush_tlb_mm_ipi()
[all …]
/arch/um/os-Linux/
Dstart_up.c32 int pid = os_getpid(), ppid = getppid(); in ptrace_child() local
38 kill(pid, SIGKILL); in ptrace_child()
40 kill(pid, SIGSTOP); in ptrace_child()
48 if (sc_result == pid) in ptrace_child()
95 int pid, n, status; in start_ptraced_child() local
99 pid = fork(); in start_ptraced_child()
100 if (pid == 0) in start_ptraced_child()
102 else if (pid < 0) in start_ptraced_child()
105 CATCH_EINTR(n = waitpid(pid, &status, WUNTRACED)); in start_ptraced_child()
112 return pid; in start_ptraced_child()
[all …]
Dhelper.c46 int pid, fds[2], ret, n; in run_helper() local
74 pid = clone(helper_child, (void *) sp, CLONE_VM, &data); in run_helper()
75 if (pid < 0) { in run_helper()
91 ret = pid; in run_helper()
99 CATCH_EINTR(waitpid(pid, NULL, __WALL)); in run_helper()
117 int pid, status, err; in run_helper_thread() local
124 pid = clone(proc, (void *) sp, flags, arg); in run_helper_thread()
125 if (pid < 0) { in run_helper_thread()
132 CATCH_EINTR(pid = waitpid(pid, &status, __WALL)); in run_helper_thread()
133 if (pid < 0) { in run_helper_thread()
[all …]
Dregisters.c14 int save_registers(int pid, struct uml_pt_regs *regs) in save_registers() argument
18 err = ptrace(PTRACE_GETREGS, pid, 0, regs->gp); in save_registers()
24 int restore_registers(int pid, struct uml_pt_regs *regs) in restore_registers() argument
28 err = ptrace(PTRACE_SETREGS, pid, 0, regs->gp); in restore_registers()
39 int init_registers(int pid) in init_registers() argument
43 err = ptrace(PTRACE_GETREGS, pid, 0, exec_regs); in init_registers()
47 arch_init_registers(pid); in init_registers()
48 get_fp_registers(pid, exec_fp_regs); in init_registers()
Dprocess.c27 unsigned long os_process_pc(int pid) in os_process_pc() argument
33 sprintf(proc_stat, "/proc/%d/stat", pid); in os_process_pc()
59 int os_process_parent(int pid) in os_process_parent() argument
65 if (pid == -1) in os_process_parent()
68 snprintf(stat, sizeof(stat), "/proc/%d/stat", pid); in os_process_parent()
93 void os_alarm_process(int pid) in os_alarm_process() argument
95 kill(pid, SIGALRM); in os_alarm_process()
98 void os_stop_process(int pid) in os_stop_process() argument
100 kill(pid, SIGSTOP); in os_stop_process()
103 void os_kill_process(int pid, int reap_child) in os_kill_process() argument
[all …]
Dumid.c139 char pid[sizeof("nnnnn\0")], *end; in is_umdir_used() local
161 n = read(fd, pid, sizeof(pid)); in is_umdir_used()
172 p = strtoul(pid, &end, 0); in is_umdir_used()
173 if (end == pid) { in is_umdir_used()
214 char pid[sizeof("nnnnn\0")]; in create_pid_file() local
227 snprintf(pid, sizeof(pid), "%d\n", getpid()); in create_pid_file()
228 n = write(fd, pid, strlen(pid)); in create_pid_file()
229 if (n != strlen(pid)) in create_pid_file()
/arch/um/include/shared/
Dregisters.h12 extern int save_i387_registers(int pid, unsigned long *fp_regs);
13 extern int restore_i387_registers(int pid, unsigned long *fp_regs);
14 extern int save_fp_registers(int pid, unsigned long *fp_regs);
15 extern int restore_fp_registers(int pid, unsigned long *fp_regs);
16 extern int save_fpx_registers(int pid, unsigned long *fp_regs);
17 extern int restore_fpx_registers(int pid, unsigned long *fp_regs);
18 extern int save_registers(int pid, struct uml_pt_regs *regs);
19 extern int restore_registers(int pid, struct uml_pt_regs *regs);
20 extern int init_registers(int pid);
23 extern int get_fp_registers(int pid, unsigned long *regs);
[all …]
/arch/um/os-Linux/skas/
Dprocess.c26 int is_skas_winch(int pid, int fd, void *data) in is_skas_winch() argument
28 return pid == getpgrp(); in is_skas_winch()
31 static int ptrace_dump_regs(int pid) in ptrace_dump_regs() argument
36 if (ptrace(PTRACE_GETREGS, pid, 0, regs) < 0) in ptrace_dump_regs()
55 void wait_stub_done(int pid) in wait_stub_done() argument
60 CATCH_EINTR(n = waitpid(pid, &status, WUNTRACED | __WALL)); in wait_stub_done()
67 err = ptrace(PTRACE_CONT, pid, 0, 0); in wait_stub_done()
79 err = ptrace_dump_regs(pid); in wait_stub_done()
84 "pid = %d, n = %d, errno = %d, status = 0x%x\n", pid, n, errno, in wait_stub_done()
91 static void get_skas_faultinfo(int pid, struct faultinfo *fi, unsigned long *aux_fp_regs) in get_skas_faultinfo() argument
[all …]
/arch/um/drivers/
Dslirp_user.c40 int pid; in slirp_tramp() local
44 pid = run_helper(slirp_pre_exec, &pe_data, argv); in slirp_tramp()
46 return pid; in slirp_tramp()
52 int fds[2], pid, err; in slirp_open() local
63 pid = err; in slirp_open()
68 pri->pid = err; in slirp_open()
87 if (pri->pid<1) { in slirp_close()
94 if (kill(pri->pid, SIGHUP)<0) { in slirp_close()
96 "(%d)\n", pri->pid, errno); in slirp_close()
99 err = helper_wait(pri->pid); in slirp_close()
[all …]
Dxterm.c19 int pid; member
34 *data = ((struct xterm_chan) { .pid = -1, in xterm_init()
88 int pid, fd, new, err; in xterm_open() local
137 pid = run_helper(NULL, NULL, argv); in xterm_open()
138 if (pid < 0) { in xterm_open()
139 err = pid; in xterm_open()
182 data->pid = pid; in xterm_open()
190 os_kill_process(pid, 1); in xterm_open()
201 if (data->pid != -1) in xterm_close()
202 os_kill_process(data->pid, 1); in xterm_close()
[all …]
Dharddog_user.c33 int in_fds[2], out_fds[2], pid, n, err; in start_watchdog() local
67 pid = run_helper(pre_exec, &data, args); in start_watchdog()
72 if (pid < 0) { in start_watchdog()
73 err = -pid; in start_watchdog()
81 helper_wait(pid); in start_watchdog()
88 helper_wait(pid); in start_watchdog()
Dubd_user.c30 int pid, fds[2], err; in start_io_thread() local
50 pid = clone(io_thread, (void *) sp, CLONE_FILES | CLONE_VM, NULL); in start_io_thread()
51 if(pid < 0){ in start_io_thread()
57 return(pid); in start_io_thread()
Dxterm_kern.c16 int pid; member
25 fd = os_rcv_fd(xterm->fd, &xterm->pid); in xterm_interrupt()
48 .pid = -1, in xterm_fd()
70 *pid_out = data->pid; in xterm_fd()
/arch/cris/arch-v32/kernel/
Dptrace.c31 static int put_debugreg(long pid, unsigned int regno, long data);
32 static long get_debugreg(long pid, unsigned int regno);
34 void deconfigure_bp(long pid);
55 ret = get_debugreg(task->pid, regno); in get_reg()
76 return put_debugreg(task->pid, regno, data); in put_reg()
103 if (!get_debugreg(child->pid, PT_BP_CTRL)) { in user_disable_single_step()
124 deconfigure_bp(child->pid); in ptrace_disable()
339 void deconfigure_bp(long pid) in deconfigure_bp() argument
344 if (bp_owner != pid) in deconfigure_bp()
350 put_debugreg(pid, PT_BP + 3 + (bp * 2), 0); in deconfigure_bp()
[all …]
/arch/x86/um/
Dptrace_user.c9 int ptrace_getregs(long pid, unsigned long *regs_out) in ptrace_getregs() argument
11 if (ptrace(PTRACE_GETREGS, pid, 0, regs_out) < 0) in ptrace_getregs()
16 int ptrace_setregs(long pid, unsigned long *regs) in ptrace_setregs() argument
18 if (ptrace(PTRACE_SETREGS, pid, 0, regs) < 0) in ptrace_setregs()
Dsyscalls_64.c20 int pid = task->mm->context.id.u.pid; in arch_prctl() local
38 ret = restore_registers(pid, &current->thread.regs.regs); in arch_prctl()
55 ret = os_arch_prctl(pid, option, ptr); in arch_prctl()
62 ret = save_registers(pid, &current->thread.regs.regs); in arch_prctl()
65 ret = save_registers(pid, &current->thread.regs.regs); in arch_prctl()
/arch/um/kernel/
Dreboot.c22 int pid; in kill_off_processes() local
31 pid = t->mm->context.id.u.pid; in kill_off_processes()
33 os_kill_ptraced_process(pid, 1); in kill_off_processes()
/arch/um/kernel/skas/
Dprocess.c20 int pid; in start_kernel_proc() local
23 pid = os_getpid(); in start_kernel_proc()
25 cpu_tasks[0].pid = pid; in start_kernel_proc()
Dmmu.c68 to_mm->id.u.pid = copy_context_skas0(stack, in init_new_context()
69 from_mm->id.u.pid); in init_new_context()
70 else to_mm->id.u.pid = start_userspace(stack); in init_new_context()
73 if (to_mm->id.u.pid < 0) { in init_new_context()
74 ret = to_mm->id.u.pid; in init_new_context()
150 if (mmu->id.u.pid < 2) { in destroy_context()
152 mmu->id.u.pid); in destroy_context()
155 os_kill_ptraced_process(mmu->id.u.pid, 1); in destroy_context()
/arch/sh/mm/
Dasids-debugfs.c36 int pid = p->pid; in asids_seq_show() local
38 if (unlikely(!pid)) in asids_seq_show()
42 seq_printf(file, "%5d : %04lx\n", pid, in asids_seq_show()
/arch/mips/kernel/
Dmips-mt-fpaff.c41 static inline struct task_struct *find_process_by_pid(pid_t pid) in find_process_by_pid() argument
43 return pid ? find_task_by_vpid(pid) : current; in find_process_by_pid()
65 asmlinkage long mipsmt_sys_sched_setaffinity(pid_t pid, unsigned int len, in mipsmt_sys_sched_setaffinity() argument
82 p = find_process_by_pid(pid); in mipsmt_sys_sched_setaffinity()
157 asmlinkage long mipsmt_sys_sched_getaffinity(pid_t pid, unsigned int len, in mipsmt_sys_sched_getaffinity() argument
173 p = find_process_by_pid(pid); in mipsmt_sys_sched_getaffinity()

123456789