Skip to content
  1. Jul 06, 2018
    • K. Y. Srinivasan's avatar
      x86/hyper-v: Fix the circular dependency in IPI enlightenment · 1268ed0c
      K. Y. Srinivasan authored
      The IPI hypercalls depend on being able to map the Linux notion of CPU ID
      to the hypervisor's notion of the CPU ID. The array hv_vp_index[] provides
      this mapping. Code for populating this array depends on the IPI functionality.
      Break this circular dependency.
      
      [ tglx: Use a proper define instead of '-1' with a u32 variable as pointed
        	out by Vitaly ]
      
      Fixes: 68bb7bfb
      
       ("X86/Hyper-V: Enable IPI enlightenments")
      Signed-off-by: default avatarK. Y. Srinivasan <kys@microsoft.com>
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      Tested-by: default avatarMichael Kelley <mikelley@microsoft.com>
      Cc: gregkh@linuxfoundation.org
      Cc: devel@linuxdriverproject.org
      Cc: olaf@aepfle.de
      Cc: apw@canonical.com
      Cc: jasowang@redhat.com
      Cc: hpa@zytor.com
      Cc: sthemmin@microsoft.com
      Cc: Michael.H.Kelley@microsoft.com
      Cc: vkuznets@redhat.com
      Link: https://lkml.kernel.org/r/20180703230155.15160-1-kys@linuxonhyperv.com
      
      1268ed0c
  2. Jul 03, 2018
    • Nick Desaulniers's avatar
      x86/paravirt: Make native_save_fl() extern inline · d0a8d937
      Nick Desaulniers authored
      
      
      native_save_fl() is marked static inline, but by using it as
      a function pointer in arch/x86/kernel/paravirt.c, it MUST be outlined.
      
      paravirt's use of native_save_fl() also requires that no GPRs other than
      %rax are clobbered.
      
      Compilers have different heuristics which they use to emit stack guard
      code, the emittance of which can break paravirt's callee saved assumption
      by clobbering %rcx.
      
      Marking a function definition extern inline means that if this version
      cannot be inlined, then the out-of-line version will be preferred. By
      having the out-of-line version be implemented in assembly, it cannot be
      instrumented with a stack protector, which might violate custom calling
      conventions that code like paravirt rely on.
      
      The semantics of extern inline has changed since gnu89. This means that
      folks using GCC versions >= 5.1 may see symbol redefinition errors at
      link time for subdirs that override KBUILD_CFLAGS (making the C standard
      used implicit) regardless of this patch. This has been cleaned up
      earlier in the patch set, but is left as a note in the commit message
      for future travelers.
      
      Reports:
       https://lkml.org/lkml/2018/5/7/534
       https://github.com/ClangBuiltLinux/linux/issues/16
      
      Discussion:
       https://bugs.llvm.org/show_bug.cgi?id=37512
       https://lkml.org/lkml/2018/5/24/1371
      
      Thanks to the many folks that participated in the discussion.
      
      Debugged-by: default avatarAlistair Strachan <astrachan@google.com>
      Debugged-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Suggested-by: default avatarArnd Bergmann <arnd@arndb.de>
      Suggested-by: default avatarH. Peter Anvin <hpa@zytor.com>
      Suggested-by: default avatarTom Stellar <tstellar@redhat.com>
      Reported-by: default avatarSedat Dilek <sedat.dilek@gmail.com>
      Tested-by: default avatarSedat Dilek <sedat.dilek@gmail.com>
      Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Acked-by: default avatarJuergen Gross <jgross@suse.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: acme@redhat.com
      Cc: akataria@vmware.com
      Cc: akpm@linux-foundation.org
      Cc: andrea.parri@amarulasolutions.com
      Cc: ard.biesheuvel@linaro.org
      Cc: aryabinin@virtuozzo.com
      Cc: astrachan@google.com
      Cc: boris.ostrovsky@oracle.com
      Cc: brijesh.singh@amd.com
      Cc: caoj.fnst@cn.fujitsu.com
      Cc: geert@linux-m68k.org
      Cc: ghackmann@google.com
      Cc: gregkh@linuxfoundation.org
      Cc: jan.kiszka@siemens.com
      Cc: jarkko.sakkinen@linux.intel.com
      Cc: joe@perches.com
      Cc: jpoimboe@redhat.com
      Cc: keescook@google.com
      Cc: kirill.shutemov@linux.intel.com
      Cc: kstewart@linuxfoundation.org
      Cc: linux-efi@vger.kernel.org
      Cc: linux-kbuild@vger.kernel.org
      Cc: manojgupta@google.com
      Cc: mawilcox@microsoft.com
      Cc: michal.lkml@markovi.net
      Cc: mjg59@google.com
      Cc: mka@chromium.org
      Cc: pombredanne@nexb.com
      Cc: rientjes@google.com
      Cc: rostedt@goodmis.org
      Cc: thomas.lendacky@amd.com
      Cc: tweek@google.com
      Cc: virtualization@lists.linux-foundation.org
      Cc: will.deacon@arm.com
      Cc: yamada.masahiro@socionext.com
      Link: http://lkml.kernel.org/r/20180621162324.36656-4-ndesaulniers@google.com
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      d0a8d937
    • H. Peter Anvin's avatar
      x86/asm: Add _ASM_ARG* constants for argument registers to <asm/asm.h> · 0e2e1600
      H. Peter Anvin authored
      
      
      i386 and x86-64 uses different registers for arguments; make them
      available so we don't have to #ifdef in the actual code.
      
      Native size and specified size (q, l, w, b) versions are provided.
      
      Signed-off-by: default avatarH. Peter Anvin <hpa@linux.intel.com>
      Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Reviewed-by: default avatarSedat Dilek <sedat.dilek@gmail.com>
      Acked-by: default avatarJuergen Gross <jgross@suse.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: acme@redhat.com
      Cc: akataria@vmware.com
      Cc: akpm@linux-foundation.org
      Cc: andrea.parri@amarulasolutions.com
      Cc: ard.biesheuvel@linaro.org
      Cc: arnd@arndb.de
      Cc: aryabinin@virtuozzo.com
      Cc: astrachan@google.com
      Cc: boris.ostrovsky@oracle.com
      Cc: brijesh.singh@amd.com
      Cc: caoj.fnst@cn.fujitsu.com
      Cc: geert@linux-m68k.org
      Cc: ghackmann@google.com
      Cc: gregkh@linuxfoundation.org
      Cc: jan.kiszka@siemens.com
      Cc: jarkko.sakkinen@linux.intel.com
      Cc: joe@perches.com
      Cc: jpoimboe@redhat.com
      Cc: keescook@google.com
      Cc: kirill.shutemov@linux.intel.com
      Cc: kstewart@linuxfoundation.org
      Cc: linux-efi@vger.kernel.org
      Cc: linux-kbuild@vger.kernel.org
      Cc: manojgupta@google.com
      Cc: mawilcox@microsoft.com
      Cc: michal.lkml@markovi.net
      Cc: mjg59@google.com
      Cc: mka@chromium.org
      Cc: pombredanne@nexb.com
      Cc: rientjes@google.com
      Cc: rostedt@goodmis.org
      Cc: thomas.lendacky@amd.com
      Cc: tstellar@redhat.com
      Cc: tweek@google.com
      Cc: virtualization@lists.linux-foundation.org
      Cc: will.deacon@arm.com
      Cc: yamada.masahiro@socionext.com
      Link: http://lkml.kernel.org/r/20180621162324.36656-3-ndesaulniers@google.com
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      0e2e1600
    • Nick Desaulniers's avatar
      compiler-gcc.h: Add __attribute__((gnu_inline)) to all inline declarations · d03db2bc
      Nick Desaulniers authored
      
      
      Functions marked extern inline do not emit an externally visible
      function when the gnu89 C standard is used. Some KBUILD Makefiles
      overwrite KBUILD_CFLAGS. This is an issue for GCC 5.1+ users as without
      an explicit C standard specified, the default is gnu11. Since c99, the
      semantics of extern inline have changed such that an externally visible
      function is always emitted. This can lead to multiple definition errors
      of extern inline functions at link time of compilation units whose build
      files have removed an explicit C standard compiler flag for users of GCC
      5.1+ or Clang.
      
      Suggested-by: default avatarArnd Bergmann <arnd@arndb.de>
      Suggested-by: default avatarH. Peter Anvin <hpa@zytor.com>
      Suggested-by: default avatarJoe Perches <joe@perches.com>
      Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Acked-by: default avatarJuergen Gross <jgross@suse.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: acme@redhat.com
      Cc: akataria@vmware.com
      Cc: akpm@linux-foundation.org
      Cc: andrea.parri@amarulasolutions.com
      Cc: ard.biesheuvel@linaro.org
      Cc: aryabinin@virtuozzo.com
      Cc: astrachan@google.com
      Cc: boris.ostrovsky@oracle.com
      Cc: brijesh.singh@amd.com
      Cc: caoj.fnst@cn.fujitsu.com
      Cc: geert@linux-m68k.org
      Cc: ghackmann@google.com
      Cc: gregkh@linuxfoundation.org
      Cc: jan.kiszka@siemens.com
      Cc: jarkko.sakkinen@linux.intel.com
      Cc: jpoimboe@redhat.com
      Cc: keescook@google.com
      Cc: kirill.shutemov@linux.intel.com
      Cc: kstewart@linuxfoundation.org
      Cc: linux-efi@vger.kernel.org
      Cc: linux-kbuild@vger.kernel.org
      Cc: manojgupta@google.com
      Cc: mawilcox@microsoft.com
      Cc: michal.lkml@markovi.net
      Cc: mjg59@google.com
      Cc: mka@chromium.org
      Cc: pombredanne@nexb.com
      Cc: rientjes@google.com
      Cc: rostedt@goodmis.org
      Cc: sedat.dilek@gmail.com
      Cc: thomas.lendacky@amd.com
      Cc: tstellar@redhat.com
      Cc: tweek@google.com
      Cc: virtualization@lists.linux-foundation.org
      Cc: will.deacon@arm.com
      Cc: yamada.masahiro@socionext.com
      Link: http://lkml.kernel.org/r/20180621162324.36656-2-ndesaulniers@google.com
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      d03db2bc
    • Zhenzhong Duan's avatar
      x86/mm/32: Initialize the CR4 shadow before __flush_tlb_all() · 4fb5f58e
      Zhenzhong Duan authored
      
      
      On 32-bit kernels, __flush_tlb_all() may have read the CR4 shadow before the
      initialization of CR4 shadow in cpu_init().
      
      Fix it by adding an explicit cr4_init_shadow() call into start_secondary()
      which is the first function called on non-boot SMP CPUs - ahead of the
      __flush_tlb_all() call.
      
      ( This is somewhat of a layering violation, but start_secondary() does
        CR4 bootstrap in the PCID case anyway. )
      
      Signed-off-by: default avatarZhenzhong Duan <zhenzhong.duan@oracle.com>
      Cc: Andy Lutomirski <luto@kernel.org>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Link: http://lkml.kernel.org/r/b07b6ae9-4b57-4b40-b9bc-50c2c67f1d91@default
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      4fb5f58e
  3. Jul 02, 2018
    • Linus Torvalds's avatar
      Linux 4.18-rc3 · 021c9179
      Linus Torvalds authored
      021c9179
    • Linus Torvalds's avatar
      Merge tag 'for-4.18-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · d3bc0e67
      Linus Torvalds authored
      Pull btrfs fixes from David Sterba:
       "We have a few regression fixes for qgroup rescan status tracking and
        the vm_fault_t conversion that mixed up the error values"
      
      * tag 'for-4.18-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        Btrfs: fix mount failure when qgroup rescan is in progress
        Btrfs: fix regression in btrfs_page_mkwrite() from vm_fault_t conversion
        btrfs: quota: Set rescan progress to (u64)-1 if we hit last leaf
      d3bc0e67
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 4a770e63
      Linus Torvalds authored
      Pull vfs fix from Al Viro:
       "Followup to procfs-seq_file series this window"
      
      This fixes a memory leak by making sure that proc seq files release any
      private data on close.  The 'proc_seq_open' has to be properly paired
      with 'proc_seq_release' that releases the extra private data.
      
      * 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        proc: add proc_seq_release
      4a770e63
    • Linus Torvalds's avatar
      Merge tag 'staging-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · d7563ca5
      Linus Torvalds authored
      Pull staging/IIO fixes from Greg KH:
       "Here are a few small staging and IIO driver fixes for 4.18-rc3.
      
        Nothing major or big, all just fixes for reported problems since
        4.18-rc1. All of these have been in linux-next this week with no
        reported problems"
      
      * tag 'staging-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        staging: android: ion: Return an ERR_PTR in ion_map_kernel
        staging: comedi: quatech_daqp_cs: fix no-op loop daqp_ao_insn_write()
        iio: imu: inv_mpu6050: Fix probe() failure on older ACPI based machines
        iio: buffer: fix the function signature to match implementation
        iio: mma8452: Fix ignoring MMA8452_INT_DRDY
        iio: tsl2x7x/tsl2772: avoid potential division by zero
        iio: pressure: bmp280: fix relative humidity unit
      d7563ca5
    • Linus Torvalds's avatar
      Merge tag 'tty-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty · 652788a9
      Linus Torvalds authored
      Pull tty/serial fixes from Greg KH:
       "Here are five fixes for the tty core and some serial drivers.
      
        The tty core ones fix some security and other issues reported by the
        syzbot that I have taken too long in responding to (sorry Tetsuo!).
      
        The 8350 serial driver fix resolves an issue of devices that used to
        work properly stopping working as they shouldn't have been added to a
        blacklist.
      
        All of these have been in linux-next for a few days with no reported
        issues"
      
      * tag 'tty-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
        vt: prevent leaking uninitialized data to userspace via /dev/vcs*
        serdev: fix memleak on module unload
        serial: 8250_pci: Remove stalled entries in blacklist
        n_tty: Access echo_* variables carefully.
        n_tty: Fix stall at n_tty_receive_char_special().
      652788a9
    • Linus Torvalds's avatar
      Merge tag 'usb-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · c2aee376
      Linus Torvalds authored
      Pull USB fixes from Greg KH:
       "Here is a number of USB gadget and other driver fixes for 4.18-rc3.
      
        There's a bunch of them here, most of them being gadget driver and
        xhci host controller fixes for reported issues (as normal), but there
        are also some new device ids, and some fixes for the typec code.
      
        There is an acpi core patch in here that was acked by the acpi
        maintainer as it is needed for the typec fixes in order to properly
        solve a problem in that driver.
      
        All of these have been in linux-next this week with no reported
        issues"
      
      * tag 'usb-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (33 commits)
        usb: chipidea: host: fix disconnection detect issue
        usb: typec: tcpm: fix logbuffer index is wrong if _tcpm_log is re-entered
        typec: tcpm: Fix a msecs vs jiffies bug
        NFC: pn533: Fix wrong GFP flag usage
        usb: cdc_acm: Add quirk for Uniden UBC125 scanner
        staging/typec: fix tcpci_rt1711h build errors
        usb: typec: ucsi: Fix for incorrect status data issue
        usb: typec: ucsi: acpi: Workaround for cache mode issue
        acpi: Add helper for deactivating memory region
        usb: xhci: increase CRS timeout value
        usb: xhci: tegra: fix runtime PM error handling
        usb: xhci: remove the code build warning
        xhci: Fix kernel oops in trace_xhci_free_virt_device
        xhci: Fix perceived dead host due to runtime suspend race with event handler
        dwc2: gadget: Fix ISOC IN DDMA PID bitfield value calculation
        usb: gadget: dwc2: fix memory leak in gadget_init()
        usb: gadget: composite: fix delayed_status race condition when set_interface
        usb: dwc2: fix isoc split in transfer with no data
        usb: dwc2: alloc dma aligned buffer for isoc split in
        usb: dwc2: fix the incorrect bitmaps for the ports of multi_tt hub
        ...
      c2aee376
    • Linus Torvalds's avatar
      Merge tag 'dma-mapping-4.18-2' of git://git.infradead.org/users/hch/dma-mapping · c350d6d1
      Linus Torvalds authored
      Pull dma mapping fixlet from Christoph Hellwig:
       "Add a missing export required by riscv and unicore"
      
      * tag 'dma-mapping-4.18-2' of git://git.infradead.org/users/hch/dma-mapping:
        swiotlb: export swiotlb_dma_ops
      c350d6d1
  4. Jul 01, 2018
    • Linus Torvalds's avatar
      Merge branch 'parisc-4.18-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux · 883c9ab9
      Linus Torvalds authored
      Pull parisc fixes and cleanups from Helge Deller:
       "Nothing exiting in this patchset, just
      
         - small cleanups of header files
      
         - default to 4 CPUs when building a SMP kernel
      
         - mark 16kB and 64kB page sizes broken
      
         - addition of the new io_pgetevents syscall"
      
      * 'parisc-4.18-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
        parisc: Build kernel without -ffunction-sections
        parisc: Reduce debug output in unwind code
        parisc: Wire up io_pgetevents syscall
        parisc: Default to 4 SMP CPUs
        parisc: Convert printk(KERN_LEVEL) to pr_lvl()
        parisc: Mark 16kB and 64kB page sizes BROKEN
        parisc: Drop struct sigaction from not exported header file
      883c9ab9
    • Linus Torvalds's avatar
      Merge tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · 08af78d7
      Linus Torvalds authored
      Pull ARM SoC fixes from Olof Johansson:
       "A smaller batch for the end of the week (let's see if I can keep the
        weekly cadence going for once).
      
        All medium-grade fixes here, nothing worrisome:
      
         - Fixes for some fairly old bugs around SD card write-protect
           detection and GPIO interrupt assignments on Davinci.
      
         - Wifi module suspend fix for Hikey.
      
         - Minor DT tweaks to fix inaccuracies for Amlogic platforms, one
           of which solves booting with third-party u-boot"
      
      * tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
        arm64: dts: hikey960: Define wl1837 power capabilities
        arm64: dts: hikey: Define wl1835 power capabilities
        ARM64: dts: meson-gxl: fix Mali GPU compatible string
        ARM64: dts: meson-axg: fix ethernet stability issue
        ARM64: dts: meson-gx: fix ATF reserved memory region
        ARM64: dts: meson-gxl-s905x-p212: Add phy-supply for usb0
        ARM64: dts: meson: fix register ranges for SD/eMMC
        ARM64: dts: meson: disable sd-uhs modes on the libretech-cc
        ARM: dts: da850: Fix interrups property for gpio
        ARM: davinci: board-da850-evm: fix WP pin polarity for MMC/SD
      08af78d7
    • Linus Torvalds's avatar
      Merge tag 'kbuild-fixes-v4.18' of... · 22d3e0c3
      Linus Torvalds authored
      Merge tag 'kbuild-fixes-v4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
      
      Pull Kbuild fixes from Masahiro Yamada:
      
       - introduce __diag_* macros and suppress -Wattribute-alias warnings
         from GCC 8
      
       - fix stack protector test script for x86_64
      
       - fix line number handling in Kconfig
      
       - document that '#' starts a comment in Kconfig
      
       - handle P_SYMBOL property in dump debugging of Kconfig
      
       - correct help message of LD_DEAD_CODE_DATA_ELIMINATION
      
       - fix occasional segmentation faults in Kconfig
      
      * tag 'kbuild-fixes-v4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        kconfig: loop boundary condition fix
        kbuild: reword help of LD_DEAD_CODE_DATA_ELIMINATION
        kconfig: handle P_SYMBOL in print_symbol()
        kconfig: document Kconfig source file comments
        kconfig: fix line numbers for if-entries in menu tree
        stack-protector: Fix test with 32-bit userland and CONFIG_64BIT=y
        powerpc: Remove -Wattribute-alias pragmas
        disable -Wattribute-alias warning for SYSCALL_DEFINEx()
        kbuild: add macro for controlling warnings to linux/compiler.h
      22d3e0c3
    • Linus Torvalds's avatar
      Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 0fbc4aea
      Linus Torvalds authored
      Pull x86 fixes from Ingo Molnar:
       "The biggest diffstat comes from self-test updates, plus there's entry
        code fixes, 5-level paging related fixes, console debug output fixes,
        and misc fixes"
      
      * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/mm: Clean up the printk()s in show_fault_oops()
        x86/mm: Drop unneeded __always_inline for p4d page table helpers
        x86/efi: Fix efi_call_phys_epilog() with CONFIG_X86_5LEVEL=y
        selftests/x86/sigreturn: Do minor cleanups
        selftests/x86/sigreturn/64: Fix spurious failures on AMD CPUs
        x86/entry/64/compat: Fix "x86/entry/64/compat: Preserve r8-r11 in int $0x80"
        x86/mm: Don't free P4D table when it is folded at runtime
        x86/entry/32: Add explicit 'l' instruction suffix
        x86/mm: Get rid of KERN_CONT in show_fault_oops()
      0fbc4aea
    • Linus Torvalds's avatar
      Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · d7d53886
      Linus Torvalds authored
      Pull perf fixes from Ingo Molnar:
       "Tooling fixes mostly, plus a build warning fix"
      
      * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (21 commits)
        perf/core: Move inline keyword at the beginning of declaration
        tools/headers: Pick up latest kernel ABIs
        perf tools: Fix crash caused by accessing feat_ops[HEADER_LAST_FEATURE]
        perf script: Fix crash because of missing evsel->priv
        perf script: Add missing output fields in a hint
        perf bench: Fix numa report output code
        perf stat: Remove duplicate event counting
        perf alias: Rebuild alias expression string to make it comparable
        perf alias: Remove trailing newline when reading sysfs files
        perf tools: Fix a clang 7.0 compilation error
        tools include uapi: Synchronize bpf.h with the kernel
        tools include uapi: Update if_link.h to pick IFLA_{BRPORT_ISOLATED,VXLAN_TTL_INHERIT}
        tools include powerpc: Update arch/powerpc/include/uapi/asm/unistd.h copy to get 'rseq' syscall
        perf tools: Update x86's syscall_64.tbl, adding 'io_pgetevents' and 'rseq'
        tools headers uapi: Synchronize drm/drm.h
        perf intel-pt: Fix packet decoding of CYC packets
        perf tests: Add valid callback for parse-events test
        perf tests: Add event parsing error handling to parse events test
        perf report powerpc: Fix crash if callchain is empty
        perf test session topology: Fix test on s390
        ...
      d7d53886
    • Linus Torvalds's avatar
      Merge tag 'selinux-pr-20180629' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux · 34a484d5
      Linus Torvalds authored
      Pull selinux fix from Paul Moore:
       "One fairly straightforward patch to fix a longstanding issue where a
        process could stall while accessing files in selinuxfs and block
        everyone else due to a held mutex.
      
        The patch passes all our tests and looks to apply cleanly to your
        current tree"
      
      * tag 'selinux-pr-20180629' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux:
        selinux: move user accesses in selinuxfs out of locked regions
      34a484d5
    • Linus Torvalds's avatar
      Merge tag 'for-linus-20180629' of git://git.kernel.dk/linux-block · e6e5bec4
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "Small set of fixes for this series. Mostly just minor fixes, the only
        oddball in here is the sg change.
      
        The sg change came out of the stall fix for NVMe, where we added a
        mempool and limited us to a single page allocation. CONFIG_SG_DEBUG
        sort-of ruins that, since we'd need to account for that. That's
        actually a generic problem, since lots of drivers need to allocate SG
        lists. So this just removes support for CONFIG_SG_DEBUG, which I added
        back in 2007 and to my knowledge it was never useful.
      
        Anyway, outside of that, this pull contains:
      
         - clone of request with special payload fix (Bart)
      
         - drbd discard handling fix (Bart)
      
         - SATA blk-mq stall fix (me)
      
         - chunk size fix (Keith)
      
         - double free nvme rdma fix (Sagi)"
      
      * tag 'for-linus-20180629' of git://git.kernel.dk/linux-block:
        sg: remove ->sg_magic member
        drbd: Fix drbd_request_prepare() discard handling
        blk-mq: don't queue more if we get a busy return
        block: Fix cloning of requests with a special payload
        nvme-rdma: fix possible double free of controller async event buffer
        block: Fix transfer when chunk sectors exceeds max
      e6e5bec4
  5. Jun 30, 2018
    • Linus Torvalds's avatar
      Merge tag 'powerpc-4.18-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · 1904148a
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
       "Two regression fixes, and a new syscall wire-up:
      
         - A fix for the recent conversion to time64_t in the powermac RTC
           routines, which caused time to go backward.
      
         - Another fix for fallout from the split PMD PTL conversion.
      
         - Wire up the new io_pgetevents() syscall.
      
        Thanks to: Aneesh Kumar K.V, Arnd Bergmann, Breno Leitao, Mathieu
        Malaterre"
      
      * tag 'powerpc-4.18-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc/powermac: Fix rtc read/write functions
        powerpc/mm/32: Fix pgtable_page_dtor call
        powerpc: Wire up io_pgetevents
      1904148a
    • Olof Johansson's avatar
      Merge tag 'davinci-fixes-for-v4.18' of... · 4ca2f0b9
      Olof Johansson authored
      
      Merge tag 'davinci-fixes-for-v4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci into fixes
      
      This fixes polarity of SD card write-protect pin on DA850 EVM
      and fixes interrupt property for DA850 SoC GPIO as defined in
      device-tree.
      
      Both of these are not introduced with v4.18 merge but have
      existed prior.
      
      * tag 'davinci-fixes-for-v4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/nsekhar/linux-davinci:
        ARM: dts: da850: Fix interrups property for gpio
        ARM: davinci: board-da850-evm: fix WP pin polarity for MMC/SD
      
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      4ca2f0b9
    • Olof Johansson's avatar
      Merge tag 'hisi-fixes-for-4.18' of git://github.com/hisilicon/linux-hisi into fixes · 35911e01
      Olof Johansson authored
      
      
      ARM64: hisi fixes for 4.18
      
      - Added power capabilities for the mmc host controller on the
        hikey and hikey960 boards to avoid broken wifi.
      
      * tag 'hisi-fixes-for-4.18' of git://github.com/hisilicon/linux-hisi:
        arm64: dts: hikey960: Define wl1837 power capabilities
        arm64: dts: hikey: Define wl1835 power capabilities
      
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      35911e01
    • Olof Johansson's avatar
      Merge tag 'amlogic-fixes' of... · d2d369a9
      Olof Johansson authored
      
      Merge tag 'amlogic-fixes' of https://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic into fixes
      
      Amlogic fixes for v4.18-rc
      - minor 64-bit DT fixes
      
      * tag 'amlogic-fixes' of https://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic:
        ARM64: dts: meson-gxl: fix Mali GPU compatible string
        ARM64: dts: meson-axg: fix ethernet stability issue
        ARM64: dts: meson-gx: fix ATF reserved memory region
        ARM64: dts: meson-gxl-s905x-p212: Add phy-supply for usb0
        ARM64: dts: meson: fix register ranges for SD/eMMC
        ARM64: dts: meson: disable sd-uhs modes on the libretech-cc
      
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      d2d369a9
    • Linus Torvalds's avatar
      Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux · 0d55ec6f
      Linus Torvalds authored
      Pull arm64 fixes from Catalin Marinas:
      
       - The alternatives patching code uses flush_icache_range() which itself
         uses alternatives. Change the code to use an unpatched variant of
         cache maintenance
      
       - Remove unnecessary ISBs from set_{pte,pmd,pud}
      
       - perf: xgene_pmu: Fix IOB SLOW PMU parser error
      
      * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
        arm64: Remove unnecessary ISBs from set_{pte,pmd,pud}
        arm64: Avoid flush_icache_range() in alternatives patching code
        drivers/perf: xgene_pmu: Fix IOB SLOW PMU parser error
      0d55ec6f
    • Linus Torvalds's avatar
      Merge branch 'i2c/for-current-fixed' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux · 44813aa6
      Linus Torvalds authored
      Pull i2c fixes from Wolfram Sang:
      
       - a revert because of bugzilla #200045 (and some documentation about
         it)
      
       - another regression fix in the i2c-gpio driver
      
       - a leak fix for the i2c core
      
      * 'i2c/for-current-fixed' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
        i2c: gpio: initialize SCL to HIGH again
        i2c: smbus: kill memory leak on emulated and failed DMA SMBus xfers
        i2c: algos: bit: mention our experience about initial states
        Revert "i2c: algo-bit: init the bus to a known state"
      44813aa6
    • Linus Torvalds's avatar
      Merge tag 'ceph-for-4.18-rc3' of git://github.com/ceph/ceph-client · 78869538
      Linus Torvalds authored
      Pull ceph fix from Ilya Dryomov:
       "A trivial dentry leak fix from Zheng"
      
      * tag 'ceph-for-4.18-rc3' of git://github.com/ceph/ceph-client:
        ceph: fix dentry leak in splice_dentry()
      78869538
  6. Jun 29, 2018
    • Helge Deller's avatar
      parisc: Build kernel without -ffunction-sections · 24b6c225
      Helge Deller authored
      
      
      As suggested by Nick Piggin it seems we can drop the -ffunction-sections
      compile flag, now that the kernel uses thin archives. Testing with 32-
      and 64-bit kernel showed no difference in kernel size.
      
      Suggested-by: default avatarNicholas Piggin <npiggin@gmail.com>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      24b6c225
    • Jens Axboe's avatar
      sg: remove ->sg_magic member · 9544bc53
      Jens Axboe authored
      
      
      This was introduced more than a decade ago when sg chaining was
      added, but we never really caught anything with it. The scatterlist
      entry size can be critical, since drivers allocate it, so remove
      the magic member. Recently it's been triggering allocation stalls
      and failures in NVMe.
      
      Tested-by: default avatarJordan Glover <Golden_Miller83@protonmail.ch>
      Acked-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      9544bc53
    • Linus Torvalds's avatar
      Merge tag 'pci-v4.18-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · cd993fc4
      Linus Torvalds authored
      Pull PCI fixes from Bjorn Helgaas:
      
       - Fix crash caused by endpoint library initialization order change
         (Alan Douglas)
      
       - Fix shpchp NULL pointer dereference regression on non-ACPI platforms
         (Bjorn Helgaas)
      
       - Move PCI_DOMAINS selection to fix build regression (Lorenzo
         Pieralisi)
      
      * tag 'pci-v4.18-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
        PCI: controller: Move PCI_DOMAINS selection to arch Kconfig
        PCI: Initialize endpoint library before controllers
        PCI: shpchp: Manage SHPC unconditionally on non-ACPI systems
      cd993fc4
    • Linus Torvalds's avatar
      Merge tag 'pm-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 5e4e8c55
      Linus Torvalds authored
      Pull power management fixes from Rafael Wysocki:
       "These fix up recently added features (the Kryo cpufreq driver and
        performance states coverage in the generic power domains framework),
        add missing documentation for a recently added sysfs knob in the
        intel_pstate driver and fix an error in its documentation.
      
        Specifics:
      
         - Fix the initialization time error handling in the recently added
           Kryo cpufreq driver (Dan Carpenter).
      
         - Fix up the recently added coverage of performance states in the
           generic power domains (genpd) framework (Viresh Kumar).
      
         - Add missing documentation of the new hwp_dynamic_boost sysfs knob
           in the intel_pstate driver (Rafael Wysocki).
      
         - Fix incorrect sysfs path in the intel_pstate driver documentation
           (Rafael Wysocki)"
      
      * tag 'pm-4.18-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        Documentation: intel_pstate: Describe hwp_dynamic_boost sysfs knob
        Documentation: admin-guide: intel_pstate: Fix sysfs path
        PM / Domains: Rename opp_node to np
        PM / Domains: Fix return value of of_genpd_opp_to_performance_state()
        cpufreq: qcom-kryo: Fix error handling in probe()
      5e4e8c55
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-2018-06-29' of git://anongit.freedesktop.org/drm/drm · 48a3c64b
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "Nothing too major this round:
      
         - small set of mali-dp fixes
      
         - single meson fix
      
         - a bunch of amdgpu fixes (one makes non-4k page sizes not be a bad
           experience)"
      
      * tag 'drm-fixes-2018-06-29' of git://anongit.freedesktop.org/drm/drm:
        drm/amd/display: release spinlock before committing updates to stream
        drm/amdgpu:Support new VCN FW version naming convention
        drm/amdgpu: fix UBSAN: Undefined behaviour for amdgpu_fence.c
        drm/meson: Fix an un-handled error path in 'meson_drv_bind_master()'
        drm/amdgpu: GPU vs CPU page size fixes in amdgpu_vm_bo_split_mapping
        drm/amdgpu: Count disabled CRTCs in commit tail earlier
        drm/mali-dp: Rectify the width and height passed to rotmem_required()
        drm/arm/malidp: Preserve LAYER_FORMAT contents when setting format
        drm: mali-dp: Enable Global SE interrupts mask for DP500
        drm/arm/malidp: Ensure that the crtcs are shutdown before removing any encoder/connector
      48a3c64b
    • Linus Torvalds's avatar
      Merge tag 'for-4.18/dm-fixes' of... · ff23908b
      Linus Torvalds authored
      Merge tag 'for-4.18/dm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm
      
      Pull device mapper fixes from Mike Snitzer:
      
       - Fix dm core to use more efficient bio_split() instead of
         bio_clone_bioset(). Also fixes splitting bio that has integrity
         payload.
      
       - Three fixes related to properly validating DAX capabilities of a
         stacked DM device that will advertise DAX support.
      
       - Update DM writecache target to use 2-factor allocator arguments. Kees
         says this is the last related change for 4.18.
      
       - Fix DM zoned target to use GFP_NOIO to avoid triggering reclaim
         during IO submission (caught by lockdep).
      
       - Fix DM thinp to gracefully recover from running out of data space
         while a previous async discard completes (whereby freeing space).
      
       - Fix DM thinp's metadata transaction commit to avoid needless work.
      
      * tag 'for-4.18/dm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm:
        dm: prevent DAX mounts if not supported
        dax: check for QUEUE_FLAG_DAX in bdev_dax_supported()
        pmem: only set QUEUE_FLAG_DAX for fsdax mode
        dm thin: handle running out of data space vs concurrent discard
        dm raid: don't use 'const' in function return
        dm zoned: avoid triggering reclaim from inside dmz_map()
        dm writecache: use 2-factor allocator arguments
        dm thin metadata: remove needless work from __commit_transaction
        dm: use bio_split() when splitting out the already processed bio
      ff23908b
    • Jens Axboe's avatar
      Merge branch 'nvme-4.18' of git://git.infradead.org/nvme into for-linus · 49f1c610
      Jens Axboe authored
      Pull single NVMe fix from Christoph.
      
      * 'nvme-4.18' of git://git.infradead.org/nvme:
        nvme-rdma: fix possible double free of controller async event buffer
      49f1c610
    • Bart Van Assche's avatar
      drbd: Fix drbd_request_prepare() discard handling · fad2d4ef
      Bart Van Assche authored
      Fix the test that verifies whether bio_op(bio) represents a discard
      or write zeroes operation. Compile-tested only.
      
      Cc: Philipp Reisner <philipp.reisner@linbit.com>
      Cc: Lars Ellenberg <lars.ellenberg@linbit.com>
      Fixes: 7435e901
      
       ("drbd: zero-out partial unaligned discards on local backend")
      Signed-off-by: default avatarBart Van Assche <bart.vanassche@wdc.com>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      fad2d4ef
    • Jens Axboe's avatar
      blk-mq: don't queue more if we get a busy return · 1f57f8d4
      Jens Axboe authored
      
      
      Some devices have different queue limits depending on the type of IO. A
      classic case is SATA NCQ, where some commands can queue, but others
      cannot. If we have NCQ commands inflight and encounter a non-queueable
      command, the driver returns busy. Currently we attempt to dispatch more
      from the scheduler, if we were able to queue some commands. But for the
      case where we ended up stopping due to BUSY, we should not attempt to
      retrieve more from the scheduler. If we do, we can get into a situation
      where we attempt to queue a non-queueable command, get BUSY, then
      successfully retrieve more commands from that scheduler and queue those.
      This can repeat forever, starving the non-queuable command indefinitely.
      
      Fix this by NOT attempting to pull more commands from the scheduler, if
      we get a BUSY return. This should also be more optimal in terms of
      letting requests stay in the scheduler for as long as possible, if we
      get a BUSY due to the regular out-of-tags condition.
      
      Reviewed-by: default avatarOmar Sandoval <osandov@fb.com>
      Reviewed-by: default avatarMing Lei <ming.lei@redhat.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      1f57f8d4
    • Avi Kivity's avatar
      aio: mark __aio_sigset::sigmask const · 2cd3ae21
      Avi Kivity authored
      
      
      io_pgetevents() will not change the signal mask.  Mark it const to make
      it clear and to reduce the need for casts in user code.
      
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarAvi Kivity <avi@scylladb.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      [hch: reapply the patch that got incorrectly reverted]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2cd3ae21
    • Christoph Hellwig's avatar
      net: handle NULL ->poll gracefully · e88958e6
      Christoph Hellwig authored
      
      
      The big aio poll revert broke various network protocols that don't
      implement ->poll as a patch in the aio poll serie removed sock_no_poll
      and made the common code handle this case.
      
      Reported-by: default avatar <syzbot+57727883dbad76db2ef0@syzkaller.appspotmail.com>
      Reported-by: default avatar <syzbot+cdb0d3176b53d35ad454@syzkaller.appspotmail.com>
      Reported-by: default avatar <syzbot+2c7e8f74f8b2571c87e8@syzkaller.appspotmail.com>
      Reported-by: default avatarTetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
      Fixes: a11e1d43
      
       ("Revert changes to convert to ->poll_mask() and aio IOCB_CMD_POLL")
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      e88958e6
    • Rafael J. Wysocki's avatar
      Merge branch 'pm-domains' · e27b4d4a
      Rafael J. Wysocki authored
      Merge fixups for the recent extenstion of the generic power domains
      (genpd) framework covering performance states.
      
      * pm-domains:
        PM / Domains: Rename opp_node to np
        PM / Domains: Fix return value of of_genpd_opp_to_performance_state()
      e27b4d4a
    • Wolfram Sang's avatar
      i2c: gpio: initialize SCL to HIGH again · 12b731dd
      Wolfram Sang authored
      It seems that during the conversion from gpio* to gpiod*, the initial
      state of SCL was wrongly switched to LOW. Fix it to be HIGH again.
      
      Fixes: 7bb75029
      
       ("i2c: gpio: Enforce open drain through gpiolib")
      Signed-off-by: default avatarWolfram Sang <wsa+renesas@sang-engineering.com>
      Tested-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
      Reviewed-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
      Cc: stable@kernel.org
      12b731dd
    • Peter Rosin's avatar
      i2c: smbus: kill memory leak on emulated and failed DMA SMBus xfers · 9aa61367
      Peter Rosin authored
      If DMA safe memory was allocated, but the subsequent I2C transfer
      fails the memory is leaked. Plug this leak.
      
      Fixes: 8a77821e
      
       ("i2c: smbus: use DMA safe buffers for emulated SMBus transactions")
      Signed-off-by: default avatarPeter Rosin <peda@axentia.se>
      Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
      Cc: stable@kernel.org
      9aa61367