# git rev-parse -q --verify 4da9f3302615f4191814f826054846bf843e24fa^{commit} 4da9f3302615f4191814f826054846bf843e24fa already have revision, skipping fetch # git checkout -q -f -B kisskb 4da9f3302615f4191814f826054846bf843e24fa # git clean -qxdf # < git log -1 # commit 4da9f3302615f4191814f826054846bf843e24fa # Merge: 125cfa0d4d14 d029bff60aa6 # Author: Linus Torvalds # Date: Tue Aug 4 21:16:22 2020 -0700 # # Merge tag 'x86-fsgsbase-2020-08-04' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip # # Pull x86 fsgsbase from Thomas Gleixner: # "Support for FSGSBASE. Almost 5 years after the first RFC to support # it, this has been brought into a shape which is maintainable and # actually works. # # This final version was done by Sasha Levin who took it up after Intel # dropped the ball. Sasha discovered that the SGX (sic!) offerings out # there ship rogue kernel modules enabling FSGSBASE behind the kernels # back which opens an instantanious unpriviledged root hole. # # The FSGSBASE instructions provide a considerable speedup of the # context switch path and enable user space to write GSBASE without # kernel interaction. This enablement requires careful handling of the # exception entries which go through the paranoid entry path as they # can no longer rely on the assumption that user GSBASE is positive (as # enforced via prctl() on non FSGSBASE enabled systemn). # # All other entries (syscalls, interrupts and exceptions) can still just # utilize SWAPGS unconditionally when the entry comes from user space. # Converting these entries to use FSGSBASE has no benefit as SWAPGS is # only marginally slower than WRGSBASE and locating and retrieving the # kernel GSBASE value is not a free operation either. The real benefit # of RD/WRGSBASE is the avoidance of the MSR reads and writes. # # The changes come with appropriate selftests and have held up in field # testing against the (sanitized) Graphene-SGX driver" # # * tag 'x86-fsgsbase-2020-08-04' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (21 commits) # x86/fsgsbase: Fix Xen PV support # x86/ptrace: Fix 32-bit PTRACE_SETREGS vs fsbase and gsbase # selftests/x86/fsgsbase: Add a missing memory constraint # selftests/x86/fsgsbase: Fix a comment in the ptrace_write_gsbase test # selftests/x86: Add a syscall_arg_fault_64 test for negative GSBASE # selftests/x86/fsgsbase: Test ptracer-induced GS base write with FSGSBASE # selftests/x86/fsgsbase: Test GS selector on ptracer-induced GS base write # Documentation/x86/64: Add documentation for GS/FS addressing mode # x86/elf: Enumerate kernel FSGSBASE capability in AT_HWCAP2 # x86/cpu: Enable FSGSBASE on 64bit by default and add a chicken bit # x86/entry/64: Handle FSGSBASE enabled paranoid entry/exit # x86/entry/64: Introduce the FIND_PERCPU_BASE macro # x86/entry/64: Switch CR3 before SWAPGS in paranoid entry # x86/speculation/swapgs: Check FSGSBASE in enabling SWAPGS mitigation # x86/process/64: Use FSGSBASE instructions on thread copy and ptrace # x86/process/64: Use FSBSBASE in switch_to() if available # x86/process/64: Make save_fsgs_for_kvm() ready for FSGSBASE # x86/fsgsbase/64: Enable FSGSBASE instructions in helper functions # x86/fsgsbase/64: Add intrinsics for FSGSBASE instructions # x86/cpu: Add 'unsafe_fsgsbase' to enable CR4.FSGSBASE # ... # < /opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux-ld --version # < git log --format=%s --max-count=1 4da9f3302615f4191814f826054846bf843e24fa # < make -s -j 8 ARCH=powerpc O=/kisskb/build/linus-rand_powerpc-randconfig_powerpc-gcc9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux- randconfig KCONFIG_SEED=0xC404ABFC WARNING: unmet direct dependencies detected for HOTPLUG_PCI_POWERNV Depends on [n]: PCI [=y] && HOTPLUG_PCI [=n] && PPC_POWERNV [=y] && EEH [=y] Selected by [y]: - OCXL [=y] && PPC_POWERNV [=y] && PCI [=y] && EEH [=y] # Added to kconfig CONFIG_STANDALONE=y # Added to kconfig CONFIG_BUILD_DOCSRC=n # Added to kconfig CONFIG_MODULE_SIG=n # Added to kconfig CONFIG_CPU_BIG_ENDIAN=y # Added to kconfig CONFIG_PPC64=y # Added to kconfig CONFIG_PPC_DISABLE_WERROR=y # Added to kconfig CONFIG_SECTION_MISMATCH_WARN_ONLY=y # Added to kconfig CONFIG_PREVENT_FIRMWARE_BUILD=y # Added to kconfig CONFIG_CC_STACKPROTECTOR_STRONG=n # Added to kconfig CONFIG_GCC_PLUGINS=n # Added to kconfig CONFIG_LD_HEAD_STUB_CATCH=y # Added to kconfig CONFIG_TRIM_UNUSED_KSYMS=n # Added to kconfig CONFIG_UBSAN=n # < make -s -j 8 ARCH=powerpc O=/kisskb/build/linus-rand_powerpc-randconfig_powerpc-gcc9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux- help # make -s -j 8 ARCH=powerpc O=/kisskb/build/linus-rand_powerpc-randconfig_powerpc-gcc9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux- olddefconfig .config:4965:warning: override: reassigning to symbol CPU_BIG_ENDIAN .config:4965:warning: override: CPU_BIG_ENDIAN changes choice state .config:4969:warning: override: reassigning to symbol PREVENT_FIRMWARE_BUILD .config:4974:warning: override: reassigning to symbol UBSAN WARNING: unmet direct dependencies detected for HOTPLUG_PCI_POWERNV Depends on [n]: PCI [=y] && HOTPLUG_PCI [=n] && PPC_POWERNV [=y] && EEH [=y] Selected by [y]: - OCXL [=y] && PPC_POWERNV [=y] && PCI [=y] && EEH [=y] # make -s -j 8 ARCH=powerpc O=/kisskb/build/linus-rand_powerpc-randconfig_powerpc-gcc9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-9.2.0-nolibc/powerpc64-linux/bin/powerpc64-linux- WARNING: unmet direct dependencies detected for HOTPLUG_PCI_POWERNV Depends on [n]: PCI [=y] && HOTPLUG_PCI [=n] && PPC_POWERNV [=y] && EEH [=y] Selected by [y]: - OCXL [=y] && PPC_POWERNV [=y] && PCI [=y] && EEH [=y] WARNING: unmet direct dependencies detected for HOTPLUG_PCI_POWERNV Depends on [n]: PCI [=y] && HOTPLUG_PCI [=n] && PPC_POWERNV [=y] && EEH [=y] Selected by [y]: - OCXL [=y] && PPC_POWERNV [=y] && PCI [=y] && EEH [=y] WARNING: unmet direct dependencies detected for HOTPLUG_PCI_POWERNV Depends on [n]: PCI [=y] && HOTPLUG_PCI [=n] && PPC_POWERNV [=y] && EEH [=y] Selected by [y]: - OCXL [=y] && PPC_POWERNV [=y] && PCI [=y] && EEH [=y] /kisskb/src/arch/powerpc/kernel/eeh.c:1707:12: warning: 'proc_eeh_show' defined but not used [-Wunused-function] 1707 | static int proc_eeh_show(struct seq_file *m, void *v) | ^~~~~~~~~~~~~ /kisskb/src/arch/powerpc/platforms/powernv/pci-ioda.c:1888:13: warning: 'pnv_ioda_setup_bus_dma' defined but not used [-Wunused-function] 1888 | static void pnv_ioda_setup_bus_dma(struct pnv_ioda_pe *pe, struct pci_bus *bus) | ^~~~~~~~~~~~~~~~~~~~~~ Completed OK # rm -rf /kisskb/build/linus-rand_powerpc-randconfig_powerpc-gcc9 # Build took: 0:10:11.151931