summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/uprobes.h
Commit message (Collapse)AuthorAgeFilesLines
* uprobes: Make arch_uprobe_task->saved_trap_nr "unsigned int"Oleg Nesterov2012-10-291-1/+1
| | | | | | | | Make arch_uprobe_task->saved_trap_nr "unsigned int" and move it down after ->saved_scratch_register, this changes sizeof() from 24 to 16. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
* uprobes/x86: Xol should send SIGTRAP if X86_EFLAGS_TF was setOleg Nesterov2012-10-291-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | arch_uprobe_disable_step() correctly preserves X86_EFLAGS_TF and returns to user-mode. But this means the application gets SIGTRAP only after the next insn. This means that UPROBE_CLEAR_TF logic is not really right. _enable should only record the state of X86_EFLAGS_TF, and _disable should check it separately from UPROBE_FIX_SETF. Remove arch_uprobe_task->restore_flags, add ->saved_tf instead, and change enable/disable accordingly. This assumes that the probed insn was not trapped, see the next patch. arch_uprobe_skip_sstep() logic has the same problem, change it to check X86_EFLAGS_TF and send SIGTRAP as well. We will cleanup this all after we fold enable/disable_step into pre/post_hol hooks. Note: send_sig(SIGTRAP) is not actually right, we need send_sigtrap(). But this needs more changes, handle_swbp() does the same and this is equally wrong. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
* uprobes/x86: Implement x86 specific arch_uprobe_*_stepSebastian Andrzej Siewior2012-10-291-0/+2
| | | | | | | | | | | | | | | | | | The arch specific implementation behaves like user_enable_single_step() except that it does not disable single stepping if it was already enabled by ptrace. This allows the debugger to single step over an uprobe. The state of block stepping is not restored. It makes only sense together with TF and if that was enabled then the debugger is notified. Note: this is still not correct. For example, TIF_SINGLESTEP check is not right, the application itself can set X86_EFLAGS_TF. And otoh we leak TIF_SINGLESTEP (set by enable) if the probed insn is "popf". See the next patches, we need the changes in arch/x86/kernel/step.c first. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Oleg Nesterov <oleg@redhat.com> Acked-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
* fedora kernel: cd394142aac30b5c751f25b517572e2448695641v3.6.3-2f17Anton Arapov2012-10-291-1/+1
| | | | Signed-off-by: Anton Arapov <anton@redhat.com>
* fedora kernel: 222b075b3ff0d9e88aa9353e3c80667756ed7361v3.5.0-4Anton Arapov2012-08-071-1/+1
| | | | Signed-off-by: Anton Arapov <anton@redhat.com>
* fedora kernel: 6c6f1b8594284404f143c407081ebe65fe068c81v3.4.4-1Anton Arapov2012-06-251-0/+57
Signed-off-by: Anton Arapov <anton@redhat.com>