aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2018-04-15 19:12:35 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2018-04-15 19:12:35 -0400
commit9fb71c2f230df44bdd237e9a4457849a3909017d (patch)
treeacf07cd9a8ba343d131afa3330bf148bacc72e7a /kernel
parent6b0a02e86c293c32a50d49b33a1f04420585d40b (diff)
parentef389b734691cdc8beb009dd402135dcdcb86a56 (diff)
Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 fixes from Thomas Gleixner: "A set of fixes and updates for x86: - Address a swiotlb regression which was caused by the recent DMA rework and made driver fail because dma_direct_supported() returned false - Fix a signedness bug in the APIC ID validation which caused invalid APIC IDs to be detected as valid thereby bloating the CPU possible space. - Fix inconsisten config dependcy/select magic for the MFD_CS5535 driver. - Fix a corruption of the physical address space bits when encryption has reduced the address space and late cpuinfo updates overwrite the reduced bit information with the original value. - Dominiks syscall rework which consolidates the architecture specific syscall functions so all syscalls can be wrapped with the same macros. This allows to switch x86/64 to struct pt_regs based syscalls. Extend the clearing of user space controlled registers in the entry patch to the lower registers" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/apic: Fix signedness bug in APIC ID validity checks x86/cpu: Prevent cpuinfo_x86::x86_phys_bits adjustment corruption x86/olpc: Fix inconsistent MFD_CS5535 configuration swiotlb: Use dma_direct_supported() for swiotlb_ops syscalls/x86: Adapt syscall_wrapper.h to the new syscall stub naming convention syscalls/core, syscalls/x86: Rename struct pt_regs-based sys_*() to __x64_sys_*() syscalls/core, syscalls/x86: Clean up compat syscall stub naming convention syscalls/core, syscalls/x86: Clean up syscall stub naming convention syscalls/x86: Extend register clearing on syscall entry to lower registers syscalls/x86: Unconditionally enable 'struct pt_regs' based syscalls on x86_64 syscalls/x86: Use 'struct pt_regs' based syscall calling for IA32_EMULATION and x32 syscalls/core: Prepare CONFIG_ARCH_HAS_SYSCALL_WRAPPER=y for compat syscalls syscalls/x86: Use 'struct pt_regs' based syscall calling convention for 64-bit syscalls syscalls/core: Introduce CONFIG_ARCH_HAS_SYSCALL_WRAPPER=y x86/syscalls: Don't pointlessly reload the system call number x86/mm: Fix documentation of module mapping range with 4-level paging x86/cpuid: Switch to 'static const' specifier
Diffstat (limited to 'kernel')
-rw-r--r--kernel/sys_ni.c10
-rw-r--r--kernel/time/posix-stubs.c10
2 files changed, 20 insertions, 0 deletions
diff --git a/kernel/sys_ni.c b/kernel/sys_ni.c
index 6cafc008f6db..9791364925dc 100644
--- a/kernel/sys_ni.c
+++ b/kernel/sys_ni.c
@@ -5,6 +5,11 @@
5 5
6#include <asm/unistd.h> 6#include <asm/unistd.h>
7 7
8#ifdef CONFIG_ARCH_HAS_SYSCALL_WRAPPER
9/* Architectures may override COND_SYSCALL and COND_SYSCALL_COMPAT */
10#include <asm/syscall_wrapper.h>
11#endif /* CONFIG_ARCH_HAS_SYSCALL_WRAPPER */
12
8/* we can't #include <linux/syscalls.h> here, 13/* we can't #include <linux/syscalls.h> here,
9 but tell gcc to not warn with -Wmissing-prototypes */ 14 but tell gcc to not warn with -Wmissing-prototypes */
10asmlinkage long sys_ni_syscall(void); 15asmlinkage long sys_ni_syscall(void);
@@ -17,8 +22,13 @@ asmlinkage long sys_ni_syscall(void)
17 return -ENOSYS; 22 return -ENOSYS;
18} 23}
19 24
25#ifndef COND_SYSCALL
20#define COND_SYSCALL(name) cond_syscall(sys_##name) 26#define COND_SYSCALL(name) cond_syscall(sys_##name)
27#endif /* COND_SYSCALL */
28
29#ifndef COND_SYSCALL_COMPAT
21#define COND_SYSCALL_COMPAT(name) cond_syscall(compat_sys_##name) 30#define COND_SYSCALL_COMPAT(name) cond_syscall(compat_sys_##name)
31#endif /* COND_SYSCALL_COMPAT */
22 32
23/* 33/*
24 * This list is kept in the same order as include/uapi/asm-generic/unistd.h. 34 * This list is kept in the same order as include/uapi/asm-generic/unistd.h.
diff --git a/kernel/time/posix-stubs.c b/kernel/time/posix-stubs.c
index 6259dbc0191a..e0dbae98db9d 100644
--- a/kernel/time/posix-stubs.c
+++ b/kernel/time/posix-stubs.c
@@ -19,6 +19,11 @@
19#include <linux/posix-timers.h> 19#include <linux/posix-timers.h>
20#include <linux/compat.h> 20#include <linux/compat.h>
21 21
22#ifdef CONFIG_ARCH_HAS_SYSCALL_WRAPPER
23/* Architectures may override SYS_NI and COMPAT_SYS_NI */
24#include <asm/syscall_wrapper.h>
25#endif
26
22asmlinkage long sys_ni_posix_timers(void) 27asmlinkage long sys_ni_posix_timers(void)
23{ 28{
24 pr_err_once("process %d (%s) attempted a POSIX timer syscall " 29 pr_err_once("process %d (%s) attempted a POSIX timer syscall "
@@ -27,8 +32,13 @@ asmlinkage long sys_ni_posix_timers(void)
27 return -ENOSYS; 32 return -ENOSYS;
28} 33}
29 34
35#ifndef SYS_NI
30#define SYS_NI(name) SYSCALL_ALIAS(sys_##name, sys_ni_posix_timers) 36#define SYS_NI(name) SYSCALL_ALIAS(sys_##name, sys_ni_posix_timers)
37#endif
38
39#ifndef COMPAT_SYS_NI
31#define COMPAT_SYS_NI(name) SYSCALL_ALIAS(compat_sys_##name, sys_ni_posix_timers) 40#define COMPAT_SYS_NI(name) SYSCALL_ALIAS(compat_sys_##name, sys_ni_posix_timers)
41#endif
32 42
33SYS_NI(timer_create); 43SYS_NI(timer_create);
34SYS_NI(timer_gettime); 44SYS_NI(timer_gettime);