static int
mips_linux_can_use_hw_breakpoint (struct target_ops *self,
- int type, int cnt, int ot)
+ enum bptype type,
+ int cnt, int ot)
{
int i;
uint32_t wanted_mask, irw_mask;
ALL_LWPS (lp)
{
tid = ptid_get_lwp (lp->ptid);
- if (ptrace (PTRACE_SET_WATCH_REGS, tid, &watch_mirror) == -1)
+ if (ptrace (PTRACE_SET_WATCH_REGS, tid, &watch_mirror, NULL) == -1)
perror_with_name (_("Couldn't write debug register"));
}
return 0;
return;
tid = ptid_get_lwp (lp->ptid);
- if (ptrace (PTRACE_SET_WATCH_REGS, tid, &watch_mirror) == -1)
+ if (ptrace (PTRACE_SET_WATCH_REGS, tid, &watch_mirror, NULL) == -1)
perror_with_name (_("Couldn't write debug register"));
}
static int
mips_linux_insert_watchpoint (struct target_ops *self,
- CORE_ADDR addr, int len, int type,
+ CORE_ADDR addr, int len,
+ enum target_hw_bp_type type,
struct expression *cond)
{
struct pt_watch_regs regs;
return -1;
/* It fit. Stick it on the end of the list. */
- new_watch = (struct mips_watchpoint *)
- xmalloc (sizeof (struct mips_watchpoint));
+ new_watch = XNEW (struct mips_watchpoint);
new_watch->addr = addr;
new_watch->len = len;
new_watch->type = type;
static int
mips_linux_remove_watchpoint (struct target_ops *self,
- CORE_ADDR addr, int len, int type,
+ CORE_ADDR addr, int len,
+ enum target_hw_bp_type type,
struct expression *cond)
{
int retval;