From: Eric Paris Date: Tue, 22 Apr 2014 15:46:16 +0000 (-0400) Subject: audit: fix build error when asm/syscall.h does not exist X-Git-Tag: v5.15~15883^2~37 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a9ebe0b98896b276a3a1664da5f40d3b7c92f316;p=platform%2Fkernel%2Flinux-starfive.git audit: fix build error when asm/syscall.h does not exist avr32 does not have an asm/syscall.h file. We need the syscall_get_arch() definition from that file for all arch's which support CONFIG_AUDITSYSCALL. Obviously avr32 is not one of those arch's. Move the include inside the CONFIG_AUDITSYSCALL such that we only do the include if we need the results. When the syscall_get_arch() call is moved inside __audit_syscall_entry() this include can be dropped entirely. But that is going to require some assembly changes on x86* in a patch that is not ready for the tree... Reported-by: Paul Gortmaker Signed-off-by: Eric Paris --- diff --git a/include/linux/audit.h b/include/linux/audit.h index bb1c3ab..783157b 100644 --- a/include/linux/audit.h +++ b/include/linux/audit.h @@ -26,7 +26,6 @@ #include #include #include -#include struct audit_sig_info { uid_t uid; @@ -110,6 +109,8 @@ extern void audit_log_session_info(struct audit_buffer *ab); #endif #ifdef CONFIG_AUDITSYSCALL +#include /* for syscall_get_arch() */ + /* These are defined in auditsc.c */ /* Public API */ extern int audit_alloc(struct task_struct *task);