Skip to content

Commit

Permalink
compat: include linux/unistd.h within linux/compat.h
Browse files Browse the repository at this point in the history
linux/compat.h does not include linux/unistd.h but the compat.h header
file contains various conditional

 #ifdef __ARCH_WANT_COMPAT_...
 asmlinkage long compat...()
 #endif

compat system call function declarations.
If linux/unistd.h isn't included it depends on previous includes if those
__ARCH_WANT_COMPAT_... defines are defined or not. So add an additional
linux/unistd.h include.

Should fix this compile error on tile:

include/uapi/asm-generic/unistd.h:195:1: error: 'compat_sys_getdents64' undeclared
make[3]: *** [arch/tile/kernel/compat.o] Error 1

Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Chris Metcalf <cmetcalf@tilera.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
  • Loading branch information
Heiko Carstens committed Mar 20, 2014
1 parent 5b098c2 commit f5b972e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions include/linux/compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#include <linux/if.h>
#include <linux/fs.h>
#include <linux/aio_abi.h> /* for aio_context_t */
#include <linux/unistd.h>

#include <asm/compat.h>
#include <asm/siginfo.h>
Expand Down

0 comments on commit f5b972e

Please sign in to comment.