Skip to content

Preparatory patches for x86 KAISER support

Ingo Molnar lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest21 patches 13 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/21x86/unwinder/orc: Don't bail on stack overflowarch/x86/kernel/unwind_orc.c+12 -21 reply
2/21x86/unwinder: Handle stack overflows more gracefullyarch/x86/include/asm/kdebug.h arch/x86/include/asm/unwind.h arch/x86/kernel/dumpstack.c +3 more+66 -612 replies
3/21x86/irq: Remove an old outdated comment about context tracking racesarch/x86/kernel/irq.c+0 -120 replies
4/21x86/irq/64: Print the offending IP in the stack overflow warningarch/x86/kernel/irq_64.c+2 -20 replies
5/21x86/entry/64: Allocate and enable the SYSENTER stackarch/x86/entry/entry_64_compat.S arch/x86/include/asm/processor.h arch/x86/kernel/asm-offsets.c +4 more+10 -140 replies
6/21x86/dumpstack: Add get_stack_info() support for the SYSENTER stackarch/x86/include/asm/stacktrace.h arch/x86/kernel/dumpstack.c arch/x86/kernel/dumpstack_32.c +1 more+34 -00 replies
7/21x86/entry/gdt: Put per-CPU GDT remaps in ascending orderarch/x86/include/asm/desc.h+1 -10 replies
8/21x86/mm/fixmap: Generalize the GDT fixmap mechanism, introduce 'struct cpu_entry_area'arch/x86/include/asm/desc.h arch/x86/include/asm/fixmap.h arch/x86/kernel/cpu/common.c +1 more+44 -180 replies
9/21x86/kasan/64: Teach KASAN about the cpu_entry_areaarch/x86/mm/kasan_init_64.c+17 -10 replies
10/21x86/entry: Fix assumptions that the HW TSS is at the beginning of cpu_tssarch/x86/include/asm/desc.h arch/x86/include/asm/processor.h arch/x86/kernel/cpu/common.c +2 more+36 -320 replies
11/21x86/dumpstack: Handle stack overflow on all stacksarch/x86/kernel/dumpstack.c+14 -104 replies
12/21x86/entry: Move SYSENTER_stack to the beginning of struct tss_structarch/x86/include/asm/processor.h arch/x86/kernel/cpu/common.c+33 -90 replies
13/21x86/entry: Remap the TSS into the CPU entry areaarch/x86/entry/entry_32.S arch/x86/include/asm/fixmap.h arch/x86/kernel/asm-offsets.c +3 more+54 -140 replies
14/21x86/entry/64: Separate cpu_current_top_of_stack from TSS.sp0arch/x86/include/asm/processor.h arch/x86/include/asm/thread_info.h arch/x86/kernel/asm-offsets_64.c +2 more+26 -60 replies
15/21x86/espfix/64: Stop assuming that pt_regs is on the entry stackarch/x86/kernel/traps.c+28 -90 replies
16/21x86/entry/64: Use a per-CPU trampoline stack for IDT entriesarch/x86/entry/entry_64.S arch/x86/entry/entry_64_compat.S arch/x86/include/asm/switch_to.h +3 more+65 -295 replies
17/21x86/entry/64: Return to userspace from the trampoline stackarch/x86/entry/entry_64.S+51 -40 replies
18/21x86/entry/64: Create a per-CPU SYSCALL entry trampolinearch/x86/entry/entry_64.S arch/x86/include/asm/fixmap.h arch/x86/kernel/asm-offsets.c +2 more+74 -10 replies
19/21x86/entry/64: Move the IST stacks into 'struct cpu_entry_area'arch/x86/include/asm/fixmap.h arch/x86/kernel/cpu/common.c+35 -150 replies
20/21x86/entry/64: Remove the SYSENTER stack canaryarch/x86/include/asm/processor.h arch/x86/kernel/dumpstack.c arch/x86/kernel/process.c +1 more+1 -110 replies
21/21x86/entry: Clean up the SYSENTER_stack codearch/x86/entry/entry_32.S arch/x86/entry/entry_64.S arch/x86/include/asm/fixmap.h +4 more+21 -231 reply

Reviews trailers per patch

19 of 21 patches have a Reviewed-by or Acked-by.

PatchThomas GleixnerBorislav PetkovDave Hansen
1/21
2/21R-b
3/21R-b R-b
4/21R-b R-b
5/21R-b R-b
6/21R-b
7/21R-b R-b
8/21R-b R-b
9/21
10/21R-b R-b R-b
11/21R-b
12/21R-b R-b
13/21R-b
14/21R-b R-b
15/21R-b R-b
16/21R-b R-b
17/21R-b R-b
18/21R-b R-b
19/21R-b R-b
20/21R-b R-b
21/21R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v1 thread

Cover letter [PATCH 00/21] Preparatory patches for x86 KAISER support

This is mostly Andy's syscall trampoline stack patches, but also some other preparatory cleanups and enhancements.

Sending this separately to make it (slightly) easier to review.

The Git version of the full queue can be found at:

git git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git WIP.x86/mm

Thanks,

Ingo

=============>

Andy Lutomirski (20):
x86/unwinder/orc: Don't bail on stack overflow
x86/irq: Remove an old outdated comment about context tracking races x86/irq/64: Print the offending IP in the stack overflow warning x86/entry/64: Allocate and enable the SYSENTER stack
x86/dumpstack: Add get_stack_info() support for the SYSENTER stack x86/entry/gdt: Put per-CPU GDT remaps in ascending order
x86/mm/fixmap: Generalize the GDT fixmap mechanism, introduce 'struct cpu_entry_area' x86/kasan/64: Teach KASAN about the cpu_entry_area
x86/entry: Fix assumptions that the HW TSS is at the beginning of cpu_tss x86/dumpstack: Handle stack overflow on all stacks
x86/entry: Move SYSENTER_stack to the beginning of struct tss_struct x86/entry: Remap the TSS into the CPU entry area
x86/entry/64: Separate cpu_current_top_of_stack from TSS.sp0 x86/espfix/64: Stop assuming that pt_regs is on the entry stack x86/entry/64: Use a per-CPU trampoline stack for IDT entries x86/entry/64: Return to userspace from the trampoline stack x86/entry/64: Create a per-CPU SYSCALL entry trampoline
x86/entry/64: Move the IST stacks into 'struct cpu_entry_area' x86/entry/64: Remove the SYSENTER stack canary
x86/entry: Clean up the SYSENTER_stack code

Josh Poimboeuf (1):
x86/unwinder: Handle stack overflows more gracefully

 arch/x86/entry/entry_32.S          |   6 +-
 arch/x86/entry/entry_64.S          | 170 ++++++++++++++++++++++++++++++++-----
 arch/x86/entry/entry_64_compat.S   |   7 +-
 arch/x86/include/asm/desc.h        |  11 +--
 arch/x86/include/asm/fixmap.h      |  61 ++++++++++++-
 arch/x86/include/asm/kdebug.h      |   1 +
 arch/x86/include/asm/processor.h   |  54 +++++++-----
 arch/x86/include/asm/stacktrace.h  |   3 +
 arch/x86/include/asm/switch_to.h   |   3 +-
 arch/x86/include/asm/thread_info.h |   2 +-
 arch/x86/include/asm/traps.h       |   1 -
 arch/x86/include/asm/unwind.h      |   7 ++
 arch/x86/kernel/asm-offsets.c      |   7 ++
 arch/x86/kernel/asm-offsets_32.c   |   5 --
 arch/x86/kernel/asm-offsets_64.c   |   1 +
 arch/x86/kernel/cpu/common.c       | 136 +++++++++++++++++++++--------
 arch/x86/kernel/doublefault.c      |  36 ++++----
 arch/x86/kernel/dumpstack.c        |  74 ++++++++++++----
 arch/x86/kernel/dumpstack_32.c     |   6 ++
 arch/x86/kernel/dumpstack_64.c     |   6 ++
 arch/x86/kernel/irq.c              |  12 ---
 arch/x86/kernel/irq_64.c           |   4 +-
 arch/x86/kernel/process.c          |  13 ++-
 arch/x86/kernel/process_64.c       |  12 +--
 arch/x86/kernel/stacktrace.c       |   2 +-
 arch/x86/kernel/traps.c            |  57 ++++++++-----
 arch/x86/kernel/unwind_orc.c       |  88 ++++++++-----------
 arch/x86/kernel/vmlinux.lds.S      |   9 ++
 arch/x86/mm/kasan_init_64.c        |  18 +++-
 arch/x86/power/cpu.c               |  16 ++--
 arch/x86/xen/mmu_pv.c              |   2 +-
 31 files changed, 590 insertions(+), 240 deletions(-)
Signature · 1 line
2.14.1