Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 334763
b: refs/heads/master
c: b64b9c9
h: refs/heads/master
i:
  334761: bdcbb73
  334759: 892786c
v: v3
  • Loading branch information
Oleg Nesterov committed Oct 7, 2012
1 parent cac444f commit f27b5e3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 15 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: ec75fba93ef0c00c91545b5e53841a80cffad0c4
refs/heads/master: b64b9c937a533f0bfbfc9f6ac93d3c3e2f97ab02
16 changes: 2 additions & 14 deletions trunk/arch/x86/kernel/uprobes.c
Original file line number Diff line number Diff line change
Expand Up @@ -651,31 +651,19 @@ void arch_uprobe_abort_xol(struct arch_uprobe *auprobe, struct pt_regs *regs)

/*
* Skip these instructions as per the currently known x86 ISA.
* 0x66* { 0x90 | 0x0f 0x1f | 0x0f 0x19 | 0x87 0xc0 }
* rep=0x66*; nop=0x90
*/
static bool __skip_sstep(struct arch_uprobe *auprobe, struct pt_regs *regs)
{
int i;

for (i = 0; i < MAX_UINSN_BYTES; i++) {
if ((auprobe->insn[i] == 0x66))
if (auprobe->insn[i] == 0x66)
continue;

if (auprobe->insn[i] == 0x90)
return true;

if (i == (MAX_UINSN_BYTES - 1))
break;

if ((auprobe->insn[i] == 0x0f) && (auprobe->insn[i+1] == 0x1f))
return true;

if ((auprobe->insn[i] == 0x0f) && (auprobe->insn[i+1] == 0x19))
return true;

if ((auprobe->insn[i] == 0x87) && (auprobe->insn[i+1] == 0xc0))
return true;

break;
}
return false;
Expand Down

0 comments on commit f27b5e3

Please sign in to comment.