]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
Merge tag 'x86-entry-2020-03-30' of git://git.kernel.org/pub/scm/linux/kernel/git...
authorLinus Torvalds <torvalds@linux-foundation.org>
Tue, 31 Mar 2020 02:14:28 +0000 (19:14 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 31 Mar 2020 02:14:28 +0000 (19:14 -0700)
Pull x86 entry code updates from Thomas Gleixner:

 - Convert the 32bit syscalls to be pt_regs based which removes the
   requirement to push all 6 potential arguments onto the stack and
   consolidates the interface with the 64bit variant

 - The first small portion of the exception and syscall related entry
   code consolidation which aims to address the recently discovered
   issues vs. RCU, int3, NMI and some other exceptions which can
   interrupt any context. The bulk of the changes is still work in
   progress and aimed for 5.8.

 - A few lockdep namespace cleanups which have been applied into this
   branch to keep the prerequisites for the ongoing work confined.

* tag 'x86-entry-2020-03-30' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (35 commits)
  x86/entry: Fix build error x86 with !CONFIG_POSIX_TIMERS
  lockdep: Rename trace_{hard,soft}{irq_context,irqs_enabled}()
  lockdep: Rename trace_softirqs_{on,off}()
  lockdep: Rename trace_hardirq_{enter,exit}()
  x86/entry: Rename ___preempt_schedule
  x86: Remove unneeded includes
  x86/entry: Drop asmlinkage from syscalls
  x86/entry/32: Enable pt_regs based syscalls
  x86/entry/32: Use IA32-specific wrappers for syscalls taking 64-bit arguments
  x86/entry/32: Rename 32-bit specific syscalls
  x86/entry/32: Clean up syscall_32.tbl
  x86/entry: Remove ABI prefixes from functions in syscall tables
  x86/entry/64: Add __SYSCALL_COMMON()
  x86/entry: Remove syscall qualifier support
  x86/entry/64: Remove ptregs qualifier from syscall table
  x86/entry: Move max syscall number calculation to syscallhdr.sh
  x86/entry/64: Split X32 syscall table into its own file
  x86/entry/64: Move sys_ni_syscall stub to common.c
  x86/entry/64: Use syscall wrappers for x32_rt_sigreturn
  x86/entry: Refactor SYS_NI macros
  ...

1  2 
arch/x86/Kconfig
arch/x86/include/asm/mce.h
arch/x86/kernel/Makefile
arch/x86/kernel/asm-offsets_32.c
arch/x86/kernel/cpu/mce/core.c
arch/x86/kernel/cpu/mce/internal.h
arch/x86/kernel/process.c
include/linux/irqflags.h
kernel/irq/handle.c
kernel/locking/lockdep.c

Simple merge
Simple merge
Simple merge
index 2b4256ebe86ecfd0f9ccf610018709001d14bf62,0dcac420b34146d8b2b58808ae7065c4b6a0d03d..6e043f295a6053a1d24a0dc9bde0abbceca06eef
@@@ -3,15 -3,8 +3,10 @@@
  # error "Please do not build this file directly, build asm-offsets.c instead"
  #endif
  
 +#include <linux/efi.h>
 +
  #include <asm/ucontext.h>
  
- #define __SYSCALL_I386(nr, sym, qual) [nr] = 1,
- static char syscalls[] = {
- #include <asm/syscalls_32.h>
- };
  /* workaround for a warning with -Wmissing-prototypes */
  void foo(void);
  
@@@ -62,11 -55,4 +57,7 @@@ void foo(void
        BLANK();
        OFFSET(stack_canary_offset, stack_canary, canary);
  #endif
-       BLANK();
-       DEFINE(__NR_syscall_max, sizeof(syscalls) - 1);
-       DEFINE(NR_syscalls, sizeof(syscalls));
 +
 +      BLANK();
 +      DEFINE(EFI_svam, offsetof(efi_runtime_services_t, set_virtual_address_map));
  }
Simple merge
Simple merge
Simple merge
index a16adbb58f66abd2d0690f0ca43cb98f6ca3049d,f4c3907e241a677cf26b29cc5f673c91f023a6fa..ceca42de443819b0740c13bb242c4ec803049ac0
  #ifdef CONFIG_TRACE_IRQFLAGS
    extern void trace_hardirqs_on(void);
    extern void trace_hardirqs_off(void);
- # define trace_hardirq_context(p)     ((p)->hardirq_context)
- # define trace_softirq_context(p)     ((p)->softirq_context)
- # define trace_hardirqs_enabled(p)    ((p)->hardirqs_enabled)
- # define trace_softirqs_enabled(p)    ((p)->softirqs_enabled)
- # define trace_hardirq_enter()                        \
+ # define lockdep_hardirq_context(p)   ((p)->hardirq_context)
+ # define lockdep_softirq_context(p)   ((p)->softirq_context)
+ # define lockdep_hardirqs_enabled(p)  ((p)->hardirqs_enabled)
+ # define lockdep_softirqs_enabled(p)  ((p)->softirqs_enabled)
+ # define lockdep_hardirq_enter()              \
  do {                                          \
 -      current->hardirq_context++;             \
 +      if (!current->hardirq_context++)        \
 +              current->hardirq_threaded = 0;  \
 +} while (0)
- # define trace_hardirq_threaded()             \
++# define lockdep_hardirq_threaded()           \
 +do {                                          \
 +      current->hardirq_threaded = 1;          \
  } while (0)
- # define trace_hardirq_exit()                 \
+ # define lockdep_hardirq_exit()                       \
  do {                                          \
        current->hardirq_context--;             \
  } while (0)
@@@ -93,21 -54,14 +93,21 @@@ do {                                               
  #else
  # define trace_hardirqs_on()          do { } while (0)
  # define trace_hardirqs_off()         do { } while (0)
- # define trace_hardirq_context(p)     0
- # define trace_softirq_context(p)     0
- # define trace_hardirqs_enabled(p)    0
- # define trace_softirqs_enabled(p)    0
- # define trace_hardirq_enter()                do { } while (0)
- # define trace_hardirq_threaded()     do { } while (0)
- # define trace_hardirq_exit()         do { } while (0)
+ # define lockdep_hardirq_context(p)   0
+ # define lockdep_softirq_context(p)   0
+ # define lockdep_hardirqs_enabled(p)  0
+ # define lockdep_softirqs_enabled(p)  0
+ # define lockdep_hardirq_enter()      do { } while (0)
++# define lockdep_hardirq_threaded()   do { } while (0)
+ # define lockdep_hardirq_exit()               do { } while (0)
  # define lockdep_softirq_enter()      do { } while (0)
  # define lockdep_softirq_exit()               do { } while (0)
 +# define lockdep_hrtimer_enter(__hrtimer)             do { } while (0)
 +# define lockdep_hrtimer_exit(__hrtimer)              do { } while (0)
 +# define lockdep_posixtimer_enter()           do { } while (0)
 +# define lockdep_posixtimer_exit()            do { } while (0)
 +# define lockdep_irq_work_enter(__work)               do { } while (0)
 +# define lockdep_irq_work_exit(__work)                do { } while (0)
  #endif
  
  #if defined(CONFIG_IRQSOFF_TRACER) || \
index 16ee716e82917920fa39cf2c6d983110b0accd59,a4ace611f47fe93130fc4d2a6f494d89ae8ca80b..a8e14c80b405bdcf37cd37fb9b74250660513b1c
@@@ -145,13 -145,6 +145,13 @@@ irqreturn_t __handle_irq_event_percpu(s
        for_each_action_of_desc(desc, action) {
                irqreturn_t res;
  
-                       trace_hardirq_threaded();
 +              /*
 +               * If this IRQ would be threaded under force_irqthreads, mark it so.
 +               */
 +              if (irq_settings_can_thread(desc) &&
 +                  !(action->flags & (IRQF_NO_THREAD | IRQF_PERCPU | IRQF_ONESHOT)))
++                      lockdep_hardirq_threaded();
 +
                trace_irq_handler_entry(irq, action);
                res = action->handler(irq, action->dev_id);
                trace_irq_handler_exit(irq, action, res);
Simple merge