mirror of
https://git.openafs.org/openafs.git
synced 2025-01-18 06:50:12 +00:00
Linux: Include linux/uaccess.h rather than asm/uaccess.h if present
Starting with Linux 4.12 there is a module build error on s390 due to asm/uaccess.h using a macro defined in the common header. The common header has been around since 2.6.18 and has always included asm/uaccess.h, so switch to using the common header whenever it is present. Change-Id: Iaab0d7652483a2a2b1f144f3e90b6d3b902c146d Signed-off-by: Seth Forshee <seth.forshee@canonical.com> Reviewed-on: https://gerrit.openafs.org/12714 Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> Tested-by: BuildBot <buildbot@rampaginggeek.com>
This commit is contained in:
parent
e739eaa650
commit
962f4838dc
@ -939,6 +939,7 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
|
||||
AC_CHECK_LINUX_HEADER([semaphore.h])
|
||||
AC_CHECK_LINUX_HEADER([seq_file.h])
|
||||
AC_CHECK_LINUX_HEADER([sched/signal.h])
|
||||
AC_CHECK_LINUX_HEADER([uaccess.h])
|
||||
|
||||
dnl Type existence checks
|
||||
AC_CHECK_LINUX_TYPE([struct vfs_path], [dcache.h])
|
||||
|
@ -123,7 +123,11 @@ wakeup(void *event)
|
||||
#define IsAfsVnode(V) ((V)->i_sb == afs_globalVFS) /* test superblock instead */
|
||||
#define SetAfsVnode(V) /* unnecessary */
|
||||
|
||||
#if defined(HAVE_LINUX_UACCESS_H)
|
||||
#include <linux/uaccess.h>
|
||||
#else
|
||||
#include <asm/uaccess.h>
|
||||
#endif
|
||||
|
||||
#define copyin(F, T, C) (copy_from_user ((char*)(T), (char*)(F), (C)) > 0 ? EFAULT : 0)
|
||||
static inline long copyinstr(char *from, char *to, int count, int *length) {
|
||||
|
@ -145,7 +145,11 @@ struct coda_inode_info {
|
||||
struct xfs_inode_info {
|
||||
};
|
||||
# endif
|
||||
# include <asm/uaccess.h>
|
||||
# if defined(HAVE_LINUX_UACCESS_H)
|
||||
# include <linux/uaccess.h>
|
||||
# else
|
||||
# include <asm/uaccess.h>
|
||||
# endif
|
||||
# include <linux/list.h>
|
||||
# include <linux/dcache.h>
|
||||
# include <linux/mount.h>
|
||||
|
@ -25,7 +25,11 @@
|
||||
#include "rx_peer.h"
|
||||
#include "rx_packet.h"
|
||||
#include "rx_internal.h"
|
||||
#if defined(HAVE_LINUX_UACCESS_H)
|
||||
#include <linux/uaccess.h>
|
||||
#else
|
||||
#include <asm/uaccess.h>
|
||||
#endif
|
||||
#ifdef AFS_RXERRQ_ENV
|
||||
#include <linux/errqueue.h>
|
||||
#include <linux/icmp.h>
|
||||
|
Loading…
Reference in New Issue
Block a user