diff options
Diffstat (limited to 'arch')
65 files changed, 214 insertions, 267 deletions
diff --git a/arch/arm/include/uapi/asm/hwcap.h b/arch/arm/include/uapi/asm/hwcap.h index 6d34d080372a..edb850960012 100644 --- a/arch/arm/include/uapi/asm/hwcap.h +++ b/arch/arm/include/uapi/asm/hwcap.h @@ -1,5 +1,5 @@ -#ifndef _UAPI__ASMARM_HWCAP_H -#define _UAPI__ASMARM_HWCAP_H +#ifndef __ASMARM_HWCAP_H +#define __ASMARM_HWCAP_H /* * HWCAP flags - for elf_hwcap (in kernel) and AT_HWCAP @@ -27,4 +27,4 @@ #define HWCAP_IDIV (HWCAP_IDIVA | HWCAP_IDIVT) #define HWCAP_LPAE (1 << 20) -#endif /* _UAPI__ASMARM_HWCAP_H */ +#endif /* __ASMARM_HWCAP_H */ diff --git a/arch/arm/include/uapi/asm/ptrace.h b/arch/arm/include/uapi/asm/ptrace.h index 5af0ed1b825a..950ab550d4d7 100644 --- a/arch/arm/include/uapi/asm/ptrace.h +++ b/arch/arm/include/uapi/asm/ptrace.h @@ -7,8 +7,8 @@ * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ -#ifndef _UAPI__ASM_ARM_PTRACE_H -#define _UAPI__ASM_ARM_PTRACE_H +#ifndef __ASM_ARM_PTRACE_H +#define __ASM_ARM_PTRACE_H #include <asm/hwcap.h> @@ -40,17 +40,8 @@ #define FIQ26_MODE 0x00000001 #define IRQ26_MODE 0x00000002 #define SVC26_MODE 0x00000003 -#if defined(__KERNEL__) && defined(CONFIG_CPU_V7M) -/* - * Use 0 here to get code right that creates a userspace - * or kernel space thread. - */ -#define USR_MODE 0x00000000 -#define SVC_MODE 0x00000000 -#else #define USR_MODE 0x00000010 #define SVC_MODE 0x00000013 -#endif #define FIQ_MODE 0x00000011 #define IRQ_MODE 0x00000012 #define ABT_MODE 0x00000017 @@ -62,12 +53,8 @@ #define V4_PSR_T_BIT 0x00000020 /* >= V4T, but not V7M */ #define V7M_PSR_T_BIT 0x01000000 -#if defined(__KERNEL__) && defined(CONFIG_CPU_V7M) -#define PSR_T_BIT V7M_PSR_T_BIT -#else /* for compatibility */ #define PSR_T_BIT V4_PSR_T_BIT -#endif #define PSR_F_BIT 0x00000040 /* >= V4, but not V7M */ #define PSR_I_BIT 0x00000080 /* >= V4, but not V7M */ @@ -120,11 +107,9 @@ * stack during a system call. Note that sizeof(struct pt_regs) * has to be a multiple of 8. */ -#ifndef __KERNEL__ struct pt_regs { long uregs[18]; }; -#endif /* __KERNEL__ */ #define ARM_cpsr uregs[16] #define ARM_pc uregs[15] @@ -154,4 +139,4 @@ struct pt_regs { #endif /* __ASSEMBLY__ */ -#endif /* _UAPI__ASM_ARM_PTRACE_H */ +#endif /* __ASM_ARM_PTRACE_H */ diff --git a/arch/arm/include/uapi/asm/setup.h b/arch/arm/include/uapi/asm/setup.h index 979ff4016404..734ff39c98dc 100644 --- a/arch/arm/include/uapi/asm/setup.h +++ b/arch/arm/include/uapi/asm/setup.h @@ -11,8 +11,8 @@ * hardware it's running on. See Documentation/arm/Setup * for more info. */ -#ifndef _UAPI__ASMARM_SETUP_H -#define _UAPI__ASMARM_SETUP_H +#ifndef __ASMARM_SETUP_H +#define __ASMARM_SETUP_H #include <linux/types.h> @@ -184,4 +184,4 @@ struct tagtable { for (t = base; t->hdr.size; t = tag_next(t)) -#endif /* _UAPI__ASMARM_SETUP_H */ +#endif /* __ASMARM_SETUP_H */ diff --git a/arch/arm/include/uapi/asm/signal.h b/arch/arm/include/uapi/asm/signal.h index 33073bdcf091..93a5c1854513 100644 --- a/arch/arm/include/uapi/asm/signal.h +++ b/arch/arm/include/uapi/asm/signal.h @@ -1,18 +1,16 @@ -#ifndef _UAPI_ASMARM_SIGNAL_H -#define _UAPI_ASMARM_SIGNAL_H +#ifndef _ASMARM_SIGNAL_H +#define _ASMARM_SIGNAL_H #include <linux/types.h> /* Avoid too many header ordering problems. */ struct siginfo; -#ifndef __KERNEL__ /* Here we must cater to libcs that poke about in kernel headers. */ #define NSIG 32 typedef unsigned long sigset_t; -#endif /* __KERNEL__ */ #define SIGHUP 1 #define SIGINT 2 @@ -92,7 +90,6 @@ typedef unsigned long sigset_t; #include <asm-generic/signal-defs.h> -#ifndef __KERNEL__ /* Here we must cater to libcs that poke about in kernel headers. */ struct sigaction { @@ -108,13 +105,12 @@ struct sigaction { #define sa_handler _u._sa_handler #define sa_sigaction _u._sa_sigaction -#endif /* __KERNEL__ */ typedef struct sigaltstack { - void __user *ss_sp; + void *ss_sp; int ss_flags; size_t ss_size; } stack_t; -#endif /* _UAPI_ASMARM_SIGNAL_H */ +#endif /* _ASMARM_SIGNAL_H */ diff --git a/arch/arm/include/uapi/asm/swab.h b/arch/arm/include/uapi/asm/swab.h index 6fcb32a5c453..5f621bfba8b9 100644 --- a/arch/arm/include/uapi/asm/swab.h +++ b/arch/arm/include/uapi/asm/swab.h @@ -12,10 +12,10 @@ * and word accesses (data or instruction) appear as: * d0...d31 */ -#ifndef _UAPI__ASM_ARM_SWAB_H -#define _UAPI__ASM_ARM_SWAB_H +#ifndef __ASM_ARM_SWAB_H +#define __ASM_ARM_SWAB_H + -#include <linux/compiler.h> #include <linux/types.h> #if !defined(__STRICT_ANSI__) || defined(__KERNEL__) @@ -23,8 +23,7 @@ #endif -#if !defined(__KERNEL__) || __LINUX_ARM_ARCH__ < 6 -static inline __attribute_const__ __u32 __arch_swab32(__u32 x) +static __inline__ __u32 __arch_swab32(__u32 x) { __u32 t; @@ -35,7 +34,7 @@ static inline __attribute_const__ __u32 __arch_swab32(__u32 x) * right thing and not screw it up to different degrees * depending on the gcc version. */ - asm ("eor\t%0, %1, %1, ror #16" : "=r" (t) : "r" (x)); + __asm__ ("eor\t%0, %1, %1, ror #16" : "=r" (t) : "r" (x)); } else #endif t = x ^ ((x << 16) | (x >> 16)); /* eor r1,r0,r0,ror #16 */ @@ -48,6 +47,5 @@ static inline __attribute_const__ __u32 __arch_swab32(__u32 x) } #define __arch_swab32 __arch_swab32 -#endif -#endif /* _UAPI__ASM_ARM_SWAB_H */ +#endif /* __ASM_ARM_SWAB_H */ diff --git a/arch/arm/include/uapi/asm/unistd.h b/arch/arm/include/uapi/asm/unistd.h index af33b44990ed..896d5143c87d 100644 --- a/arch/arm/include/uapi/asm/unistd.h +++ b/arch/arm/include/uapi/asm/unistd.h @@ -10,8 +10,8 @@ * Please forward _all_ changes to this file to rmk@arm.linux.org.uk, * no matter what the change is. Thanks! */ -#ifndef _UAPI__ASM_ARM_UNISTD_H -#define _UAPI__ASM_ARM_UNISTD_H +#ifndef __ASM_ARM_UNISTD_H +#define __ASM_ARM_UNISTD_H #define __NR_OABI_SYSCALL_BASE 0x900000 @@ -431,7 +431,6 @@ /* * The following syscalls are obsolete and no longer available for EABI. */ -#if !defined(__KERNEL__) #if defined(__ARM_EABI__) #undef __NR_time #undef __NR_umount @@ -446,6 +445,5 @@ #undef __NR_syscall #undef __NR_ipc #endif -#endif -#endif /* _UAPI__ASM_ARM_UNISTD_H */ +#endif /* __ASM_ARM_UNISTD_H */ diff --git a/arch/arm64/include/uapi/asm/hwcap.h b/arch/arm64/include/uapi/asm/hwcap.h index eea497578b87..f2890d01cc07 100644 --- a/arch/arm64/include/uapi/asm/hwcap.h +++ b/arch/arm64/include/uapi/asm/hwcap.h @@ -13,8 +13,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _UAPI__ASM_HWCAP_H -#define _UAPI__ASM_HWCAP_H +#ifndef __ASM_HWCAP_H +#define __ASM_HWCAP_H /* * HWCAP flags - for elf_hwcap (in kernel) and AT_HWCAP @@ -23,4 +23,4 @@ #define HWCAP_ASIMD (1 << 1) -#endif /* _UAPI__ASM_HWCAP_H */ +#endif /* __ASM_HWCAP_H */ diff --git a/arch/arm64/include/uapi/asm/ptrace.h b/arch/arm64/include/uapi/asm/ptrace.h index 6913643bbe54..d2fcc969e7df 100644 --- a/arch/arm64/include/uapi/asm/ptrace.h +++ b/arch/arm64/include/uapi/asm/ptrace.h @@ -16,8 +16,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _UAPI__ASM_PTRACE_H -#define _UAPI__ASM_PTRACE_H +#ifndef __ASM_PTRACE_H +#define __ASM_PTRACE_H #include <linux/types.h> @@ -89,4 +89,4 @@ struct user_hwdebug_state { #endif /* __ASSEMBLY__ */ -#endif /* _UAPI__ASM_PTRACE_H */ +#endif /* __ASM_PTRACE_H */ diff --git a/arch/arm64/include/uapi/asm/sigcontext.h b/arch/arm64/include/uapi/asm/sigcontext.h index 690ad51cc901..fd5b447ed4b6 100644 --- a/arch/arm64/include/uapi/asm/sigcontext.h +++ b/arch/arm64/include/uapi/asm/sigcontext.h @@ -13,8 +13,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _UAPI__ASM_SIGCONTEXT_H -#define _UAPI__ASM_SIGCONTEXT_H +#ifndef __ASM_SIGCONTEXT_H +#define __ASM_SIGCONTEXT_H #include <linux/types.h> @@ -54,4 +54,4 @@ struct fpsimd_context { }; -#endif /* _UAPI__ASM_SIGCONTEXT_H */ +#endif /* __ASM_SIGCONTEXT_H */ diff --git a/arch/microblaze/include/uapi/asm/elf.h b/arch/microblaze/include/uapi/asm/elf.h index be1731d5e2fa..f96828f2b70a 100644 --- a/arch/microblaze/include/uapi/asm/elf.h +++ b/arch/microblaze/include/uapi/asm/elf.h @@ -8,8 +8,8 @@ * for more details. */ -#ifndef _UAPI_ASM_MICROBLAZE_ELF_H -#define _UAPI_ASM_MICROBLAZE_ELF_H +#ifndef _ASM_MICROBLAZE_ELF_H +#define _ASM_MICROBLAZE_ELF_H /* * Note there is no "official" ELF designation for Microblaze. @@ -118,4 +118,4 @@ do { \ #endif /* __uClinux__ */ -#endif /* _UAPI_ASM_MICROBLAZE_ELF_H */ +#endif /* _ASM_MICROBLAZE_ELF_H */ diff --git a/arch/microblaze/include/uapi/asm/ptrace.h b/arch/microblaze/include/uapi/asm/ptrace.h index d31238a5f946..5b0be96be9d7 100644 --- a/arch/microblaze/include/uapi/asm/ptrace.h +++ b/arch/microblaze/include/uapi/asm/ptrace.h @@ -6,8 +6,8 @@ * for more details. */ -#ifndef _UAPI_ASM_MICROBLAZE_PTRACE_H -#define _UAPI_ASM_MICROBLAZE_PTRACE_H +#ifndef _ASM_MICROBLAZE_PTRACE_H +#define _ASM_MICROBLAZE_PTRACE_H #ifndef __ASSEMBLY__ @@ -54,7 +54,6 @@ struct pt_regs { int pt_mode; }; -#ifndef __KERNEL__ /* pt_regs offsets used by gdbserver etc in ptrace syscalls */ #define PT_GPR(n) ((n) * sizeof(microblaze_reg_t)) @@ -65,8 +64,7 @@ struct pt_regs { #define PT_FSR (36 * sizeof(microblaze_reg_t)) #define PT_KERNEL_MODE (37 * sizeof(microblaze_reg_t)) -#endif /* __KERNEL */ #endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_MICROBLAZE_PTRACE_H */ +#endif /* _ASM_MICROBLAZE_PTRACE_H */ diff --git a/arch/microblaze/include/uapi/asm/setup.h b/arch/microblaze/include/uapi/asm/setup.h index 76bc2acee6af..6af93cf87815 100644 --- a/arch/microblaze/include/uapi/asm/setup.h +++ b/arch/microblaze/include/uapi/asm/setup.h @@ -8,12 +8,12 @@ * for more details. */ -#ifndef _UAPI_ASM_MICROBLAZE_SETUP_H -#define _UAPI_ASM_MICROBLAZE_SETUP_H +#ifndef _ASM_MICROBLAZE_SETUP_H +#define _ASM_MICROBLAZE_SETUP_H #define COMMAND_LINE_SIZE 256 # ifndef __ASSEMBLY__ # endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_MICROBLAZE_SETUP_H */ +#endif /* _ASM_MICROBLAZE_SETUP_H */ diff --git a/arch/microblaze/include/uapi/asm/unistd.h b/arch/microblaze/include/uapi/asm/unistd.h index 20043b67d158..0fa49724e42f 100644 --- a/arch/microblaze/include/uapi/asm/unistd.h +++ b/arch/microblaze/include/uapi/asm/unistd.h @@ -7,8 +7,8 @@ * for more details. */ -#ifndef _UAPI_ASM_MICROBLAZE_UNISTD_H -#define _UAPI_ASM_MICROBLAZE_UNISTD_H +#ifndef _ASM_MICROBLAZE_UNISTD_H +#define _ASM_MICROBLAZE_UNISTD_H #define __NR_restart_syscall 0 /* ok */ #define __NR_exit 1 /* ok */ @@ -397,4 +397,4 @@ #define __NR_kcmp 379 #define __NR_finit_module 380 -#endif /* _UAPI_ASM_MICROBLAZE_UNISTD_H */ +#endif /* _ASM_MICROBLAZE_UNISTD_H */ diff --git a/arch/mips/include/uapi/asm/errno.h b/arch/mips/include/uapi/asm/errno.h index 31575e2fd1bd..8919f87a5418 100644 --- a/arch/mips/include/uapi/asm/errno.h +++ b/arch/mips/include/uapi/asm/errno.h @@ -5,8 +5,8 @@ * * Copyright (C) 1995, 1999, 2001, 2002 by Ralf Baechle */ -#ifndef _UAPI_ASM_ERRNO_H -#define _UAPI_ASM_ERRNO_H +#ifndef _ASM_ERRNO_H +#define _ASM_ERRNO_H /* * These error numbers are intended to be MIPS ABI compatible @@ -126,4 +126,4 @@ #define EDQUOT 1133 /* Quota exceeded */ -#endif /* _UAPI_ASM_ERRNO_H */ +#endif /* _ASM_ERRNO_H */ diff --git a/arch/mips/include/uapi/asm/fcntl.h b/arch/mips/include/uapi/asm/fcntl.h index 6ca432f00860..88755eed9474 100644 --- a/arch/mips/include/uapi/asm/fcntl.h +++ b/arch/mips/include/uapi/asm/fcntl.h @@ -5,8 +5,8 @@ * * Copyright (C) 1995, 96, 97, 98, 99, 2003, 05 Ralf Baechle */ -#ifndef _UAPI_ASM_FCNTL_H -#define _UAPI_ASM_FCNTL_H +#ifndef _ASM_FCNTL_H +#define _ASM_FCNTL_H #include <asm/sgidefs.h> @@ -76,4 +76,4 @@ struct flock { #include <asm-generic/fcntl.h> -#endif /* _UAPI_ASM_FCNTL_H */ +#endif /* _ASM_FCNTL_H */ diff --git a/arch/mips/include/uapi/asm/inst.h b/arch/mips/include/uapi/asm/inst.h index e5a676e3d3c0..2c1ceb66e34a 100644 --- a/arch/mips/include/uapi/asm/inst.h +++ b/arch/mips/include/uapi/asm/inst.h @@ -9,8 +9,8 @@ * Copyright (C) 2006 by Thiemo Seufer * Copyright (C) 2012 MIPS Technologies, Inc. All rights reserved. */ -#ifndef _UAPI_ASM_INST_H -#define _UAPI_ASM_INST_H +#ifndef _ASM_INST_H +#define _ASM_INST_H /* * Major opcodes; before MIPS IV cop1x was called cop3. @@ -893,4 +893,4 @@ union mips16e_instruction { struct m16e_i8 i8; }; -#endif /* _UAPI_ASM_INST_H */ +#endif /* _ASM_INST_H */ diff --git a/arch/mips/include/uapi/asm/ioctls.h b/arch/mips/include/uapi/asm/ioctls.h index b1e637757fe3..70b139113b86 100644 --- a/arch/mips/include/uapi/asm/ioctls.h +++ b/arch/mips/include/uapi/asm/ioctls.h @@ -108,6 +108,6 @@ #define TIOCSERGETMULTI 0x548f /* Get multiport config */ #define TIOCSERSETMULTI 0x5490 /* Set multiport config */ #define TIOCMIWAIT 0x5491 /* wait for a change on serial input line(s) */ -#define TIOCGICOUNT 0x5492 /* read serial port inline interrupt counts */ +#define TIOCGICOUNT 0x5492 /* read serial port __inline__ interrupt counts */ #endif /* __ASM_IOCTLS_H */ diff --git a/arch/mips/include/uapi/asm/ptrace.h b/arch/mips/include/uapi/asm/ptrace.h index b26f7e317279..508f8fdc79ed 100644 --- a/arch/mips/include/uapi/asm/ptrace.h +++ b/arch/mips/include/uapi/asm/ptrace.h @@ -6,8 +6,8 @@ * Copyright (C) 1994, 95, 96, 97, 98, 99, 2000 by Ralf Baechle * Copyright (C) 1999, 2000 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_PTRACE_H -#define _UAPI_ASM_PTRACE_H +#ifndef _ASM_PTRACE_H +#define _ASM_PTRACE_H /* 0 - 31 are integer registers, 32 - 63 are fp registers. */ #define FPR_BASE 32 @@ -22,7 +22,6 @@ #define DSP_CONTROL 77 #define ACX 78 -#ifndef __KERNEL__ /* * This struct defines the way the registers are stored on the stack during a * system call/exception. As usual the registers k0/k1 aren't being saved. @@ -39,7 +38,6 @@ struct pt_regs { unsigned long cp0_cause; unsigned long cp0_epc; } __attribute__ ((aligned (8))); -#endif /* __KERNEL__ */ /* Arbitrarily choose the same ptrace numbers as used by the Sparc code. */ #define PTRACE_GETREGS 12 @@ -100,4 +98,4 @@ struct pt_watch_regs { #define PTRACE_SET_WATCH_REGS 0xd1 -#endif /* _UAPI_ASM_PTRACE_H */ +#endif /* _ASM_PTRACE_H */ diff --git a/arch/mips/include/uapi/asm/setup.h b/arch/mips/include/uapi/asm/setup.h index 93f237bb1353..716f4b74b416 100644 --- a/arch/mips/include/uapi/asm/setup.h +++ b/arch/mips/include/uapi/asm/setup.h @@ -1,7 +1,7 @@ -#ifndef _UAPI_MIPS_SETUP_H -#define _UAPI_MIPS_SETUP_H +#ifndef _MIPS_SETUP_H +#define _MIPS_SETUP_H #define COMMAND_LINE_SIZE 4096 -#endif /* _UAPI_MIPS_SETUP_H */ +#endif /* _MIPS_SETUP_H */ diff --git a/arch/mips/include/uapi/asm/sigcontext.h b/arch/mips/include/uapi/asm/sigcontext.h index 6c9906f59c6e..0f64a709cd54 100644 --- a/arch/mips/include/uapi/asm/sigcontext.h +++ b/arch/mips/include/uapi/asm/sigcontext.h @@ -6,8 +6,8 @@ * Copyright (C) 1996, 1997, 1999 by Ralf Baechle * Copyright (C) 1999 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_SIGCONTEXT_H -#define _UAPI_ASM_SIGCONTEXT_H +#ifndef _ASM_SIGCONTEXT_H +#define _ASM_SIGCONTEXT_H #include <linux/types.h> #include <asm/sgidefs.h> @@ -75,4 +75,4 @@ struct sigcontext { #endif /* _MIPS_SIM == _MIPS_SIM_ABI64 || _MIPS_SIM == _MIPS_SIM_NABI32 */ -#endif /* _UAPI_ASM_SIGCONTEXT_H */ +#endif /* _ASM_SIGCONTEXT_H */ diff --git a/arch/mips/include/uapi/asm/siginfo.h b/arch/mips/include/uapi/asm/siginfo.h index 88e292b7719e..4d847c8af7fb 100644 --- a/arch/mips/include/uapi/asm/siginfo.h +++ b/arch/mips/include/uapi/asm/siginfo.h @@ -6,8 +6,8 @@ * Copyright (C) 1998, 1999, 2001, 2003 Ralf Baechle * Copyright (C) 2000, 2001 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_SIGINFO_H -#define _UAPI_ASM_SIGINFO_H +#ifndef _ASM_SIGINFO_H +#define _ASM_SIGINFO_H #define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(long) + 2*sizeof(int)) @@ -46,13 +46,13 @@ typedef struct siginfo { /* kill() */ struct { - pid_t _pid; /* sender's pid */ + __kernel_pid_t _pid; /* sender's pid */ __ARCH_SI_UID_T _uid; /* sender's uid */ } _kill; /* POSIX.1b timers */ struct { - timer_t _tid; /* timer id */ + __kernel_timer_t _tid; /* timer id */ int _overrun; /* overrun count */ char _pad[sizeof( __ARCH_SI_UID_T) - sizeof(int)]; sigval_t _sigval; /* same as below */ @@ -61,31 +61,31 @@ typedef struct siginfo { /* POSIX.1b signals */ struct { - pid_t _pid; /* sender's pid */ + __kernel_pid_t _pid; /* sender's pid */ __ARCH_SI_UID_T _uid; /* sender's uid */ sigval_t _sigval; } _rt; /* SIGCHLD */ struct { - pid_t _pid; /* which child */ + __kernel_pid_t _pid; /* which child */ __ARCH_SI_UID_T _uid; /* sender's uid */ int _status; /* exit code */ - clock_t _utime; - clock_t _stime; + __kernel_clock_t _utime; + __kernel_clock_t _stime; } _sigchld; /* IRIX SIGCHLD */ struct { - pid_t _pid; /* which child */ - clock_t _utime; + __kernel_pid_t _pid; /* which child */ + __kernel_clock_t _utime; int _status; /* exit code */ - clock_t _stime; + __kernel_clock_t _stime; } _irix_sigchld; /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */ struct { - void __user *_addr; /* faulting insn/memory ref. */ + void *_addr; /* faulting insn/memory ref. */ #ifdef __ARCH_SI_TRAPNO int _trapno; /* TRAP # which caused the signal */ #endif @@ -112,4 +112,4 @@ typedef struct siginfo { #define SI_MESGQ __SI_CODE(__SI_MESGQ, -4) /* sent by real time mesq state change */ -#endif /* _UAPI_ASM_SIGINFO_H */ +#endif /* _ASM_SIGINFO_H */ diff --git a/arch/mips/include/uapi/asm/signal.h b/arch/mips/include/uapi/asm/signal.h index addb9f556b71..13aa4c21b5c8 100644 --- a/arch/mips/include/uapi/asm/signal.h +++ b/arch/mips/include/uapi/asm/signal.h @@ -6,8 +6,8 @@ * Copyright (C) 1995, 96, 97, 98, 99, 2003 by Ralf Baechle * Copyright (C) 1999 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_SIGNAL_H -#define _UAPI_ASM_SIGNAL_H +#ifndef _ASM_SIGNAL_H +#define _ASM_SIGNAL_H #include <linux/types.h> @@ -100,20 +100,18 @@ typedef unsigned long old_sigset_t; /* at least 32 bits */ #include <asm-generic/signal-defs.h> -#ifndef __KERNEL__ struct sigaction { unsigned int sa_flags; __sighandler_t sa_handler; sigset_t sa_mask; }; -#endif /* IRIX compatible stack_t */ typedef struct sigaltstack { - void __user *ss_sp; + void *ss_sp; size_t ss_size; int ss_flags; } stack_t; -#endif /* _UAPI_ASM_SIGNAL_H */ +#endif /* _ASM_SIGNAL_H */ diff --git a/arch/mips/include/uapi/asm/socket.h b/arch/mips/include/uapi/asm/socket.h index 61c01f054d1b..00927d419971 100644 --- a/arch/mips/include/uapi/asm/socket.h +++ b/arch/mips/include/uapi/asm/socket.h @@ -6,8 +6,8 @@ * Copyright (C) 1997, 1999, 2000, 2001 Ralf Baechle * Copyright (C) 2000, 2001 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_SOCKET_H -#define _UAPI_ASM_SOCKET_H +#ifndef _ASM_SOCKET_H +#define _ASM_SOCKET_H #include <asm/sockios.h> @@ -94,4 +94,4 @@ #define SO_BUSY_POLL 46 -#endif /* _UAPI_ASM_SOCKET_H */ +#endif /* _ASM_SOCKET_H */ diff --git a/arch/mips/include/uapi/asm/swab.h b/arch/mips/include/uapi/asm/swab.h index ac9a8f9cd1fb..b098829cd600 100644 --- a/arch/mips/include/uapi/asm/swab.h +++ b/arch/mips/include/uapi/asm/swab.h @@ -8,14 +8,14 @@ #ifndef _ASM_SWAB_H #define _ASM_SWAB_H -#include <linux/compiler.h> + #include <linux/types.h> #define __SWAB_64_THRU_32__ #if defined(__mips_isa_rev) && (__mips_isa_rev >= 2) -static inline __attribute_const__ __u16 __arch_swab16(__u16 x) +static __inline__ __u16 __arch_swab16(__u16 x) { __asm__( " wsbh %0, %1 \n" @@ -26,7 +26,7 @@ static inline __attribute_const__ __u16 __arch_swab16(__u16 x) } #define __arch_swab16 __arch_swab16 -static inline __attribute_const__ __u32 __arch_swab32(__u32 x) +static __inline__ __u32 __arch_swab32(__u32 x) { __asm__( " wsbh %0, %1 \n" @@ -43,7 +43,7 @@ static inline __attribute_const__ __u32 __arch_swab32(__u32 x) * 64-bit kernel on r2 CPUs. */ #ifdef __mips64 -static inline __attribute_const__ __u64 __arch_swab64(__u64 x) +static __inline__ __u64 __arch_swab64(__u64 x) { __asm__( " dsbh %0, %1\n" diff --git a/arch/mips/include/uapi/asm/termios.h b/arch/mips/include/uapi/asm/termios.h index baeb2fa87451..36c1884cb7f3 100644 --- a/arch/mips/include/uapi/asm/termios.h +++ b/arch/mips/include/uapi/asm/termios.h @@ -6,8 +6,8 @@ * Copyright (C) 1995, 1996, 2000, 2001 by Ralf Baechle * Copyright (C) 2000, 2001 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_TERMIOS_H -#define _UAPI_ASM_TERMIOS_H +#ifndef _ASM_TERMIOS_H +#define _ASM_TERMIOS_H #include <linux/errno.h> #include <asm/termbits.h> @@ -77,4 +77,4 @@ struct termio { #define TIOCM_LOOP 0x8000 -#endif /* _UAPI_ASM_TERMIOS_H */ +#endif /* _ASM_TERMIOS_H */ diff --git a/arch/mips/include/uapi/asm/types.h b/arch/mips/include/uapi/asm/types.h index 7ac9d0baad84..21f80aaeef9b 100644 --- a/arch/mips/include/uapi/asm/types.h +++ b/arch/mips/include/uapi/asm/types.h @@ -8,20 +8,18 @@ * written by Ralf Baechle * Copyright (C) 1999 Silicon Graphics, Inc. */ -#ifndef _UAPI_ASM_TYPES_H -#define _UAPI_ASM_TYPES_H +#ifndef _ASM_TYPES_H +#define _ASM_TYPES_H /* * We don't use int-l64.h for the kernel anymore but still use it for * userspace to avoid code changes. */ -#ifndef __KERNEL__ # if _MIPS_SZLONG == 64 # include <asm-generic/int-l64.h> # else # include <asm-generic/int-ll64.h> # endif -#endif -#endif /* _UAPI_ASM_TYPES_H */ +#endif /* _ASM_TYPES_H */ diff --git a/arch/mips/include/uapi/asm/unistd.h b/arch/mips/include/uapi/asm/unistd.h index 1dee279f9665..acf4818e1b9b 100644 --- a/arch/mips/include/uapi/asm/unistd.h +++ b/arch/mips/include/uapi/asm/unistd.h @@ -9,8 +9,8 @@ * Changed system calls macros _syscall5 - _syscall7 to push args 5 to 7 onto * the stack. Robin Farine for ACN S.A, Copyright (C) 1996 by ACN S.A */ -#ifndef _UAPI_ASM_UNISTD_H -#define _UAPI_ASM_UNISTD_H +#ifndef _ASM_UNISTD_H +#define _ASM_UNISTD_H #include <asm/sgidefs.h> @@ -1036,4 +1036,4 @@ #define __NR_N32_Linux 6000 #define __NR_N32_Linux_syscalls 312 -#endif /* _UAPI_ASM_UNISTD_H */ +#endif /* _ASM_UNISTD_H */ diff --git a/arch/powerpc/include/asm/linkage.h b/arch/powerpc/include/asm/linkage.h index b36f650a13ff..167ceca08aa9 100644 --- a/arch/powerpc/include/asm/linkage.h +++ b/arch/powerpc/include/asm/linkage.h @@ -3,10 +3,10 @@ #ifdef CONFIG_PPC64 #define cond_syscall(x) \ - asm ("\t.weak " #x "\n\t.set " #x ", sys_ni_syscall\n" \ + __asm__ ("\t.weak " #x "\n\t.set " #x ", sys_ni_syscall\n" \ "\t.weak ." #x "\n\t.set ." #x ", .sys_ni_syscall\n") #define SYSCALL_ALIAS(alias, name) \ - asm ("\t.globl " #alias "\n\t.set " #alias ", " #name "\n" \ + __asm__ ("\t.globl " #alias "\n\t.set " #alias ", " #name "\n" \ "\t.globl ." #alias "\n\t.set ." #alias ", ." #name) #endif diff --git a/arch/powerpc/include/uapi/asm/bootx.h b/arch/powerpc/include/uapi/asm/bootx.h index 6e51cf0708a1..7f82d64acc2e 100644 --- a/arch/powerpc/include/uapi/asm/bootx.h +++ b/arch/powerpc/include/uapi/asm/bootx.h @@ -6,8 +6,8 @@ */ -#ifndef _UAPI__ASM_BOOTX_H__ -#define _UAPI__ASM_BOOTX_H__ +#ifndef __ASM_BOOTX_H__ +#define __ASM_BOOTX_H__ #include <linux/types.h> @@ -129,4 +129,4 @@ typedef struct boot_infos #pragma options align=reset #endif -#endif /* _UAPI__ASM_BOOTX_H__ */ +#endif /* __ASM_BOOTX_H__ */ diff --git a/arch/powerpc/include/uapi/asm/cputable.h b/arch/powerpc/include/uapi/asm/cputable.h index 5b7657959faa..8144a22c5587 100644 --- a/arch/powerpc/include/uapi/asm/cputable.h +++ b/arch/powerpc/include/uapi/asm/cputable.h @@ -1,5 +1,5 @@ -#ifndef _UAPI__ASM_POWERPC_CPUTABLE_H -#define _UAPI__ASM_POWERPC_CPUTABLE_H +#ifndef __ASM_POWERPC_CPUTABLE_H +#define __ASM_POWERPC_CPUTABLE_H /* in AT_HWCAP */ #define PPC_FEATURE_32 0x80000000 @@ -42,4 +42,4 @@ #define PPC_FEATURE2_ISEL 0x08000000 #define PPC_FEATURE2_TAR 0x04000000 -#endif /* _UAPI__ASM_POWERPC_CPUTABLE_H */ +#endif /* __ASM_POWERPC_CPUTABLE_H */ diff --git a/arch/powerpc/include/uapi/asm/elf.h b/arch/powerpc/include/uapi/asm/elf.h index 7e39c9146a71..36ff1f7fd16d 100644 --- a/arch/powerpc/include/uapi/asm/elf.h +++ b/arch/powerpc/include/uapi/asm/elf.h @@ -6,8 +6,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_ELF_H -#define _UAPI_ASM_POWERPC_ELF_H +#ifndef _ASM_POWERPC_ELF_H +#define _ASM_POWERPC_ELF_H #include <linux/types.h> @@ -303,4 +303,4 @@ struct ppc64_opd_entry }; -#endif /* _UAPI_ASM_POWERPC_ELF_H */ +#endif /* _ASM_POWERPC_ELF_H */ diff --git a/arch/powerpc/include/uapi/asm/epapr_hcalls.h b/arch/powerpc/include/uapi/asm/epapr_hcalls.h index 7f9c74b46704..06f724786a44 100644 --- a/arch/powerpc/include/uapi/asm/epapr_hcalls.h +++ b/arch/powerpc/include/uapi/asm/epapr_hcalls.h @@ -37,8 +37,8 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef _UAPI_ASM_POWERPC_EPAPR_HCALLS_H -#define _UAPI_ASM_POWERPC_EPAPR_HCALLS_H +#ifndef _ASM_POWERPC_EPAPR_HCALLS_H +#define _ASM_POWERPC_EPAPR_HCALLS_H #define EV_BYTE_CHANNEL_SEND 1 #define EV_BYTE_CHANNEL_RECEIVE 2 @@ -95,4 +95,4 @@ #define EV_UNIMPLEMENTED 12 /* Unimplemented hypercall */ #define EV_BUFFER_OVERFLOW 13 /* Caller-supplied buffer too small */ -#endif /* _UAPI_ASM_POWERPC_EPAPR_HCALLS_H */ +#endif /* _ASM_POWERPC_EPAPR_HCALLS_H */ diff --git a/arch/powerpc/include/uapi/asm/ioctls.h b/arch/powerpc/include/uapi/asm/ioctls.h index 49a25796a61a..d5b258cd9c37 100644 --- a/arch/powerpc/include/uapi/asm/ioctls.h +++ b/arch/powerpc/include/uapi/asm/ioctls.h @@ -114,6 +114,6 @@ #define TIOCSERSETMULTI 0x545B /* Set multiport config */ #define TIOCMIWAIT 0x545C /* wait for a change on serial input line(s) */ -#define TIOCGICOUNT 0x545D /* read serial port inline interrupt counts */ +#define TIOCGICOUNT 0x545D /* read serial port __inline__ interrupt counts */ #endif /* _ASM_POWERPC_IOCTLS_H */ diff --git a/arch/powerpc/include/uapi/asm/kvm_para.h b/arch/powerpc/include/uapi/asm/kvm_para.h index e3af3286a068..7e64f575f670 100644 --- a/arch/powerpc/include/uapi/asm/kvm_para.h +++ b/arch/powerpc/include/uapi/asm/kvm_para.h @@ -17,8 +17,8 @@ * Authors: Hollis Blanchard <hollisb@us.ibm.com> */ -#ifndef _UAPI__POWERPC_KVM_PARA_H__ -#define _UAPI__POWERPC_KVM_PARA_H__ +#ifndef __POWERPC_KVM_PARA_H__ +#define __POWERPC_KVM_PARA_H__ #include <linux/types.h> @@ -88,4 +88,4 @@ struct kvm_vcpu_arch_shared { #define KVM_MAGIC_FEAT_MAS0_TO_SPRG7 (1 << 1) -#endif /* _UAPI__POWERPC_KVM_PARA_H__ */ +#endif /* __POWERPC_KVM_PARA_H__ */ diff --git a/arch/powerpc/include/uapi/asm/mman.h b/arch/powerpc/include/uapi/asm/mman.h index 6ea26df0a73c..6fa6b6012f1f 100644 --- a/arch/powerpc/include/uapi/asm/mman.h +++ b/arch/powerpc/include/uapi/asm/mman.h @@ -4,8 +4,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_MMAN_H -#define _UAPI_ASM_POWERPC_MMAN_H +#ifndef _ASM_POWERPC_MMAN_H +#define _ASM_POWERPC_MMAN_H #include <asm-generic/mman-common.h> @@ -28,4 +28,4 @@ #define MAP_STACK 0x20000 /* give out an address that is best suited for process/thread stacks */ #define MAP_HUGETLB 0x40000 /* create a huge page mapping */ -#endif /* _UAPI_ASM_POWERPC_MMAN_H */ +#endif /* _ASM_POWERPC_MMAN_H */ diff --git a/arch/powerpc/include/uapi/asm/nvram.h b/arch/powerpc/include/uapi/asm/nvram.h index 608bdc8aedd1..a18abfc7cd83 100644 --- a/arch/powerpc/include/uapi/asm/nvram.h +++ b/arch/powerpc/include/uapi/asm/nvram.h @@ -7,8 +7,8 @@ * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_NVRAM_H -#define _UAPI_ASM_POWERPC_NVRAM_H +#ifndef _ASM_POWERPC_NVRAM_H +#define _ASM_POWERPC_NVRAM_H /* Signatures for nvram partitions */ #define NVRAM_SIG_SP 0x02 /* support processor */ @@ -59,4 +59,4 @@ struct pmac_machine_location { #define IOC_NVRAM_GET_OFFSET _IOWR('p', 0x42, int) /* Get NVRAM partition offset */ #define IOC_NVRAM_SYNC _IO('p', 0x43) /* Sync NVRAM image */ -#endif /* _UAPI_ASM_POWERPC_NVRAM_H */ +#endif /* _ASM_POWERPC_NVRAM_H */ diff --git a/arch/powerpc/include/uapi/asm/perf_event.h b/arch/powerpc/include/uapi/asm/perf_event.h index 80a4d40cf5bc..6c9ad175b25e 100644 --- a/arch/powerpc/include/uapi/asm/perf_event.h +++ b/arch/powerpc/include/uapi/asm/perf_event.h @@ -7,12 +7,12 @@ * License. */ -#ifndef _UAPI_ASM_POWERPC_PERF_EVENT_H -#define _UAPI_ASM_POWERPC_PERF_EVENT_H +#ifndef _ASM_POWERPC_PERF_EVENT_H +#define _ASM_POWERPC_PERF_EVENT_H /* * We use bit 63 of perf_event_attr.config as a flag to request EBB. */ #define PERF_EVENT_CONFIG_EBB_SHIFT 63 -#endif /* _UAPI_ASM_POWERPC_PERF_EVENT_H */ +#endif /* _ASM_POWERPC_PERF_EVENT_H */ diff --git a/arch/powerpc/include/uapi/asm/ptrace.h b/arch/powerpc/include/uapi/asm/ptrace.h index 77d2ed35b111..d216fe1fc874 100644 --- a/arch/powerpc/include/uapi/asm/ptrace.h +++ b/arch/powerpc/include/uapi/asm/ptrace.h @@ -4,7 +4,7 @@ * This struct defines the way the registers are stored on the * kernel stack during a system call or other kernel entry. * - * this should only contain volatile regs + * this should only contain __volatile__ regs * since we can keep non-volatile in the thread_struct * should set this up when only volatiles are saved * by intr code. @@ -20,8 +20,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_PTRACE_H -#define _UAPI_ASM_POWERPC_PTRACE_H +#ifndef _ASM_POWERPC_PTRACE_H +#define _ASM_POWERPC_PTRACE_H #include <linux/types.h> @@ -258,4 +258,4 @@ struct ppc_hw_breakpoint { #define PPC_BREAKPOINT_CONDITION_BE(n) \ (1<<((n)+PPC_BREAKPOINT_CONDITION_BE_SHIFT)) -#endif /* _UAPI_ASM_POWERPC_PTRACE_H */ +#endif /* _ASM_POWERPC_PTRACE_H */ diff --git a/arch/powerpc/include/uapi/asm/sigcontext.h b/arch/powerpc/include/uapi/asm/sigcontext.h index 9c1f24fd5d11..70c3dbf01dc1 100644 --- a/arch/powerpc/include/uapi/asm/sigcontext.h +++ b/arch/powerpc/include/uapi/asm/sigcontext.h @@ -7,7 +7,7 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#include <linux/compiler.h> + #include <asm/ptrace.h> #ifdef __powerpc64__ #include <asm/elf.h> @@ -21,7 +21,7 @@ struct sigcontext { #endif unsigned long handler; unsigned long oldmask; - struct pt_regs __user *regs; + struct pt_regs *regs; #ifdef __powerpc64__ elf_gregset_t gp_regs; elf_fpregset_t fp_regs; @@ -79,7 +79,7 @@ struct sigcontext { * backwards compatility to store VSR 0-31 doubleword 1 after the VMX * registers and vscr/vrsave. */ - elf_vrreg_t __user *v_regs; + elf_vrreg_t *v_regs; long vmx_reserve[ELF_NVRREG+ELF_NVRREG+32+1]; #endif }; diff --git a/arch/powerpc/include/uapi/asm/signal.h b/arch/powerpc/include/uapi/asm/signal.h index 6c69ee94fd8d..4cdbe24591e0 100644 --- a/arch/powerpc/include/uapi/asm/signal.h +++ b/arch/powerpc/include/uapi/asm/signal.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_POWERPC_SIGNAL_H -#define _UAPI_ASM_POWERPC_SIGNAL_H +#ifndef _ASM_POWERPC_SIGNAL_H +#define _ASM_POWERPC_SIGNAL_H #include <linux/types.h> @@ -90,7 +90,6 @@ typedef struct { #include <asm-generic/signal-defs.h> -#ifndef __KERNEL__ struct old_sigaction { __sighandler_t sa_handler; old_sigset_t sa_mask; @@ -104,10 +103,9 @@ struct sigaction { __sigrestore_t sa_restorer; sigset_t sa_mask; /* mask last for extensibility */ }; -#endif typedef struct sigaltstack { - void __user *ss_sp; + void *ss_sp; int ss_flags; size_t ss_size; } stack_t; @@ -134,4 +132,4 @@ struct sig_dbg_op { #define SIG_DBG_BRANCH_TRACING 2 #endif /* ! __powerpc64__ */ -#endif /* _UAPI_ASM_POWERPC_SIGNAL_H */ +#endif /* _ASM_POWERPC_SIGNAL_H */ diff --git a/arch/powerpc/include/uapi/asm/spu_info.h b/arch/powerpc/include/uapi/asm/spu_info.h index ed071bf97707..de8afe320247 100644 --- a/arch/powerpc/include/uapi/asm/spu_info.h +++ b/arch/powerpc/include/uapi/asm/spu_info.h @@ -20,19 +20,17 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -#ifndef _UAPI_SPU_INFO_H -#define _UAPI_SPU_INFO_H +#ifndef _SPU_INFO_H +#define _SPU_INFO_H #include <linux/types.h> -#ifndef __KERNEL__ struct mfc_cq_sr { __u64 mfc_cq_data0_RW; __u64 mfc_cq_data1_RW; __u64 mfc_cq_data2_RW; __u64 mfc_cq_data3_RW; }; -#endif /* __KERNEL__ */ struct spu_dma_info { __u64 dma_info_type; @@ -50,4 +48,4 @@ struct spu_proxydma_info { struct mfc_cq_sr proxydma_info_command_data[8]; }; -#endif /* _UAPI_SPU_INFO_H */ +#endif /* _SPU_INFO_H */ diff --git a/arch/powerpc/include/uapi/asm/swab.h b/arch/powerpc/include/uapi/asm/swab.h index b6c368aa5c05..3958720b6359 100644 --- a/arch/powerpc/include/uapi/asm/swab.h +++ b/arch/powerpc/include/uapi/asm/swab.h @@ -4,12 +4,12 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_SWAB_H -#define _UAPI_ASM_POWERPC_SWAB_H +#ifndef _ASM_POWERPC_SWAB_H +#define _ASM_POWERPC_SWAB_H #include <linux/types.h> -#include <linux/compiler.h> + #ifdef __GNUC__ @@ -20,4 +20,4 @@ #endif /* __GNUC__ */ -#endif /* _UAPI_ASM_POWERPC_SWAB_H */ +#endif /* _ASM_POWERPC_SWAB_H */ diff --git a/arch/powerpc/include/uapi/asm/termios.h b/arch/powerpc/include/uapi/asm/termios.h index 6cca5cdfec04..64fad8505aaf 100644 --- a/arch/powerpc/include/uapi/asm/termios.h +++ b/arch/powerpc/include/uapi/asm/termios.h @@ -9,8 +9,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_TERMIOS_H -#define _UAPI_ASM_POWERPC_TERMIOS_H +#ifndef _ASM_POWERPC_TERMIOS_H +#define _ASM_POWERPC_TERMIOS_H #include <asm/ioctls.h> @@ -73,4 +73,4 @@ struct termio { -#endif /* _UAPI_ASM_POWERPC_TERMIOS_H */ +#endif /* _ASM_POWERPC_TERMIOS_H */ diff --git a/arch/powerpc/include/uapi/asm/types.h b/arch/powerpc/include/uapi/asm/types.h index 4b8ab990a3c1..3ca9bbbbd844 100644 --- a/arch/powerpc/include/uapi/asm/types.h +++ b/arch/powerpc/include/uapi/asm/types.h @@ -10,8 +10,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_TYPES_H -#define _UAPI_ASM_POWERPC_TYPES_H +#ifndef _ASM_POWERPC_TYPES_H +#define _ASM_POWERPC_TYPES_H /* * This is here because we used to use l64 for 64bit powerpc @@ -37,4 +37,4 @@ typedef struct { #endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_POWERPC_TYPES_H */ +#endif /* _ASM_POWERPC_TYPES_H */ diff --git a/arch/powerpc/include/uapi/asm/ucontext.h b/arch/powerpc/include/uapi/asm/ucontext.h index d9a4ddf0cc86..11726716906f 100644 --- a/arch/powerpc/include/uapi/asm/ucontext.h +++ b/arch/powerpc/include/uapi/asm/ucontext.h @@ -19,11 +19,11 @@ struct mcontext { struct ucontext { unsigned long uc_flags; - struct ucontext __user *uc_link; + struct ucontext *uc_link; stack_t uc_stack; #ifndef __powerpc64__ int uc_pad[7]; - struct mcontext __user *uc_regs;/* points to uc_mcontext field */ + struct mcontext *uc_regs;/* points to uc_mcontext field */ #endif sigset_t uc_sigmask; /* glibc has 1024-bit signal masks, ours are 64-bit */ diff --git a/arch/powerpc/include/uapi/asm/unistd.h b/arch/powerpc/include/uapi/asm/unistd.h index 74cb4d72d673..46a9783d6da3 100644 --- a/arch/powerpc/include/uapi/asm/unistd.h +++ b/arch/powerpc/include/uapi/asm/unistd.h @@ -6,8 +6,8 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ -#ifndef _UAPI_ASM_POWERPC_UNISTD_H_ -#define _UAPI_ASM_POWERPC_UNISTD_H_ +#ifndef _ASM_POWERPC_UNISTD_H_ +#define _ASM_POWERPC_UNISTD_H_ #define __NR_restart_syscall 0 @@ -379,4 +379,4 @@ #define __NR_kcmp 354 -#endif /* _UAPI_ASM_POWERPC_UNISTD_H_ */ +#endif /* _ASM_POWERPC_UNISTD_H_ */ diff --git a/arch/x86/include/uapi/asm/boot.h b/arch/x86/include/uapi/asm/boot.h index 94292c4c8122..1f200ace58c5 100644 --- a/arch/x86/include/uapi/asm/boot.h +++ b/arch/x86/include/uapi/asm/boot.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_BOOT_H -#define _UAPI_ASM_X86_BOOT_H +#ifndef _ASM_X86_BOOT_H +#define _ASM_X86_BOOT_H /* Internal svga startup constants */ #define NORMAL_VGA 0xffff /* 80x25 mode */ @@ -7,4 +7,4 @@ #define ASK_VGA 0xfffd /* ask for it at bootup */ -#endif /* _UAPI_ASM_X86_BOOT_H */ +#endif /* _ASM_X86_BOOT_H */ diff --git a/arch/x86/include/uapi/asm/debugreg.h b/arch/x86/include/uapi/asm/debugreg.h index 3c0874dd9861..4cd9bd35bdb3 100644 --- a/arch/x86/include/uapi/asm/debugreg.h +++ b/arch/x86/include/uapi/asm/debugreg.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_DEBUGREG_H -#define _UAPI_ASM_X86_DEBUGREG_H +#ifndef _ASM_X86_DEBUGREG_H +#define _ASM_X86_DEBUGREG_H /* Indicate the register numbers for a number of the specific @@ -77,4 +77,4 @@ * HW breakpoint additions */ -#endif /* _UAPI_ASM_X86_DEBUGREG_H */ +#endif /* _ASM_X86_DEBUGREG_H */ diff --git a/arch/x86/include/uapi/asm/e820.h b/arch/x86/include/uapi/asm/e820.h index bbae02470701..cd8706e19512 100644 --- a/arch/x86/include/uapi/asm/e820.h +++ b/arch/x86/include/uapi/asm/e820.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_E820_H -#define _UAPI_ASM_X86_E820_H +#ifndef _ASM_X86_E820_H +#define _ASM_X86_E820_H #define E820MAP 0x2d0 /* our map */ #define E820MAX 128 /* number of entries in E820MAP */ @@ -26,9 +26,7 @@ * to collapse the next two #ifdef lines to a single line: * #if defined(__KERNEL__) && defined(CONFIG_EFI) */ -#ifndef __KERNEL__ #define E820_X_MAX E820MAX -#endif #define E820NR 0x1e8 /* # entries in E820MAP */ @@ -72,4 +70,4 @@ struct e820map { #endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_X86_E820_H */ +#endif /* _ASM_X86_E820_H */ diff --git a/arch/x86/include/uapi/asm/ist.h b/arch/x86/include/uapi/asm/ist.h index bad9f5ea4070..192dec3d69fd 100644 --- a/arch/x86/include/uapi/asm/ist.h +++ b/arch/x86/include/uapi/asm/ist.h @@ -12,8 +12,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * General Public License for more details. */ -#ifndef _UAPI_ASM_X86_IST_H -#define _UAPI_ASM_X86_IST_H +#ifndef _ASM_X86_IST_H +#define _ASM_X86_IST_H @@ -26,4 +26,4 @@ struct ist_info { __u32 perf_level; }; -#endif /* _UAPI_ASM_X86_IST_H */ +#endif /* _ASM_X86_IST_H */ diff --git a/arch/x86/include/uapi/asm/kvm_para.h b/arch/x86/include/uapi/asm/kvm_para.h index 94dc8ca434e0..e41c5c1a28da 100644 --- a/arch/x86/include/uapi/asm/kvm_para.h +++ b/arch/x86/include/uapi/asm/kvm_para.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_KVM_PARA_H -#define _UAPI_ASM_X86_KVM_PARA_H +#ifndef _ASM_X86_KVM_PARA_H +#define _ASM_X86_KVM_PARA_H #include <linux/types.h> #include <asm/hyperv.h> @@ -98,4 +98,4 @@ struct kvm_vcpu_pv_apf_data { #define KVM_PV_EOI_DISABLED 0x0 -#endif /* _UAPI_ASM_X86_KVM_PARA_H */ +#endif /* _ASM_X86_KVM_PARA_H */ diff --git a/arch/x86/include/uapi/asm/mce.h b/arch/x86/include/uapi/asm/mce.h index a0eab85ce7b8..46e0674ad046 100644 --- a/arch/x86/include/uapi/asm/mce.h +++ b/arch/x86/include/uapi/asm/mce.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_MCE_H -#define _UAPI_ASM_X86_MCE_H +#ifndef _ASM_X86_MCE_H +#define _ASM_X86_MCE_H #include <linux/types.h> #include <asm/ioctls.h> @@ -31,4 +31,4 @@ struct mce { #define MCE_GET_LOG_LEN _IOR('M', 2, int) #define MCE_GETCLEAR_FLAGS _IOR('M', 3, int) -#endif /* _UAPI_ASM_X86_MCE_H */ +#endif /* _ASM_X86_MCE_H */ diff --git a/arch/x86/include/uapi/asm/msr.h b/arch/x86/include/uapi/asm/msr.h index 155e51048fa4..f1aeaf77242c 100644 --- a/arch/x86/include/uapi/asm/msr.h +++ b/arch/x86/include/uapi/asm/msr.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_MSR_H -#define _UAPI_ASM_X86_MSR_H +#ifndef _ASM_X86_MSR_H +#define _ASM_X86_MSR_H #include <asm/msr-index.h> @@ -12,4 +12,4 @@ #define X86_IOC_WRMSR_REGS _IOWR('c', 0xA1, __u32[8]) #endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_X86_MSR_H */ +#endif /* _ASM_X86_MSR_H */ diff --git a/arch/x86/include/uapi/asm/mtrr.h b/arch/x86/include/uapi/asm/mtrr.h index d0acb658c8f4..a39f6438bd3c 100644 --- a/arch/x86/include/uapi/asm/mtrr.h +++ b/arch/x86/include/uapi/asm/mtrr.h @@ -20,8 +20,8 @@ The postal address is: Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. */ -#ifndef _UAPI_ASM_X86_MTRR_H -#define _UAPI_ASM_X86_MTRR_H +#ifndef _ASM_X86_MTRR_H +#define _ASM_X86_MTRR_H #include <linux/types.h> #include <linux/ioctl.h> @@ -114,4 +114,4 @@ struct mtrr_state_type { #define MTRR_NUM_TYPES 7 -#endif /* _UAPI_ASM_X86_MTRR_H */ +#endif /* _ASM_X86_MTRR_H */ diff --git a/arch/x86/include/uapi/asm/posix_types.h b/arch/x86/include/uapi/asm/posix_types.h index 85506b383627..9b4a886ffd8b 100644 --- a/arch/x86/include/uapi/asm/posix_types.h +++ b/arch/x86/include/uapi/asm/posix_types.h @@ -1,4 +1,3 @@ -#ifndef __KERNEL__ # ifdef __i386__ # include <asm/posix_types_32.h> # elif defined(__ILP32__) @@ -6,4 +5,3 @@ # else # include <asm/posix_types_64.h> # endif -#endif diff --git a/arch/x86/include/uapi/asm/processor-flags.h b/arch/x86/include/uapi/asm/processor-flags.h index 180a0c3c224d..de35a8e0c38f 100644 --- a/arch/x86/include/uapi/asm/processor-flags.h +++ b/arch/x86/include/uapi/asm/processor-flags.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_PROCESSOR_FLAGS_H -#define _UAPI_ASM_X86_PROCESSOR_FLAGS_H +#ifndef _ASM_X86_PROCESSOR_FLAGS_H +#define _ASM_X86_PROCESSOR_FLAGS_H /* Various flags defined: can be included from assembler. */ #include <linux/const.h> @@ -150,4 +150,4 @@ #define CX86_RCR_BASE 0xdc -#endif /* _UAPI_ASM_X86_PROCESSOR_FLAGS_H */ +#endif /* _ASM_X86_PROCESSOR_FLAGS_H */ diff --git a/arch/x86/include/uapi/asm/ptrace.h b/arch/x86/include/uapi/asm/ptrace.h index ac4b9aa4d999..4dc18e96d5f5 100644 --- a/arch/x86/include/uapi/asm/ptrace.h +++ b/arch/x86/include/uapi/asm/ptrace.h @@ -1,7 +1,7 @@ -#ifndef _UAPI_ASM_X86_PTRACE_H -#define _UAPI_ASM_X86_PTRACE_H +#ifndef _ASM_X86_PTRACE_H +#define _ASM_X86_PTRACE_H -#include <linux/compiler.h> /* For __user */ + /* For */ #include <asm/ptrace-abi.h> #include <asm/processor-flags.h> @@ -12,7 +12,6 @@ /* this struct defines the way the registers are stored on the stack during a system call. */ -#ifndef __KERNEL__ struct pt_regs { long ebx; @@ -34,11 +33,9 @@ struct pt_regs { int xss; }; -#endif /* __KERNEL__ */ #else /* __i386__ */ -#ifndef __KERNEL__ struct pt_regs { unsigned long r15; @@ -68,11 +65,10 @@ struct pt_regs { /* top of stack page */ }; -#endif /* __KERNEL__ */ #endif /* !__i386__ */ #endif /* !__ASSEMBLY__ */ -#endif /* _UAPI_ASM_X86_PTRACE_H */ +#endif /* _ASM_X86_PTRACE_H */ diff --git a/arch/x86/include/uapi/asm/sigcontext.h b/arch/x86/include/uapi/asm/sigcontext.h index d8b9f9081e86..a6193135f319 100644 --- a/arch/x86/include/uapi/asm/sigcontext.h +++ b/arch/x86/include/uapi/asm/sigcontext.h @@ -1,7 +1,7 @@ -#ifndef _UAPI_ASM_X86_SIGCONTEXT_H -#define _UAPI_ASM_X86_SIGCONTEXT_H +#ifndef _ASM_X86_SIGCONTEXT_H +#define _ASM_X86_SIGCONTEXT_H + -#include <linux/compiler.h> #include <linux/types.h> #define FP_XSTATE_MAGIC1 0x46505853U @@ -98,7 +98,6 @@ struct _fpstate { #define X86_FXSR_MAGIC 0x0000 -#ifndef __KERNEL__ /* * User-space might still rely on the old definition: */ @@ -122,11 +121,10 @@ struct sigcontext { unsigned long eflags; unsigned long esp_at_signal; unsigned short ss, __ssh; - struct _fpstate __user *fpstate; + struct _fpstate *fpstate; unsigned long oldmask; unsigned long cr2; }; -#endif /* !__KERNEL__ */ #else /* __i386__ */ @@ -153,7 +151,6 @@ struct _fpstate { }; }; -#ifndef __KERNEL__ /* * User-space might still rely on the old definition: */ @@ -184,13 +181,12 @@ struct sigcontext { __u64 trapno; __u64 oldmask; __u64 cr2; - struct _fpstate __user *fpstate; /* zero when no FPU context */ + struct _fpstate *fpstate; /* zero when no FPU context */ #ifdef __ILP32__ __u32 __fpstate_pad; #endif __u64 reserved1[8]; }; -#endif /* !__KERNEL__ */ #endif /* !__i386__ */ @@ -218,4 +214,4 @@ struct _xstate { /* new processor state extensions go here */ }; -#endif /* _UAPI_ASM_X86_SIGCONTEXT_H */ +#endif /* _ASM_X86_SIGCONTEXT_H */ diff --git a/arch/x86/include/uapi/asm/signal.h b/arch/x86/include/uapi/asm/signal.h index 8264f47cf53e..facdb433a0e9 100644 --- a/arch/x86/include/uapi/asm/signal.h +++ b/arch/x86/include/uapi/asm/signal.h @@ -1,21 +1,19 @@ -#ifndef _UAPI_ASM_X86_SIGNAL_H -#define _UAPI_ASM_X86_SIGNAL_H +#ifndef _ASM_X86_SIGNAL_H +#define _ASM_X86_SIGNAL_H #ifndef __ASSEMBLY__ #include <linux/types.h> #include <linux/time.h> -#include <linux/compiler.h> + /* Avoid too many header ordering problems. */ struct siginfo; -#ifndef __KERNEL__ /* Here we must cater to libcs that poke about in kernel headers. */ #define NSIG 32 typedef unsigned long sigset_t; -#endif /* __KERNEL__ */ #endif /* __ASSEMBLY__ */ @@ -95,7 +93,6 @@ typedef unsigned long sigset_t; #ifndef __ASSEMBLY__ -# ifndef __KERNEL__ /* Here we must cater to libcs that poke about in kernel headers. */ #ifdef __i386__ @@ -122,14 +119,13 @@ struct sigaction { }; #endif /* !__i386__ */ -# endif /* ! __KERNEL__ */ typedef struct sigaltstack { - void __user *ss_sp; + void *ss_sp; int ss_flags; size_t ss_size; } stack_t; #endif /* __ASSEMBLY__ */ -#endif /* _UAPI_ASM_X86_SIGNAL_H */ +#endif /* _ASM_X86_SIGNAL_H */ diff --git a/arch/x86/include/uapi/asm/svm.h b/arch/x86/include/uapi/asm/svm.h index b5d7640abc5d..ff6edd617d1b 100644 --- a/arch/x86/include/uapi/asm/svm.h +++ b/arch/x86/include/uapi/asm/svm.h @@ -1,5 +1,5 @@ -#ifndef _UAPI__SVM_H -#define _UAPI__SVM_H +#ifndef __SVM_H +#define __SVM_H #define SVM_EXIT_READ_CR0 0x000 #define SVM_EXIT_READ_CR3 0x003 @@ -129,4 +129,4 @@ { SVM_EXIT_NPF, "npf" } -#endif /* _UAPI__SVM_H */ +#endif /* __SVM_H */ diff --git a/arch/x86/include/uapi/asm/swab.h b/arch/x86/include/uapi/asm/swab.h index 7f235c7105c1..d1b09bf3d1cb 100644 --- a/arch/x86/include/uapi/asm/swab.h +++ b/arch/x86/include/uapi/asm/swab.h @@ -2,16 +2,16 @@ #define _ASM_X86_SWAB_H #include <linux/types.h> -#include <linux/compiler.h> -static inline __attribute_const__ __u32 __arch_swab32(__u32 val) + +static __inline__ __u32 __arch_swab32(__u32 val) { - asm("bswapl %0" : "=r" (val) : "0" (val)); + __asm__("bswapl %0" : "=r" (val) : "0" (val)); return val; } #define __arch_swab32 __arch_swab32 -static inline __attribute_const__ __u64 __arch_swab64(__u64 val) +static __inline__ __u64 __arch_swab64(__u64 val) { #ifdef __i386__ union { @@ -22,12 +22,12 @@ static inline __attribute_const__ __u64 __arch_swab64(__u64 val) __u64 u; } v; v.u = val; - asm("bswapl %0 ; bswapl %1 ; xchgl %0,%1" + __asm__("bswapl %0 ; bswapl %1 ; xchgl %0,%1" : "=r" (v.s.a), "=r" (v.s.b) : "0" (v.s.a), "1" (v.s.b)); return v.u; #else /* __i386__ */ - asm("bswapq %0" : "=r" (val) : "0" (val)); + __asm__("bswapq %0" : "=r" (val) : "0" (val)); return val; #endif } diff --git a/arch/x86/include/uapi/asm/unistd.h b/arch/x86/include/uapi/asm/unistd.h index a26df0d75cd0..1f99b12843ae 100644 --- a/arch/x86/include/uapi/asm/unistd.h +++ b/arch/x86/include/uapi/asm/unistd.h @@ -1,10 +1,9 @@ -#ifndef _UAPI_ASM_X86_UNISTD_H -#define _UAPI_ASM_X86_UNISTD_H +#ifndef _ASM_X86_UNISTD_H +#define _ASM_X86_UNISTD_H /* x32 syscall flag bit */ #define __X32_SYSCALL_BIT 0x40000000 -#ifndef __KERNEL__ # ifdef __i386__ # include <asm/unistd_32.h> # elif defined(__ILP32__) @@ -12,6 +11,5 @@ # else # include <asm/unistd_64.h> # endif -#endif -#endif /* _UAPI_ASM_X86_UNISTD_H */ +#endif /* _ASM_X86_UNISTD_H */ diff --git a/arch/x86/include/uapi/asm/vm86.h b/arch/x86/include/uapi/asm/vm86.h index e0b243e9d859..211da113fb7c 100644 --- a/arch/x86/include/uapi/asm/vm86.h +++ b/arch/x86/include/uapi/asm/vm86.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_VM86_H -#define _UAPI_ASM_X86_VM86_H +#ifndef _ASM_X86_VM86_H +#define _ASM_X86_VM86_H /* * I'm guessing at the VIF/VIP flag usage, but hope that this is how @@ -126,4 +126,4 @@ struct vm86plus_struct { }; -#endif /* _UAPI_ASM_X86_VM86_H */ +#endif /* _ASM_X86_VM86_H */ diff --git a/arch/x86/include/uapi/asm/vmx.h b/arch/x86/include/uapi/asm/vmx.h index 0e79420376eb..89c1fc92838f 100644 --- a/arch/x86/include/uapi/asm/vmx.h +++ b/arch/x86/include/uapi/asm/vmx.h @@ -21,8 +21,8 @@ * Yaniv Kamay <yaniv@qumranet.com> * */ -#ifndef _UAPIVMX_H -#define _UAPIVMX_H +#ifndef VMX_H +#define VMX_H #define VMX_EXIT_REASONS_FAILED_VMENTRY 0x80000000 @@ -116,4 +116,4 @@ { EXIT_REASON_INVD, "INVD" }, \ { EXIT_REASON_INVPCID, "INVPCID" } -#endif /* _UAPIVMX_H */ +#endif /* VMX_H */ diff --git a/arch/x86/include/uapi/asm/vsyscall.h b/arch/x86/include/uapi/asm/vsyscall.h index 85dc1b3825ab..a565bb198087 100644 --- a/arch/x86/include/uapi/asm/vsyscall.h +++ b/arch/x86/include/uapi/asm/vsyscall.h @@ -1,5 +1,5 @@ -#ifndef _UAPI_ASM_X86_VSYSCALL_H -#define _UAPI_ASM_X86_VSYSCALL_H +#ifndef _ASM_X86_VSYSCALL_H +#define _ASM_X86_VSYSCALL_H enum vsyscall_num { __NR_vgettimeofday, @@ -14,4 +14,4 @@ enum vsyscall_num { #define VSYSCALL_ADDR(vsyscall_nr) (VSYSCALL_START+VSYSCALL_SIZE*(vsyscall_nr)) -#endif /* _UAPI_ASM_X86_VSYSCALL_H */ +#endif /* _ASM_X86_VSYSCALL_H */ |