Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 167865
b: refs/heads/master
c: cdd3904
h: refs/heads/master
i:
  167863: e440dd2
v: v3
  • Loading branch information
Josh Boyer authored and Benjamin Herrenschmidt committed Oct 27, 2009
1 parent cea8859 commit b0d8298
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 348aa3030096e61474a5537fed5bd69e70b755c0
refs/heads/master: cdd3904dcc56d9d24ef86be897e421d3cc364226
20 changes: 19 additions & 1 deletion trunk/arch/powerpc/xmon/xmon.c
Original file line number Diff line number Diff line change
Expand Up @@ -517,6 +517,15 @@ static int xmon_core(struct pt_regs *regs, int fromipi)
in_xmon = 0;
#endif

#ifdef CONFIG_BOOKE
if (regs->msr & MSR_DE) {
bp = at_breakpoint(regs->nip);
if (bp != NULL) {
regs->nip = (unsigned long) &bp->instr[0];
atomic_inc(&bp->ref_count);
}
}
#else
if ((regs->msr & (MSR_IR|MSR_PR|MSR_SF)) == (MSR_IR|MSR_SF)) {
bp = at_breakpoint(regs->nip);
if (bp != NULL) {
Expand All @@ -530,7 +539,7 @@ static int xmon_core(struct pt_regs *regs, int fromipi)
}
}
}

#endif
insert_cpu_bpts();

local_irq_restore(flags);
Expand Down Expand Up @@ -894,6 +903,14 @@ cmds(struct pt_regs *excp)
}
}

#ifdef CONFIG_BOOKE
static int do_step(struct pt_regs *regs)
{
regs->msr |= MSR_DE;
mtspr(SPRN_DBCR0, mfspr(SPRN_DBCR0) | DBCR0_IC | DBCR0_IDM);
return 1;
}
#else
/*
* Step a single instruction.
* Some instructions we emulate, others we execute with MSR_SE set.
Expand Down Expand Up @@ -924,6 +941,7 @@ static int do_step(struct pt_regs *regs)
regs->msr |= MSR_SE;
return 1;
}
#endif

static void bootcmds(void)
{
Expand Down

0 comments on commit b0d8298

Please sign in to comment.