Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 1910
b: refs/heads/master
c: 63224d1
h: refs/heads/master
v: v3
  • Loading branch information
Ananth N Mavinakayanahalli authored and Linus Torvalds committed Jun 8, 2005
1 parent d2b825c commit a2fe9b8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 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: 42442ed5744b03f5351a142649b8b4c97e6950ab
refs/heads/master: 63224d1e8b4cf87cc7420201a8cb3b44b9bf0b40
13 changes: 9 additions & 4 deletions trunk/arch/ppc64/kernel/kprobes.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,17 @@ static struct pt_regs jprobe_saved_regs;

int arch_prepare_kprobe(struct kprobe *p)
{
int ret = 0;
kprobe_opcode_t insn = *p->addr;

if (IS_MTMSRD(insn) || IS_RFID(insn))
/* cannot put bp on RFID/MTMSRD */
return 1;
return 0;
if ((unsigned long)p->addr & 0x03) {
printk("Attempt to register kprobe at an unaligned address\n");
ret = -EINVAL;
} else if (IS_MTMSRD(insn) || IS_RFID(insn)) {
printk("Cannot register a kprobe on rfid or mtmsrd\n");
ret = -EINVAL;
}
return ret;
}

void arch_copy_kprobe(struct kprobe *p)
Expand Down

0 comments on commit a2fe9b8

Please sign in to comment.