linux/arch/x86/include/asm
Joerg Roedel 61a6bd83ab Revert "x86/mm/legacy: Populate the user page-table with user pgd's"
This reverts commit 1f40a46cf4.

It turned out that this patch is not sufficient to enable PTI on 32 bit
systems with legacy 2-level page-tables. In this paging mode the huge-page
PTEs are in the top-level page-table directory, where also the mirroring to
the user-space page-table happens. So every huge PTE exits twice, in the
kernel and in the user page-table.

That means that accessed/dirty bits need to be fetched from two PTEs in
this mode to be safe, but this is not trivial to implement because it needs
changes to generic code just for the sake of enabling PTI with 32-bit
legacy paging. As all systems that need PTI should support PAE anyway,
remove support for PTI when 32-bit legacy paging is used.

Fixes: 7757d607c6 ('x86/pti: Allow CONFIG_PAGE_TABLE_ISOLATION for x86_32')
Reported-by: Meelis Roos <mroos@linux.ee>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: hpa@zytor.com
Cc: linux-mm@kvack.org
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Link: https://lkml.kernel.org/r/1536922754-31379-1-git-send-email-joro@8bytes.org
2018-09-14 17:08:45 +02:00
..
crypto
e820
fpu
numachip
trace Minor code cleanups for PPC. 2018-08-19 10:38:36 -07:00
uv
xen xen: remove unused hypercall functions 2018-08-20 14:46:18 -04:00
a.out-core.h
acenv.h
acpi.h
agp.h
alternative-asm.h
alternative.h
amd_nb.h
apb_timer.h
apic.h x86/irq: Let interrupt handlers set kvm_cpu_l1tf_flush_l1d 2018-08-05 09:53:13 +02:00
apic_flat_64.h
apicdef.h
apm.h x86/apm: Don't access __preempt_count with zeroed fs 2018-07-16 17:59:57 +02:00
arch_hweight.h
archrandom.h
asm-offsets.h
asm-prototypes.h
asm.h x86/asm: Add _ASM_ARG* constants for argument registers to <asm/asm.h> 2018-07-03 10:56:27 +02:00
atomic.h x86: Fix kernel-doc atomic.h warnings 2018-09-03 12:41:41 +02:00
atomic64_32.h x86: Fix kernel-doc atomic.h warnings 2018-09-03 12:41:41 +02:00
atomic64_64.h x86: Fix kernel-doc atomic.h warnings 2018-09-03 12:41:41 +02:00
barrier.h x86/spectre_v1: Disable compiler optimizations over array_index_mask_nospec() 2018-06-21 16:00:21 +02:00
bios_ebda.h
bitops.h
boot.h
bootparam_utils.h
bug.h
bugs.h
cache.h
cacheflush.h
cacheinfo.h
calgary.h
ce4100.h
checksum.h
checksum_32.h
checksum_64.h
clocksource.h
cmdline.h
cmpxchg.h locking/atomics: Instrument xchg() 2018-07-25 11:53:59 +02:00
cmpxchg_32.h
cmpxchg_64.h locking/atomics/x86: Reduce arch_cmpxchg64*() instrumentation 2018-07-25 11:53:58 +02:00
compat.h
cpu.h
cpu_device_id.h
cpu_entry_area.h
cpufeature.h
cpufeatures.h Merge branch 'l1tf-final' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-08-14 09:46:06 -07:00
cpumask.h
crash.h
current.h
debugreg.h
delay.h
desc.h
desc_defs.h
device.h
disabled-features.h
div64.h
dma-direct.h
dma-mapping.h x86/pci-dma: switch the VIA 32-bit DMA quirk to use the struct device flag 2018-05-28 12:48:25 +02:00
dma.h
dmi.h x86: Don't include linux/irq.h from asm/hardirq.h 2018-08-05 09:53:13 +02:00
dwarf2.h
edac.h
efi.h
elf.h
emergency-restart.h
entry_arch.h
error-injection.h
espfix.h
exec.h
extable.h
fb.h
fixmap.h
floppy.h
frame.h
ftrace.h
futex.h
gart.h
genapic.h
geode.h
hardirq.h x86: Don't include linux/irq.h from asm/hardirq.h 2018-08-05 09:53:13 +02:00
highmem.h
hpet.h
hugetlb.h
hw_breakpoint.h perf/hw_breakpoint: Remove default hw_breakpoint_arch_parse() 2018-06-26 09:07:58 +02:00
hw_irq.h
hyperv-tlfs.h Minor code cleanups for PPC. 2018-08-19 10:38:36 -07:00
hypervisor.h
i8259.h x86: i8259: Add missing include file 2018-08-15 13:44:10 -07:00
ia32.h
ia32_unistd.h
imr.h
inat.h
inat_types.h
init.h
insn-eval.h
insn.h
inst.h
intel-family.h x86/cpu: Introduce INTEL_CPU_FAM*() helper macros 2018-07-03 13:08:20 +02:00
intel-mid.h x86/platform/intel-mid: Remove per platform code 2018-07-03 13:08:21 +02:00
intel_ds.h perf/x86/intel/ds: Handle PEBS overflow for fixed counters 2018-07-25 11:50:50 +02:00
intel_mid_vrtc.h
intel_pconfig.h
intel_pmc_ipc.h
intel_pt.h
intel_punit_ipc.h
intel_rdt_sched.h
intel_scu_ipc.h
intel_telemetry.h
invpcid.h
io.h
io_apic.h
iomap.h
iommu.h
iommu_table.h
iosf_mbi.h
ipi.h
irq.h
irq_regs.h
irq_remapping.h x86: irq_remapping: Move irq remapping mode enum 2018-07-06 14:43:47 +02:00
irq_vectors.h
irq_work.h
irqdomain.h
irqflags.h x86/irqflags: Mark native_restore_fl extern inline 2018-08-30 11:37:09 +02:00
ist.h
jailhouse_para.h
jump_label.h
kasan.h
kaslr.h
kbdleds.h
Kbuild module: use relative references for __ksymtab entries 2018-08-22 10:52:47 -07:00
kdebug.h x86/process: Don't mix user/kernel regs in 64bit __show_regs() 2018-09-06 14:33:12 +02:00
kexec-bzimage64.h
kexec.h
kgdb.h
kmap_types.h
kprobes.h kprobes/x86: Don't call the ->break_handler() in x86 kprobes 2018-06-21 12:33:13 +02:00
kvm_emulate.h kvm: x86: use correct privilege level for sgdt/sidt/fxsave/fxrstor access 2018-06-12 15:06:34 +02:00
kvm_host.h KVM: LAPIC: Fix pv ipis out-of-bounds access 2018-09-07 18:38:43 +02:00
kvm_page_track.h
kvm_para.h x86/kvmclock: Decrapify kvm_register_clock() 2018-07-20 00:02:36 +02:00
kvmclock.h
linkage.h
livepatch.h
local.h
local64.h
mach_timer.h
mach_traps.h
math_emu.h
mc146818rtc.h
mce.h x86/mce: Add notifier_block forward declaration 2018-08-20 18:04:42 +02:00
mcsafe_test.h
mem_encrypt.h
microcode.h
microcode_amd.h
microcode_intel.h
misc.h
mmconfig.h
mmu.h
mmu_context.h x86/ldt: Enable LDT user-mapping for PAE 2018-07-20 01:11:48 +02:00
mmx.h
mmzone.h
mmzone_32.h
mmzone_64.h
module.h
mpspec.h
mpspec_def.h
mpx.h
mshyperv.h Minor code cleanups for PPC. 2018-08-19 10:38:36 -07:00
msi.h
msidef.h
msr-index.h x86/speculation: Use ARCH_CAPABILITIES to skip L1D flush on vmentry 2018-08-05 17:10:19 +02:00
msr-trace.h
msr.h
mtrr.h
mwait.h
nmi.h
nops.h
nospec-branch.h x86/speculation: Support Enhanced IBRS on future CPUs 2018-08-03 12:50:34 +02:00
numa.h
numa_32.h
olpc.h
olpc_ofw.h
orc_lookup.h
orc_types.h x86/unwind/orc: Detect the end of the stack 2018-06-21 16:34:56 +02:00
page.h
page_32.h
page_32_types.h x86/speculation/l1tf: Increase 32bit PAE __PHYSICAL_PAGE_SHIFT 2018-06-20 19:09:59 +02:00
page_64.h
page_64_types.h
page_types.h x86/mm: Decouple dynamic __PHYSICAL_MASK from AMD SME 2018-06-06 13:38:01 +02:00
paravirt.h x86/mm: Only use tlb_remove_table() for paravirt 2018-08-23 11:56:31 -07:00
paravirt_types.h x86/mm: Only use tlb_remove_table() for paravirt 2018-08-23 11:56:31 -07:00
parport.h
pat.h
pci-direct.h PCI: Make early dump functionality generic 2018-06-29 20:06:07 -05:00
pci-functions.h
pci.h
pci_64.h
pci_x86.h
percpu.h x86/asm: Use CC_SET/CC_OUT in percpu_cmpxchg8b_double() to micro-optimize code generation 2018-06-21 15:21:47 +02:00
perf_event.h
perf_event_p4.h
pgalloc.h x86/mm: Don't free P4D table when it is folded at runtime 2018-06-26 09:21:48 +02:00
pgtable-2level.h Revert "x86/mm/legacy: Populate the user page-table with user pgd's" 2018-09-14 17:08:45 +02:00
pgtable-2level_types.h x86/pgtable: Move two more functions from pgtable_64.h to pgtable.h 2018-07-20 01:11:42 +02:00
pgtable-3level.h x86/pae: use 64 bit atomic xchg function in native_ptep_get_and_clear 2018-08-27 14:20:49 -04:00
pgtable-3level_types.h x86/pgtable: Move two more functions from pgtable_64.h to pgtable.h 2018-07-20 01:11:42 +02:00
pgtable-invert.h x86/speculation/l1tf: Exempt zeroed PTEs from inversion 2018-08-17 10:27:36 -07:00
pgtable.h x86/mm: Use WRITE_ONCE() when setting PTEs 2018-09-08 12:30:36 +02:00
pgtable_32.h x86/pgtable: Move two more functions from pgtable_64.h to pgtable.h 2018-07-20 01:11:42 +02:00
pgtable_32_types.h x86/ldt: Define LDT_END_ADDR 2018-07-20 01:11:47 +02:00
pgtable_64.h x86/mm: Use WRITE_ONCE() when setting PTEs 2018-09-08 12:30:36 +02:00
pgtable_64_types.h x86/ldt: Define LDT_END_ADDR 2018-07-20 01:11:47 +02:00
pgtable_types.h x86/mm/pae: Populate valid user PGD entries 2018-07-20 01:11:42 +02:00
pkeys.h powerpc updates for 4.18 2018-06-07 10:23:33 -07:00
platform_sst_audio.h
pm-trace.h
posix_types.h
preempt.h
probe_roms.h
processor-cyrix.h
processor-flags.h x86/mm/pti: Define X86_CR3_PTI_PCID_USER_BIT on x86_32 2018-07-20 01:11:44 +02:00
processor.h x86/speculation/l1tf: Increase l1tf memory limit for Nehalem+ 2018-08-27 10:29:14 +02:00
prom.h
proto.h
pti.h x86/mm/pti: Introduce pti_finalize() 2018-07-20 01:11:45 +02:00
ptrace.h
purgatory.h
pvclock-abi.h
pvclock.h
qrwlock.h
qspinlock.h
qspinlock_paravirt.h locking/pvqspinlock/x86: Use LOCK_PREFIX in __pv_queued_spin_unlock() assembly code 2018-07-25 11:22:20 +02:00
realmode.h
reboot.h
reboot_fixups.h
refcount.h locking/refcounts: Include fewer headers in <linux/refcount.h> 2018-06-21 18:22:02 +02:00
required-features.h
rio.h
rmwcc.h
rwsem.h
seccomp.h
sections.h x86/mm/pti: Make pti_clone_kernel_text() compile on 32 bit 2018-07-20 01:11:44 +02:00
segment.h Kbuild: rename CC_STACKPROTECTOR[_STRONG] config variables 2018-06-14 12:21:18 +09:00
serial.h
set_memory.h libnvdimm-for-4.19_dax-memory-failure 2018-08-25 18:43:59 -07:00
setup.h
setup_arch.h
shmparam.h
sigcontext.h
sigframe.h
sighandling.h
signal.h x86/asm: Use CC_SET()/CC_OUT() in __gen_sigismember() 2018-08-30 13:02:31 +02:00
simd.h
smap.h
smp.h
sparsemem.h
spec-ctrl.h
special_insns.h
spinlock.h
spinlock_types.h
sta2x11.h
stackprotector.h Kbuild: rename CC_STACKPROTECTOR[_STRONG] config variables 2018-06-14 12:21:18 +09:00
stacktrace.h x86/dumpstack: Don't dump kernel memory based on usermode RIP 2018-08-31 17:08:22 +02:00
string.h
string_32.h
string_64.h
suspend.h
suspend_32.h
suspend_64.h
svm.h
swiotlb.h
switch_to.h x86/entry: Rename update_sp0 to update_task_stack 2018-07-20 01:11:40 +02:00
sync_bitops.h
sync_core.h
syscall.h
syscall_wrapper.h
syscalls.h
sysfb.h
tce.h
text-patching.h x86/alternatives, jumplabel: Use text_poke_early() before mm_init() 2018-07-20 00:02:38 +02:00
thread_info.h
time.h
timer.h
timex.h
tlb.h
tlbbatch.h
tlbflush.h x86/nmi: Fix NMI uaccess race against CR3 switching 2018-08-31 17:08:22 +02:00
topology.h x86/topology: Provide topology_smt_supported() 2018-06-21 14:20:57 +02:00
trace_clock.h
traps.h
tsc.h x86/tsc: Make use of tsc_calibrate_cpu_early() 2018-07-20 00:02:44 +02:00
uaccess.h
uaccess_32.h
uaccess_64.h x86/asm/memcpy_mcsafe: Fix copy_to_user_mcsafe() exception handling 2018-07-16 00:05:05 +02:00
umip.h
unaligned.h
unistd.h
unwind.h
unwind_hints.h x86/unwind/orc: Detect the end of the stack 2018-06-21 16:34:56 +02:00
uprobes.h
user.h
user32.h
user_32.h
user_64.h
vdso.h
vga.h
vgtod.h x86/vdso: Fix lsl operand order 2018-09-01 23:01:56 +02:00
virtext.h
vm86.h
vmx.h KVM: vmx: Add defines for SGX ENCLS exiting 2018-08-22 16:48:35 +02:00
vsyscall.h
vvar.h
word-at-a-time.h
x86_init.h Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-06-10 09:44:53 -07:00
xor.h
xor_32.h
xor_64.h
xor_avx.h