Lines Matching defs:phdl
59 proc_stop(struct proc_handle *phdl)
63 if (kill(proc_getpid(phdl), SIGSTOP) == -1) {
64 DPRINTF("kill %d", proc_getpid(phdl));
66 } else if (waitpid(proc_getpid(phdl), &status, WSTOPPED) == -1) {
67 DPRINTF("waitpid %d", proc_getpid(phdl));
78 proc_bkptset(struct proc_handle *phdl, uintptr_t address,
86 if (phdl->status == PS_DEAD || phdl->status == PS_UNDEAD ||
87 phdl->status == PS_IDLE) {
95 if (phdl->status != PS_STOP) {
96 if (proc_stop(phdl) != 0)
110 if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
126 if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
136 proc_continue(phdl);
142 proc_bkptdel(struct proc_handle *phdl, uintptr_t address,
149 if (phdl->status == PS_DEAD || phdl->status == PS_UNDEAD ||
150 phdl->status == PS_IDLE) {
158 if (phdl->status != PS_STOP) {
159 if (proc_stop(phdl) != 0)
173 if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
181 proc_continue(phdl);
200 proc_bkptexec(struct proc_handle *phdl, unsigned long saved)
206 if (proc_regget(phdl, REG_PC, &pc) < 0) {
211 if (proc_bkptdel(phdl, pc, saved) < 0) {
219 proc_regset(phdl, REG_PC, pc);
220 if (ptrace(PT_STEP, proc_getpid(phdl), (caddr_t)1, 0) < 0) {
224 proc_wstatus(phdl);
225 status = proc_getwstat(phdl);
234 if (proc_bkptset(phdl, pc, &samesaved) < 0) {