Skip to content

Commit

Permalink
uml: fix compile for x86-64
Browse files Browse the repository at this point in the history
Randy Dunlap reports that we get

  arch/x86/um/shared/sysdep/ptrace.h:7:20: error: redefinition of 'regs_return_value'
  arch/x86/um/shared/sysdep/ptrace.h:7:20: note: previous definition of 'regs_return_value' was here

when compiling UML for x86-64.

Stephen Rothwell root-caused it and says:

 "Caused by commit d7e7528 ("Audit: push audit success and retcode
  into arch ptrace.h") (another patch that was never in linux-next :-().

  This file now needs protection against double inclusion."

so let's do as the man says.

Reported-by: Randy Dunlap <[email protected]>
Analyzed-by: Stephen Rothwell <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
torvalds committed Jan 19, 2012
1 parent f59e842 commit 90a4c0f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions arch/x86/um/shared/sysdep/ptrace.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#ifndef __SYSDEP_X86_PTRACE_H
#define __SYSDEP_X86_PTRACE_H

#ifdef __i386__
#include "ptrace_32.h"
#else
Expand All @@ -8,3 +11,5 @@ static inline long regs_return_value(struct uml_pt_regs *regs)
{
return UPT_SYSCALL_RET(regs);
}

#endif /* __SYSDEP_X86_PTRACE_H */

0 comments on commit 90a4c0f

Please sign in to comment.