openrisc: Fix up audit_syscall_[entry|exit]() usage

Commits d7e7528bcd456f5c36ad4a202ccfb43c5aa98bc4 and
b05d8447e7821695bc2fa3359431f7a664232743 simplified the usage of the
audit_syscall_[entry|exit] functions.  Unfortunately, the OpenRISC
architecture didn't get fixed up along with the other architectures when
those patches were pushed.  This makes the relevant changes to this
architecture.

Signed-off-by: Jonas Bonn <jonas@southpole.se>
diff --git a/arch/openrisc/include/asm/ptrace.h b/arch/openrisc/include/asm/ptrace.h
index 054537c..e612ce4 100644
--- a/arch/openrisc/include/asm/ptrace.h
+++ b/arch/openrisc/include/asm/ptrace.h
@@ -77,7 +77,6 @@
 	long  syscallno;	/* Syscall number (used by strace) */
 	long dummy;		/* Cheap alignment fix */
 };
-#endif /* __ASSEMBLY__ */
 
 /* TODO: Rename this to REDZONE because that's what it is */
 #define STACK_FRAME_OVERHEAD  128  /* size of minimum stack frame */
@@ -87,6 +86,13 @@
 #define user_stack_pointer(regs)	((unsigned long)(regs)->sp)
 #define profile_pc(regs)		instruction_pointer(regs)
 
+static inline long regs_return_value(struct pt_regs *regs)
+{
+	return regs->gpr[11];
+}
+
+#endif /* __ASSEMBLY__ */
+
 /*
  * Offsets used by 'ptrace' system call interface.
  */