lkml.org 
[lkml]   [2009]   [Mar]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH 1/5] ptrace: remove incorrect unlikelys
From: Steven Rostedt <rostedt@goodmis.org>

Impact: clean up

Accounding to the annotated branch profiler, the unlikelys used by
ptrace is incorrect every time.

correct incorrect % Function File Line
------- --------- - -------- ---- ----
0 24176 100 syscall_trace_leave ptrace.c 1444
0 21478 100 syscall_trace_enter ptrace.c 1424

Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
arch/x86/kernel/ptrace.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c
index 06ca07f..74a16db 100644
--- a/arch/x86/kernel/ptrace.c
+++ b/arch/x86/kernel/ptrace.c
@@ -1421,7 +1421,7 @@ asmregparm long syscall_trace_enter(struct pt_regs *regs)
tracehook_report_syscall_entry(regs))
ret = -1L;

- if (unlikely(current->audit_context)) {
+ if (current->audit_context) {
if (IS_IA32)
audit_syscall_entry(AUDIT_ARCH_I386,
regs->orig_ax,
@@ -1441,7 +1441,7 @@ asmregparm long syscall_trace_enter(struct pt_regs *regs)

asmregparm void syscall_trace_leave(struct pt_regs *regs)
{
- if (unlikely(current->audit_context))
+ if (current->audit_context)
audit_syscall_exit(AUDITSC_RESULT(regs->ax), regs->ax);

if (test_thread_flag(TIF_SYSCALL_TRACE))
--
1.6.2
--


\
 
 \ /
  Last update: 2009-03-25 06:25    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site