1. 17 May, 2018 13 commits
    • Linus Walleij's avatar
      regulator: wm8994: Pass descriptor instead of GPIO number · 3c6b38d4
      Linus Walleij authored
      Instead of passing a global GPIO number for the enable GPIO, pass
      a descriptor looked up from the device tree node or the board file
      decriptor table for the regulator.
      
      There is a single board file passing the GPIOs for LDO1 and LDO2
      through platform data, so augment this to pass descriptors
      associated with the i2c device as well.
      
      The special GPIO enable DT property for the enable GPIO is
      nonstandard but this was accomodated in
      commit 6a537d48
      "gpio: of: Support regulator nonstandard GPIO properties".
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Acked-by: default avatarCharles Keepax <ckeepax@opensource.cirrus.com>
      Acked-by: default avatarLee Jones <lee.jones@linaro.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      3c6b38d4
    • Maciej Purski's avatar
      regulator: core: Change voltage setting path · 456e7cdf
      Maciej Purski authored
      On Odroid XU3/4 and other Exynos5422 based boards there is a case, that
      different devices on the board are supplied by different regulators
      with non-fixed voltages. If one of these devices temporarily requires
      higher voltage, there might occur a situation that the spread between
      two devices' voltages is so high, that there is a risk of changing
      'high' and 'low' states on the interconnection between devices powered
      by those regulators.
      
      Uncoupled regulators should be a special case of coupled regulators, so
      they should share a common voltage setting path. When enabling,
      disabling or setting voltage of a coupled regulator, all coupled
      regulators should be locked. Regulator's supplies should be locked, when
      setting voltage of a single regulator. Enabling a coupled regulator or
      setting its voltage should not be possible if some of its coupled
      regulators, has not been registered.
      
      Add function for locking coupled regulators and supplies. Extract
      a new function regulator_set_voltage_rdev() from
      regulator_set_voltage_unlocked(), which is called when setting
      voltage of a single regulator.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      456e7cdf
    • Maciej Purski's avatar
      regulator: core: Add voltage balancing mechanism · 69686176
      Maciej Purski authored
      On Odroid XU3/4 and other Exynos5422 based boards there is a case, that
      different devices on the board are supplied by different regulators
      with non-fixed voltages. If one of these devices temporarily requires
      higher voltage, there might occur a situation that the spread between
      two devices' voltages is so high, that there is a risk of changing
      'high' and 'low' states on the interconnection between devices powered
      by those regulators.
      
      Introduce new function regulator_balance_voltage(), which
      keeps max_spread constraint fulfilled between a group of coupled
      regulators. It should be called if a regulator changes its
      voltage or after disabling or enabling. Disabled regulators should
      follow changes of the enabled ones, but their consumers' demands
      shouldn't be taken into account while calculating voltage of other
      coupled regulators.
      
      Find voltages, which are closest to suiting all the consumers' demands,
      while fulfilling max_spread constraint, keeping the following rules:
      - if one regulator is about to rise its voltage, rise others
        voltages in order to keep the max_spread
      - if a regulator, which has caused rising other regulators, is
        lowered, lower other regulators if possible
      - if one regulator is about to lower its voltage, but it hasn't caused
        rising other regulators, don't change its voltage if it breaks the
        max_spread
      
      Change regulators' voltages step by step, keeping max_spread constraint
      fulfilled all the time. Function regulator_get_optimal_voltage()
      should find the best possible change for the regulator, which doesn't
      break max_spread constraint. In function regulator_balance_voltage()
      optimize number of steps by finding highest voltage difference on
      each iteration.
      
      If a regulator, which is about to change its voltage, is not coupled,
      method regulator_get_optimal_voltage() should simply return the lowest
      voltage fulfilling consumers' demands.
      
      Coupling should be checked only if the system is in PM_SUSPEND_ON state.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      69686176
    • Maciej Purski's avatar
      regulator: core: Resolve coupled regulators · d3d64537
      Maciej Purski authored
      On Odroid XU3/4 and other Exynos5422 based boards there is a case, that
      different devices on the board are supplied by different regulators
      with non-fixed voltages. If one of these devices temporarily requires
      higher voltage, there might occur a situation that the spread between
      two devices' voltages is so high, that there is a risk of changing
      'high' and 'low' states on the interconnection between devices powered
      by those regulators.
      
      Fill coupling descriptor with data obtained from DTS using previously
      defined of_functions. Fail to register a regulator, if some data
      inconsistency occurs. If some coupled regulators are not yet registered,
      don't fail to register, but try to resolve them in late init call.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      d3d64537
    • Maciej Purski's avatar
      regulator: core: Parse coupled regulators properties · a085a31a
      Maciej Purski authored
      On Odroid XU3/4 and other Exynos5422 based boards there is a case, that
      different devices on the board are supplied by different regulators
      with non-fixed voltages. If one of these devices temporarily requires
      higher voltage, there might occur a situation that the spread between
      devices' voltages is so high, that there is a risk of changing
      'high' and 'low' states on the interconnection between devices powered
      by those regulators.
      
      Add new structure "coupling_desc" to regulator_dev, which contains
      pointers to all coupled regulators including the owner of the structure,
      number of coupled regulators and counter of currently resolved
      regulators.
      
      Add of_functions to parse all data needed in regulator coupling.
      Provide method to check DTS data consistency. Check if each coupled
      regulator's max_spread is equal and if their lists of regulators match.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      a085a31a
    • Maciej Purski's avatar
      regulator: bindings: Add properties for coupled regulators · f98618b3
      Maciej Purski authored
      Some regulators require keeping their voltage spread below defined
      max_spread.
      
      Add properties to provide information on regulators' coupling.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Reviewed-by: default avatarRob Herring <robh@kernel.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      f98618b3
    • Maciej Purski's avatar
      regulator: core: Make locks re-entrant · 66cf9a7e
      Maciej Purski authored
      Setting voltage, enabling/disabling regulators requires operations on
      all regulators related with the regulator being changed. Therefore,
      all of them should be locked for the whole operation. With the current
      locking implementation, adding additional dependency (regulators
      coupling) causes deadlocks in some cases.
      
      Introduce a possibility to attempt to lock a mutex multiple times
      by the same task without waiting on a mutex. This should handle all
      reasonable coupling-supplying combinations, especially when two coupled
      regulators share common supplies. The only situation that should be
      forbidden is simultaneous coupling and supplying between a pair of
      regulators.
      
      The idea is based on clk core.
      Signed-off-by: default avatarMaciej Purski <m.purski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      66cf9a7e
    • Linus Walleij's avatar
      regulator: s2mps11: Pass descriptor instead of GPIO number · 0369e02b
      Linus Walleij authored
      Instead of passing a global GPIO number for the enable GPIO, pass
      a descriptor looked up with the standard devm_gpiod_get_optional()
      call.
      
      This regulator supports passing platform data, but enable/sleep
      regulators are looked up from the device tree exclusively, so
      we can need not touch other files.
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Reviewed-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Tested-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      0369e02b
    • Linus Walleij's avatar
      regulator: max77686: Pass descriptor instead of GPIO number · c89c00e2
      Linus Walleij authored
      Instead of passing a global GPIO number, pass a descriptor looked
      up from the device tree configuration node.
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Reviewed-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Tested-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      c89c00e2
    • Linus Walleij's avatar
      regulator: arizona-ldo1: Look up a descriptor and pass to the core · e1739e86
      Linus Walleij authored
      Instead of passing a global GPIO number, pass a descriptor looked
      up with the standard devm_gpiod_get_optional() call.
      
      We have augmented the GPIO core to look up the regulator special
      GPIO "wlf,ldoena" in commit 6a537d48
      "gpio: of: Support regulator nonstandard GPIO properties".
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Acked-by: default avatarCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      e1739e86
    • David Collins's avatar
      regulator: of: add support for allowed modes configuration · 54557ad9
      David Collins authored
      Add support for configuring the machine constraints
      valid_modes_mask element based on a list of allowed modes
      specified via a device tree property.
      Signed-off-by: default avatarDavid Collins <collinsd@codeaurora.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      54557ad9
    • David Collins's avatar
      regulator: of: add property for allowed modes specification · d73e2842
      David Collins authored
      Add a common device tree property for regulator nodes to support
      the specification of allowed operating modes.
      Signed-off-by: default avatarDavid Collins <collinsd@codeaurora.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      d73e2842
    • Douglas Anderson's avatar
      regulator: core: Allow for regulators that can't be read at bootup · 84b3a7c9
      Douglas Anderson authored
      Regulators attached via RPMh on Qualcomm sdm845 apparently are
      write-only.  Specifically you can send a request for a certain voltage
      but you can't read back to see what voltage you've requested.  What
      this means is that at bootup we have absolutely no idea what voltage
      we could be at.
      
      As discussed in the patches to try to support the RPMh regulators [1],
      the fact that regulators are write-only means that its driver's
      get_voltage_sel() should return an error code if it's called before
      any calls to set_voltage_sel().  This causes problems in
      machine_constraints_voltage() when trying to apply the constraints.
      
      A proposed fix was to come up with an error code that could be
      returned by get_voltage_sel() which would cause the regulator
      framework to simply try setting the voltage with the current
      constraints.
      
      In this patch I propose the error code -ENOTRECOVERABLE.  In errno.h
      this error is described as "State not recoverable".  Though the error
      code was originally intended "for robust mutexes", the description of
      the error code seems to apply here because we can't read the state of
      the regulator.  Also note that the only existing user of this error
      code in the regulator framework is tps65090-regulator.c which returns
      this error code from the enable() call (not get_voltage() or
      get_voltage_sel()), so there should be no existing regulators that
      might accidentally get the new behavior.  (Side note is that tps65090
      seems to interpret this error code to mean an error that you can't
      recover from rather than some data that can't be recovered).
      
      [1] https://patchwork.kernel.org/patch/10340897/Signed-off-by: default avatarDouglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      84b3a7c9
  2. 09 May, 2018 2 commits
  3. 05 May, 2018 2 commits
    • Changbin Du's avatar
      regulator: add dummy function of_find_regulator_by_node · 08813e0e
      Changbin Du authored
      If device tree is not enabled, of_find_regulator_by_node() should have
      a dummy function since the function call is still there.
      
      This is to fix build error after CONFIG_NO_AUTO_INLINE is introduced.
      If this option is enabled, GCC will not auto-inline functions that are
      not explicitly marked as inline.
      
      In this case (no CONFIG_OF), the copmiler will report error in function
      regulator_dev_lookup().
      
      W/O NO_AUTO_INLINE, function of_get_regulator() is auto-inlined and then
      the call to of_find_regulator_by_node() is optimized out since
      of_get_regulator() always return NULL.
      
      W/ NO_AUTO_INLINE, the return value of of_get_regulator() is a variable
      so the call to of_find_regulator_by_node() cannot be optimized out. So
      we need a stub of_find_regulator_by_node().
      
      static struct regulator_dev *regulator_dev_lookup(struct device *dev,
      						  const char *supply)
      {
      	struct regulator_dev *r = NULL;
      	struct device_node *node;
      	struct regulator_map *map;
      	const char *devname = NULL;
      
      	regulator_supply_alias(&dev, &supply);
      
      	/* first do a dt based lookup */
      	if (dev && dev->of_node) {
      		node = of_get_regulator(dev, supply);
      		if (node) {
      			r = of_find_regulator_by_node(node);
      			if (r)
      				return r;
      	...
      Signed-off-by: default avatarChangbin Du <changbin.du@intel.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      08813e0e
    • Fabio Estevam's avatar
      regulator: pfuze100: Make the node name generic · 60891ceb
      Fabio Estevam authored
      According to Devicetree Specification v0.2 document:
      
      "The name of a node should be somewhat generic, reflecting the function
      of the device and not its precise programming model."
      
      Do as suggested in the binding example.
      Signed-off-by: default avatarFabio Estevam <fabio.estevam@nxp.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      60891ceb
  4. 01 May, 2018 1 commit
  5. 23 Apr, 2018 6 commits
  6. 20 Apr, 2018 2 commits
  7. 18 Apr, 2018 1 commit
  8. 17 Apr, 2018 2 commits
  9. 16 Apr, 2018 6 commits
    • Linus Walleij's avatar
      regulator: ab8500: Drop AB8540/9540 support · ec1ba3e5
      Linus Walleij authored
      The AB8540 was an evolved version of the AB8500, but it was never
      mass produced or put into products, only reference designs exist.
      The upstream support was never completed and it is unlikely that
      this will happen so drop the support for now to simplify
      maintenance of the AB8500.
      
      Cc: Loic Pallardy <loic.pallardy@st.com>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      ec1ba3e5
    • Linus Torvalds's avatar
      Linux 4.17-rc1 · 60cc43fc
      Linus Torvalds authored
      60cc43fc
    • Linus Torvalds's avatar
      Merge tag 'for-4.17-part2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · e37563bb
      Linus Torvalds authored
      Pull more btrfs updates from David Sterba:
       "We have queued a few more fixes (error handling, log replay,
        softlockup) and the rest is SPDX updates that touche almost all files
        so the diffstat is long"
      
      * tag 'for-4.17-part2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        btrfs: Only check first key for committed tree blocks
        btrfs: add SPDX header to Kconfig
        btrfs: replace GPL boilerplate by SPDX -- sources
        btrfs: replace GPL boilerplate by SPDX -- headers
        Btrfs: fix loss of prealloc extents past i_size after fsync log replay
        Btrfs: clean up resources during umount after trans is aborted
        btrfs: Fix possible softlock on single core machines
        Btrfs: bail out on error during replay_dir_deletes
        Btrfs: fix NULL pointer dereference in log_dir_items
      e37563bb
    • Linus Torvalds's avatar
      Merge tag '4.17-rc1SMB3-Fixes' of git://git.samba.org/sfrench/cifs-2.6 · 09c9b0ea
      Linus Torvalds authored
      Pull cifs fixes from Steve French:
       "SMB3 fixes, a few for stable, and some important cleanup work from
        Ronnie of the smb3 transport code"
      
      * tag '4.17-rc1SMB3-Fixes' of git://git.samba.org/sfrench/cifs-2.6:
        cifs: change validate_buf to validate_iov
        cifs: remove rfc1002 hardcoded constants from cifs_discard_remaining_data()
        cifs: Change SMB2_open to return an iov for the error parameter
        cifs: add resp_buf_size to the mid_q_entry structure
        smb3.11: replace a 4 with server->vals->header_preamble_size
        cifs: replace a 4 with server->vals->header_preamble_size
        cifs: add pdu_size to the TCP_Server_Info structure
        SMB311: Improve checking of negotiate security contexts
        SMB3: Fix length checking of SMB3.11 negotiate request
        CIFS: add ONCE flag for cifs_dbg type
        cifs: Use ULL suffix for 64-bit constant
        SMB3: Log at least once if tree connect fails during reconnect
        cifs: smb2pdu: Fix potential NULL pointer dereference
      09c9b0ea
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · f0d98d85
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "This is a set of minor (and safe changes) that didn't make the initial
        pull request plus some bug fixes.
      
        The status handling code is actually a running regression from the
        previous merge window which had an incomplete fix (now reverted) and
        most of the remaining bug fixes are for problems older than the
        current merge window"
      
      [ Side note: this merge also takes the base kernel git repository to 6+
        million objects for the first time. Technically we hit it a couple of
        merges ago already if you count all the tag objects, but now it
        reaches 6M+ objects reachable from HEAD.
      
        I was joking around that that's when I should switch to 5.0, because
        3.0 happened at the 2M mark, and 4.0 happened at 4M objects. But
        probably not, even if numerology is about as good a reason as any.
      
                                                                    - Linus ]
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        scsi: devinfo: Add Microsoft iSCSI target to 1024 sector blacklist
        scsi: cxgb4i: silence overflow warning in t4_uld_rx_handler()
        scsi: dpt_i2o: Use after free in I2ORESETCMD ioctl
        scsi: core: Make scsi_result_to_blk_status() recognize CONDITION MET
        scsi: core: Rename __scsi_error_from_host_byte() into scsi_result_to_blk_status()
        Revert "scsi: core: return BLK_STS_OK for DID_OK in __scsi_error_from_host_byte()"
        scsi: aacraid: Insure command thread is not recursively stopped
        scsi: qla2xxx: Correct setting of SAM_STAT_CHECK_CONDITION
        scsi: qla2xxx: correctly shift host byte
        scsi: qla2xxx: Fix race condition between iocb timeout and initialisation
        scsi: qla2xxx: Avoid double completion of abort command
        scsi: qla2xxx: Fix small memory leak in qla2x00_probe_one on probe failure
        scsi: scsi_dh: Don't look for NULL devices handlers by name
        scsi: core: remove redundant assignment to shost->use_blk_mq
      f0d98d85
    • Linus Torvalds's avatar
      Merge tag 'kbuild-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild · ca71b3ba
      Linus Torvalds authored
      Pull more Kbuild updates from Masahiro Yamada:
      
       - pass HOSTLDFLAGS when compiling single .c host programs
      
       - build genksyms lexer and parser files instead of using shipped
         versions
      
       - rename *-asn1.[ch] to *.asn1.[ch] for suffix consistency
      
       - let the top .gitignore globally ignore artifacts generated by flex,
         bison, and asn1_compiler
      
       - let the top Makefile globally clean artifacts generated by flex,
         bison, and asn1_compiler
      
       - use safer .SECONDARY marker instead of .PRECIOUS to prevent
         intermediate files from being removed
      
       - support -fmacro-prefix-map option to make __FILE__ a relative path
      
       - fix # escaping to prepare for the future GNU Make release
      
       - clean up deb-pkg by using debian tools instead of handrolled
         source/changes generation
      
       - improve rpm-pkg portability by supporting kernel-install as a
         fallback of new-kernel-pkg
      
       - extend Kconfig listnewconfig target to provide more information
      
      * tag 'kbuild-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        kconfig: extend output of 'listnewconfig'
        kbuild: rpm-pkg: use kernel-install as a fallback for new-kernel-pkg
        Kbuild: fix # escaping in .cmd files for future Make
        kbuild: deb-pkg: split generating packaging and build
        kbuild: use -fmacro-prefix-map to make __FILE__ a relative path
        kbuild: mark $(targets) as .SECONDARY and remove .PRECIOUS markers
        kbuild: rename *-asn1.[ch] to *.asn1.[ch]
        kbuild: clean up *-asn1.[ch] patterns from top-level Makefile
        .gitignore: move *-asn1.[ch] patterns to the top-level .gitignore
        kbuild: add %.dtb.S and %.dtb to 'targets' automatically
        kbuild: add %.lex.c and %.tab.[ch] to 'targets' automatically
        genksyms: generate lexer and parser during build instead of shipping
        kbuild: clean up *.lex.c and *.tab.[ch] patterns from top-level Makefile
        .gitignore: move *.lex.c *.tab.[ch] patterns to the top-level .gitignore
        kbuild: use HOSTLDFLAGS for single .c executables
      ca71b3ba
  10. 15 Apr, 2018 5 commits
    • Linus Torvalds's avatar
      Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 9fb71c2f
      Linus Torvalds authored
      Pull x86 fixes from Thomas Gleixner:
       "A set of fixes and updates for x86:
      
         - Address a swiotlb regression which was caused by the recent DMA
           rework and made driver fail because dma_direct_supported() returned
           false
      
         - Fix a signedness bug in the APIC ID validation which caused invalid
           APIC IDs to be detected as valid thereby bloating the CPU possible
           space.
      
         - Fix inconsisten config dependcy/select magic for the MFD_CS5535
           driver.
      
         - Fix a corruption of the physical address space bits when encryption
           has reduced the address space and late cpuinfo updates overwrite
           the reduced bit information with the original value.
      
         - Dominiks syscall rework which consolidates the architecture
           specific syscall functions so all syscalls can be wrapped with the
           same macros. This allows to switch x86/64 to struct pt_regs based
           syscalls. Extend the clearing of user space controlled registers in
           the entry patch to the lower registers"
      
      * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/apic: Fix signedness bug in APIC ID validity checks
        x86/cpu: Prevent cpuinfo_x86::x86_phys_bits adjustment corruption
        x86/olpc: Fix inconsistent MFD_CS5535 configuration
        swiotlb: Use dma_direct_supported() for swiotlb_ops
        syscalls/x86: Adapt syscall_wrapper.h to the new syscall stub naming convention
        syscalls/core, syscalls/x86: Rename struct pt_regs-based sys_*() to __x64_sys_*()
        syscalls/core, syscalls/x86: Clean up compat syscall stub naming convention
        syscalls/core, syscalls/x86: Clean up syscall stub naming convention
        syscalls/x86: Extend register clearing on syscall entry to lower registers
        syscalls/x86: Unconditionally enable 'struct pt_regs' based syscalls on x86_64
        syscalls/x86: Use 'struct pt_regs' based syscall calling for IA32_EMULATION and x32
        syscalls/core: Prepare CONFIG_ARCH_HAS_SYSCALL_WRAPPER=y for compat syscalls
        syscalls/x86: Use 'struct pt_regs' based syscall calling convention for 64-bit syscalls
        syscalls/core: Introduce CONFIG_ARCH_HAS_SYSCALL_WRAPPER=y
        x86/syscalls: Don't pointlessly reload the system call number
        x86/mm: Fix documentation of module mapping range with 4-level paging
        x86/cpuid: Switch to 'static const' specifier
      9fb71c2f
    • Linus Torvalds's avatar
      Merge branch 'x86-pti-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 6b0a02e8
      Linus Torvalds authored
      Pull x86 pti updates from Thomas Gleixner:
       "Another series of PTI related changes:
      
         - Remove the manual stack switch for user entries from the idtentry
           code. This debloats entry by 5k+ bytes of text.
      
         - Use the proper types for the asm/bootparam.h defines to prevent
           user space compile errors.
      
         - Use PAGE_GLOBAL for !PCID systems to gain back performance
      
         - Prevent setting of huge PUD/PMD entries when the entries are not
           leaf entries otherwise the entries to which the PUD/PMD points to
           and are populated get lost"
      
      * 'x86-pti-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/pgtable: Don't set huge PUD/PMD on non-leaf entries
        x86/pti: Leave kernel text global for !PCID
        x86/pti: Never implicitly clear _PAGE_GLOBAL for kernel image
        x86/pti: Enable global pages for shared areas
        x86/mm: Do not forbid _PAGE_RW before init for __ro_after_init
        x86/mm: Comment _PAGE_GLOBAL mystery
        x86/mm: Remove extra filtering in pageattr code
        x86/mm: Do not auto-massage page protections
        x86/espfix: Document use of _PAGE_GLOBAL
        x86/mm: Introduce "default" kernel PTE mask
        x86/mm: Undo double _PAGE_PSE clearing
        x86/mm: Factor out pageattr _PAGE_GLOBAL setting
        x86/entry/64: Drop idtentry's manual stack switch for user entries
        x86/uapi: Fix asm/bootparam.h userspace compilation errors
      6b0a02e8
    • Linus Torvalds's avatar
      Merge branch 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 71b8ebbf
      Linus Torvalds authored
      Pull scheduler fixes from Thomas Gleixner:
       "A few scheduler fixes:
      
         - Prevent a bogus warning vs. runqueue clock update flags in
           do_sched_rt_period_timer()
      
         - Simplify the helper functions which handle requests for skipping
           the runqueue clock updat.
      
         - Do not unlock the tunables mutex in the error path of the cpu
           frequency scheduler utils. Its not held.
      
         - Enforce proper alignement for 'struct util_est' in sched_avg to
           prevent a misalignment fault on IA64"
      
      * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        sched/core: Force proper alignment of 'struct util_est'
        sched/core: Simplify helpers for rq clock update skip requests
        sched/rt: Fix rq->clock_update_flags < RQCF_ACT_SKIP warning
        sched/cpufreq/schedutil: Fix error path mutex unlock
      71b8ebbf
    • Linus Torvalds's avatar
      Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 174e7194
      Linus Torvalds authored
      Pull more perf updates from Thomas Gleixner:
       "A rather large set of perf updates:
      
        Kernel:
      
         - Fix various initialization issues
      
         - Prevent creating [ku]probes for not CAP_SYS_ADMIN users
      
        Tooling:
      
         - Show only failing syscalls with 'perf trace --failure' (Arnaldo
           Carvalho de Melo)
      
                  e.g: See what 'openat' syscalls are failing:
      
              # perf trace --failure -e openat
               762.323 ( 0.007 ms): VideoCapture/4566 openat(dfd: CWD, filename: /dev/video2) = -1 ENOENT No such file or directory
               <SNIP N /dev/videoN open attempts... sigh, where is that improvised camera lid?!? >
               790.228 ( 0.008 ms): VideoCapture/4566 openat(dfd: CWD, filename: /dev/video63) = -1 ENOENT No such file or directory
              ^C#
      
         - Show information about the event (freq, nr_samples, total
           period/nr_events) in the annotate --tui and --stdio2 'perf
           annotate' output, similar to the first line in the 'perf report
           --tui', but just for the samples for a the annotated symbol
           (Arnaldo Carvalho de Melo)
      
         - Introduce 'perf version --build-options' to show what features were
           linked, aliased as well as a shorter 'perf -vv' (Jin Yao)
      
         - Add a "dso_size" sort order (Kim Phillips)
      
         - Remove redundant ')' in the tracepoint output in 'perf trace'
           (Changbin Du)
      
         - Synchronize x86's cpufeatures.h, no effect on toolss (Arnaldo
           Carvalho de Melo)
      
         - Show group details on the title line in the annotate browser and
           'perf annotate --stdio2' output, so that the per-event columns can
           have headers (Arnaldo Carvalho de Melo)
      
         - Fixup vertical line separating metrics from instructions and
           cleaning unused lines at the bottom, both in the annotate TUI
           browser (Arnaldo Carvalho de Melo)
      
         - Remove duplicated 'samples' in lost samples warning in
           'perf report' (Arnaldo Carvalho de Melo)
      
         - Synchronize i915_drm.h, silencing the perf build process,
           automagically adding support for the new DRM_I915_QUERY ioctl
           (Arnaldo Carvalho de Melo)
      
         - Make auxtrace_queues__add_buffer() allocate struct buffer, from a
           patchkit already applied (Adrian Hunter)
      
         - Fix the --stdio2/TUI annotate output to include group details, be
           it for a recorded '{a,b,f}' explicit event group or when forcing
           group display using 'perf report --group' for a set of events not
           recorded as a group (Arnaldo Carvalho de Melo)
      
         - Fix display artifacts in the ui browser (base class for the
           annotate and main report/top TUI browser) related to the extra
           title lines work (Arnaldo Carvalho de Melo)
      
         - perf auxtrace refactorings, leftovers from a previously partially
           processed patchset (Adrian Hunter)
      
         - Fix the builtin clang build (Sandipan Das, Arnaldo Carvalho de
           Melo)
      
         - Synchronize i915_drm.h, silencing a perf build warning and in the
           process automagically adding support for a new ioctl command
           (Arnaldo Carvalho de Melo)
      
         - Fix a strncpy issue in uprobe tracing"
      
      * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (36 commits)
        perf/core: Need CAP_SYS_ADMIN to create k/uprobe with perf_event_open()
        tracing/uprobe_event: Fix strncpy corner case
        perf/core: Fix perf_uprobe_init()
        perf/core: Fix perf_kprobe_init()
        perf/core: Fix use-after-free in uprobe_perf_close()
        perf tests clang: Fix function name for clang IR test
        perf clang: Add support for recent clang versions
        perf tools: Fix perf builds with clang support
        perf tools: No need to include namespaces.h in util.h
        perf hists browser: Remove leftover from row returned from refresh
        perf hists browser: Show extra_title_lines in the 'D' debug hotkey
        perf auxtrace: Make auxtrace_queues__add_buffer() do CPU filtering
        tools headers uapi: Synchronize i915_drm.h
        perf report: Remove duplicated 'samples' in lost samples warning
        perf ui browser: Fixup cleaning unused lines at the bottom
        perf annotate browser: Fixup vertical line separating metrics from instructions
        perf annotate: Show group details on the title line
        perf auxtrace: Make auxtrace_queues__add_buffer() allocate struct buffer
        perf/x86/intel: Move regs->flags EXACT bit init
        perf trace: Remove redundant ')'
        ...
      174e7194
    • Linus Torvalds's avatar
      Merge branch 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 19ca90de
      Linus Torvalds authored
      Pull x86 EFI bootup fixlet from Thomas Gleixner:
       "A single fix for an early boot warning caused by invoking
        this_cpu_has() before SMP initialization"
      
      * 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/mm: Fix bogus warning during EFI bootup, use boot_cpu_has() instead of this_cpu_has() in build_cr3_noflush()
      19ca90de