1 // SPDX-License-Identifier: GPL-2.0 2 #undef __powerpc64__ 3 #include <linux/audit_arch.h> 4 #include <asm/unistd.h> 5 6 #include "audit_32.h" 7 8 unsigned ppc32_dir_class[] = { 9 #include <asm-generic/audit_dir_write.h> 10 ~0U 11 }; 12 13 unsigned ppc32_chattr_class[] = { 14 #include <asm-generic/audit_change_attr.h> 15 ~0U 16 }; 17 18 unsigned ppc32_write_class[] = { 19 #include <asm-generic/audit_write.h> 20 ~0U 21 }; 22 23 unsigned ppc32_read_class[] = { 24 #include <asm-generic/audit_read.h> 25 ~0U 26 }; 27 28 unsigned ppc32_signal_class[] = { 29 #include <asm-generic/audit_signal.h> 30 ~0U 31 }; 32 ppc32_classify_syscall(unsigned syscall)33int ppc32_classify_syscall(unsigned syscall) 34 { 35 switch(syscall) { 36 case __NR_open: 37 return AUDITSC_OPEN; 38 case __NR_openat: 39 return AUDITSC_OPENAT; 40 case __NR_socketcall: 41 return AUDITSC_SOCKETCALL; 42 case __NR_execve: 43 return AUDITSC_EXECVE; 44 case __NR_openat2: 45 return AUDITSC_OPENAT2; 46 default: 47 return AUDITSC_COMPAT; 48 } 49 } 50