diff options
author | Eric Paris <eparis@redhat.com> | 2012-01-03 14:23:06 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-01-17 16:16:56 -0500 |
commit | b05d8447e7821695bc2fa3359431f7a664232743 (patch) | |
tree | da90e558279c6407aa2e08d36bea5d9a21cd959c /arch/sh/kernel/ptrace_32.c | |
parent | f031cd25568a390dc2c9c3a4015054183753449a (diff) |
audit: inline audit_syscall_entry to reduce burden on archs
Every arch calls:
if (unlikely(current->audit_context))
audit_syscall_entry()
which requires knowledge about audit (the existance of audit_context) in
the arch code. Just do it all in static inline in audit.h so that arch's
can remain blissfully ignorant.
Signed-off-by: Eric Paris <eparis@redhat.com>
Diffstat (limited to 'arch/sh/kernel/ptrace_32.c')
-rw-r--r-- | arch/sh/kernel/ptrace_32.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/sh/kernel/ptrace_32.c b/arch/sh/kernel/ptrace_32.c index c0b5c179d27b..a3e651563763 100644 --- a/arch/sh/kernel/ptrace_32.c +++ b/arch/sh/kernel/ptrace_32.c | |||
@@ -518,10 +518,9 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs) | |||
518 | if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT))) | 518 | if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT))) |
519 | trace_sys_enter(regs, regs->regs[0]); | 519 | trace_sys_enter(regs, regs->regs[0]); |
520 | 520 | ||
521 | if (unlikely(current->audit_context)) | 521 | audit_syscall_entry(audit_arch(), regs->regs[3], |
522 | audit_syscall_entry(audit_arch(), regs->regs[3], | 522 | regs->regs[4], regs->regs[5], |
523 | regs->regs[4], regs->regs[5], | 523 | regs->regs[6], regs->regs[7]); |
524 | regs->regs[6], regs->regs[7]); | ||
525 | 524 | ||
526 | return ret ?: regs->regs[0]; | 525 | return ret ?: regs->regs[0]; |
527 | } | 526 | } |