1. 13 Apr, 2018 11 commits
    • Linus Torvalds's avatar
      Merge tag 'apparmor-pr-2018-04-10' of... · 80a17a5f
      Linus Torvalds authored
      Merge tag 'apparmor-pr-2018-04-10' of git://git.kernel.org/pub/scm/linux/kernel/git/jj/linux-apparmor
      
      Pull apparmor updates from John Johansen:
       "Features:
        - add base infrastructure for socket mediation. ABI bump and
          additional checks to ensure only v8 compliant policy uses socket af
          mediation.
        - improve and cleanup dfa verification
        - improve profile attachment logic
           - improve overlapping expression handling
           - add the xattr matching to the attachment logic
        - improve signal mediation handling with stacked labels
        - improve handling of no_new_privs in a label stack
      
        Cleanups and changes:
        - use dfa to parse string split
        - bounded version of label_parse
        - proper line wrap nulldfa.in
        - split context out into task and cred naming to better match usage
        - simplify code in aafs
      
        Bug fixes:
        - fix display of .ns_name for containers
        - fix resource audit messages when auditing peer
        - fix logging of the existence test for signals
        - fix resource audit messages when auditing peer
        - fix display of .ns_name for containers
        - fix an error code in verify_table_headers()
        - fix memory leak on buffer on error exit path
        - fix error returns checks by making size a ssize_t"
      
      * tag 'apparmor-pr-2018-04-10' of git://git.kernel.org/pub/scm/linux/kernel/git/jj/linux-apparmor: (36 commits)
        apparmor: fix memory leak on buffer on error exit path
        apparmor: fix dangling symlinks to policy rawdata after replacement
        apparmor: Fix an error code in verify_table_headers()
        apparmor: fix error returns checks by making size a ssize_t
        apparmor: update MAINTAINERS file git and wiki locations
        apparmor: remove POLICY_MEDIATES_SAFE
        apparmor: add base infastructure for socket mediation
        apparmor: improve overlapping domain attachment resolution
        apparmor: convert attaching profiles via xattrs to use dfa matching
        apparmor: Add support for attaching profiles via xattr, presence and value
        apparmor: cleanup: simplify code to get ns symlink name
        apparmor: cleanup create_aafs() error path
        apparmor: dfa split verification of table headers
        apparmor: dfa add support for state differential encoding
        apparmor: dfa move character match into a macro
        apparmor: update domain transitions that are subsets of confinement at nnp
        apparmor: move context.h to cred.h
        apparmor: move task related defines and fns to task.X files
        apparmor: cleanup, drop unused fn __aa_task_is_confined()
        apparmor: cleanup fixup description of aa_replace_profiles
        ...
      80a17a5f
    • Linus Torvalds's avatar
      Merge tag 'for-linus-20180413' of git://git.kernel.dk/linux-block · edda4153
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "Followup fixes for this merge window. This contains:
      
         - Series from Ming, fixing corner cases in our CPU <-> queue mapping.
      
           This triggered repeated warnings on especially s390, but I also hit
           it in cpu hot plug/unplug testing while doing IO on NVMe on x86-64.
      
         - Another fix from Ming, ensuring that we always order budget and
           driver tag identically, avoiding a deadlock on QD=1 devices.
      
         - Loop locking regression fix from this merge window, from Omar.
      
         - Another loop locking fix, this time missing an unlock, from Tetsuo
           Handa.
      
         - Fix for racing IO submission with device removal from Bart.
      
         - sr reference fix from me, fixing a case where disk change or
           getevents can race with device removal.
      
         - Set of nvme fixes by way of Keith, from various contributors"
      
      * tag 'for-linus-20180413' of git://git.kernel.dk/linux-block: (28 commits)
        nvme: expand nvmf_check_if_ready checks
        nvme: Use admin command effects for admin commands
        nvmet: fix space padding in serial number
        nvme: check return value of init_srcu_struct function
        nvmet: Fix nvmet_execute_write_zeroes sector count
        nvme-pci: Separate IO and admin queue IRQ vectors
        nvme-pci: Remove unused queue parameter
        nvme-pci: Skip queue deletion if there are no queues
        nvme: target: fix buffer overflow
        nvme: don't send keep-alives to the discovery controller
        nvme: unexport nvme_start_keep_alive
        nvme-loop: fix kernel oops in case of unhandled command
        nvme: enforce 64bit offset for nvme_get_log_ext fn
        sr: get/drop reference to device in revalidate and check_events
        blk-mq: Revert "blk-mq: reimplement blk_mq_hw_queue_mapped"
        blk-mq: Avoid that submitting a bio concurrently with device removal triggers a crash
        backing: silence compiler warning using __printf
        blk-mq: remove code for dealing with remapping queue
        blk-mq: reimplement blk_mq_hw_queue_mapped
        blk-mq: don't check queue mapped in __blk_mq_delay_run_hw_queue()
        ...
      edda4153
    • Linus Torvalds's avatar
      Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux · 3e565a35
      Linus Torvalds authored
      Pull more i2c updates from Wolfram Sang:
      
       - hot bugfix for i801 to make laptops with strange BIOS reboot again
         when using SMBUS Host notify
      
       - change to MAINTAINERS creating a specific fallback entry for I2C host
         drivers and settings its status to "Odd fixes"
      
       - a long overdue param checking for the I2C core
      
      * 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
        i2c: add param sanity check to i2c_transfer()
        MAINTAINERS: add maintainer for Renesas I2C related drivers
        MAINTAINERS: remove me as maintainer for I2C host drivers
        i2c: i801: Restore configuration at shutdown
        i2c: i801: Save register SMBSLVCMD value only once
      3e565a35
    • Linus Torvalds's avatar
      Merge tag 'sh-for-4.17' of git://git.libc.org/linux-sh · 1bad9ce1
      Linus Torvalds authored
      Pull arch/sh updates from Rich Felker:
       "Fixes for bugs in futex, device tree, and userspace breakpoint traps,
        and for PCI issues on SH7786"
      
      * tag 'sh-for-4.17' of git://git.libc.org/linux-sh:
        arch/sh: pcie-sh7786: handle non-zero DMA offset
        arch/sh: pcie-sh7786: adjust the memory mapping
        arch/sh: pcie-sh7786: adjust PCI MEM and IO regions
        arch/sh: pcie-sh7786: exclude unusable PCI MEM areas
        arch/sh: pcie-sh7786: mark unavailable PCI resource as disabled
        arch/sh: pci: don't use disabled resources
        arch/sh: make the DMA mapping operations observe dev->dma_pfn_offset
        arch/sh: add sh7786_mm_sel() function
        sh: fix debug trap failure to process signals before return to user
        sh: fix memory corruption of unflattened device tree
        sh: fix futex FUTEX_OP_SET op on userspace addresses
      1bad9ce1
    • Linus Torvalds's avatar
      Merge tag 'arm64-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux · e4e57f20
      Linus Torvalds authored
      Pull more arm64 updates from Will Deacon:
       "A few late updates to address some issues arising from conflicts with
        other trees:
      
         - Removal of Qualcomm-specific Spectre-v2 mitigation in favour of the
           generic SMCCC-based firmware call
      
         - Fix EL2 hardening capability checking, which was bodged to reduce
           conflicts with the KVM tree
      
         - Add some currently unused assembler macros for managing SIMD
           registers which will be used by some crypto code in the next merge
           window"
      
      * tag 'arm64-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
        arm64: assembler: add macros to conditionally yield the NEON under PREEMPT
        arm64: assembler: add utility macros to push/pop stack frames
        arm64: Move the content of bpi.S to hyp-entry.S
        arm64: Get rid of __smccc_workaround_1_hvc_*
        arm64: capabilities: Rework EL2 vector hardening entry
        arm64: KVM: Use SMCCC_ARCH_WORKAROUND_1 for Falkor BP hardening
      e4e57f20
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux · 6c21e433
      Linus Torvalds authored
      Pull  more s390 updates from Martin Schwidefsky:
       "Three notable larger changes next to the usual bug fixing:
      
         - update the email addresses in MAINTAINERS for the s390 folks to use
           the simpler linux.ibm.com domain instead of the old
           linux.vnet.ibm.com
      
         - an update for the zcrypt device driver that removes some old and
           obsolete interfaces and add support for up to 256 crypto adapters
      
         - a rework of the IPL aka boot code"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: (23 commits)
        s390: correct nospec auto detection init order
        s390/zcrypt: Support up to 256 crypto adapters.
        s390/zcrypt: Remove deprecated zcrypt proc interface.
        s390/zcrypt: Remove deprecated ioctls.
        s390/zcrypt: Make ap init functions static.
        MAINTAINERS: update s390 maintainers email addresses
        s390/ipl: remove reipl_method and dump_method
        s390/ipl: correct kdump reipl block checksum calculation
        s390/ipl: remove non-existing functions declaration
        s390: assume diag308 set always works
        s390/ipl: avoid adding scpdata to cmdline during ftp/dvd boot
        s390/ipl: correct ipl parmblock valid checks
        s390/ipl: rely on diag308 store to get ipl info
        s390/ipl: move ipl_flags to ipl.c
        s390/ipl: get rid of ipl_ssid and ipl_devno
        s390/ipl: unite diag308 and scsi boot ipl blocks
        s390/ipl: ensure loadparm valid flag is set
        s390/qdio: lock device while installing IRQ handler
        s390/qdio: clear intparm during shutdown
        s390/ccwgroup: require at least one ccw device
        ...
      6c21e433
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-for-v4.17-rc1' of git://people.freedesktop.org/~airlied/linux · 16e205cf
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "One omap, and one alsa pm fix (we merged the breaking patch via drm
        tree).
      
        Otherwise it's two bunches of amdgpu fixes, removing an unneeded file,
        some DC fixes, HDMI audio regression fix, and some vega12 fixes"
      
      * tag 'drm-fixes-for-v4.17-rc1' of git://people.freedesktop.org/~airlied/linux: (27 commits)
        Revert "drm/amd/display: disable CRTCs with NULL FB on their primary plane (V2)"
        Revert "drm/amd/display: fix dereferencing possible ERR_PTR()"
        drm/amd/display: Fix regamma not affecting full-intensity color values
        drm/amd/display: Fix FBC text console corruption
        drm/amd/display: Only register backlight device if embedded panel connected
        drm/amd/display: fix brightness level after resume from suspend
        drm/amd/display: HDMI has no sound after Panel power off/on
        drm/amdgpu: add MP1 and THM hw ip base reg offset
        drm/amdgpu: fix null pointer panic with direct fw loading on gpu reset
        drm/radeon: add PX quirk for Asus K73TK
        drm/omap: fix crash if there's no video PLL
        drm/amdgpu: Fix memory leaks at amdgpu_init() error path
        drm/amdgpu: Fix PCIe lane width calculation
        drm/radeon: Fix PCIe lane width calculation
        drm/amdgpu/si: implement get/set pcie_lanes asic callback
        drm/amdgpu: Add support for SRBM selection v3
        Revert "drm/amdgpu: Don't change preferred domian when fallback GTT v5"
        drm/amd/powerply: fix power reading on Fiji
        drm/amd/powerplay: Enable ACG SS feature
        drm/amdgpu/sdma: fix mask in emit_pipeline_sync
        ...
      16e205cf
    • Linus Torvalds's avatar
      Merge tag 'trace-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace · affb0280
      Linus Torvalds authored
      Pull tracing fixes from Steven Rostedt:
       "A few clean ups and bug fixes:
      
         - replace open coded "ARRAY_SIZE()" with macro
      
         - updates to uprobes
      
         - bug fix for perf event filter on error path"
      
      * tag 'trace-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
        tracing: Enforce passing in filter=NULL to create_filter()
        trace_uprobe: Simplify probes_seq_show()
        trace_uprobe: Use %lx to display offset
        tracing/uprobe: Add support for overlayfs
        tracing: Use ARRAY_SIZE() macro instead of open coding it
      affb0280
    • Alexey Dobriyan's avatar
      proc: fixup copyright sign · ee9294d6
      Alexey Dobriyan authored
      Add copyright in two files before they get autorubberstamped.
      Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      ee9294d6
    • Linus Torvalds's avatar
      Merge tag 'pci-v4.17-changes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · 0c314a95
      Linus Torvalds authored
      Pull PCI fixes from Bjorn Helgaas:
      
       - mark Extended Tags as broken on Broadcom HT1100 and HT2000 Root Ports
         to fix drm/Xorg hangs and unresponsive keyboards (Sinan Kaya)
      
       - remove useless messages during resource reassignment (Desnes A. Nunes
         do Rosario)
      
      * tag 'pci-v4.17-changes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
        PCI: Remove messages about reassigning resources
        PCI: Mark Broadcom HT1100 and HT2000 Root Port Extended Tags as broken
      0c314a95
    • Linus Torvalds's avatar
      Merge branch 'parisc-4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux · 681857ef
      Linus Torvalds authored
      Pull parisc updates from Helge Deller:
      
       - fix panic when halting system via "shutdown -h now"
      
       - drop own coding in favour of generic CONFIG_COMPAT_BINFMT_ELF
         implementation
      
       - add FPE_CONDTRAP constant: last outstanding parisc-specific cleanup
         for Eric Biedermans siginfo patches
      
       - move some functions to .init and some to .text.hot linker sections
      
      * 'parisc-4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
        parisc: Prevent panic at system halt
        parisc: Switch to generic COMPAT_BINFMT_ELF
        parisc: Move cache flush functions into .text.hot section
        parisc/signal: Add FPE_CONDTRAP for conditional trap handling
      681857ef
  2. 12 Apr, 2018 29 commits
    • Thomas Petazzoni's avatar
      arch/sh: pcie-sh7786: handle non-zero DMA offset · bf9c7e3d
      Thomas Petazzoni authored
      On SuperH, the base of the physical memory might be different from
      zero. In this case, PCI address zero will map to a non-zero physical
      address. In order to make sure that the DMA mapping API takes care of
      this DMA offset, we must fill in the dev->dma_pfn_offset field for PCI
      devices. This gets done in the pcibios_bus_add_device() hook, called
      for each new PCI device detected.
      
      The dma_pfn_offset global variable is re-calculated for every PCI
      controller available on the platform, but that's not an issue because
      its value will each time be exactly the same, as it only depends on
      the memory start address and memory size.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      bf9c7e3d
    • Thomas Petazzoni's avatar
      arch/sh: pcie-sh7786: adjust the memory mapping · 79e1c5e7
      Thomas Petazzoni authored
      The code setting up the PCI -> SuperHighway mapping doesn't take into
      account the fact that the address stored in PCIELARx must be aligned
      with the size stored in PCIELAMRx.
      
      For example, when your physical memory starts at 0x0800_0000 (128 MB),
      a size of 64 MB or 128 MB is fine. However, if you have 256 MB of
      memory, it doesn't work because the base address is not aligned on the
      size.
      
      In such situation, we have to round down the base address to make sure
      it is aligned on the size of the area. For for a 0x0800_0000 base
      address with 256 MB of memory, we will round down to 0x0, and extend
      the size of the mapping to 512 MB.
      
      This allows the mapping to work on platforms that have 256 MB of
      RAM. The current setup would only work with 128 MB of RAM or less.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      79e1c5e7
    • Thomas Petazzoni's avatar
      arch/sh: pcie-sh7786: adjust PCI MEM and IO regions · 5da1bb96
      Thomas Petazzoni authored
      The current definition of the PCIe IO and MEM resources for SH7786
      doesn't match what the datasheet says. For example, for PCIe0
      0xfe100000 is advertised by the datasheet as a PCI IO region, while
      0xfd000000 is advertised as a PCI MEM region. The code currently
      inverts the two.
      
      The SH4A_PCIEPARL and SH4A_PCIEPTCTLR registers allow to define the
      base address and role of the different regions (including whether it's
      a MEM or IO region). However, practical experience on a SH7786 shows
      that if 0xfe100000 is used for LEL and 0xfd000000 for IO, a PCIe
      device using two MEM BARs cannot be accessed at all. Simply using
      0xfe100000 for IO and 0xfd000000 for MEM makes the PCIe device
      accessible.
      
      It is very likely that this was never seen because there are two other
      PCI MEM region listed in the resources. However, for different
      reasons, none of the two other MEM regions are usable on the specific
      SH7786 platform the problem was encountered. Therefore, the last MEM
      region at 0xfe100000 was used to place the BARs, making the device
      non-functional.
      
      This commit therefore adjusts those PCI MEM and IO resources
      definitions so that they match what the datasheet says. They have only
      been tested with PCIe 0.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      5da1bb96
    • Thomas Petazzoni's avatar
      arch/sh: pcie-sh7786: exclude unusable PCI MEM areas · d62e9bf5
      Thomas Petazzoni authored
      Depending on the physical memory layout, some PCI MEM areas are not
      usable. According to the SH7786 datasheet, the PCI MEM area from
      1000_0000 to 13FF_FFFF is only usable if the physical memory layout
      (in MMSELR) is 1, 2, 5 or 6. In all other configurations, this PCI MEM
      area is not usable (because it overlaps with DRAM).
      
      Therefore, this commit adjusts the PCI SH7786 initialization to mark
      the relevant PCI resource as IORESOURCE_DISABLED if we can't use it.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      d62e9bf5
    • Thomas Petazzoni's avatar
      arch/sh: pcie-sh7786: mark unavailable PCI resource as disabled · 7dd7f698
      Thomas Petazzoni authored
      Some PCI MEM resources are marked as IORESOURCE_MEM_32BIT, which means
      they are only usable when the SH core runs in 32-bit mode. In 29-bit
      mode, such memory regions are not usable.
      
      The existing code for SH7786 properly skips such regions when
      configuring the PCIe controller registers. However, because such
      regions are still described in the resource array, the
      pcibios_scanbus() function in the SuperH pci.c will register them to
      the PCI core. Due to this, the PCI core will allocate MEM areas from
      this resource, and assign BARs pointing to this area, even though it's
      unusable.
      
      In order to prevent this from happening, we mark such regions as
      IORESOURCE_DISABLED, which tells the SuperH pci.c pcibios_scanbus()
      function to skip them.
      
      Note that we separate marking the region as disabled from skipping it,
      because other regions will be marked as disabled in follow-up patches.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      7dd7f698
    • Thomas Petazzoni's avatar
      arch/sh: pci: don't use disabled resources · 3aeb93a0
      Thomas Petazzoni authored
      In pcibios_scanbus(), we provide to the PCI core the usable MEM and IO
      regions using pci_add_resource_offset(). We travel through all
      resources available in the "struct pci_channel".
      
      Also, in register_pci_controller(), we travel through all resources to
      request them, making sure they don't conflict with already requested
      resources.
      
      However, some resources may be disabled, in which case they should not
      be requested nor provided to the PCI core.
      
      In the current situation, none of the resources are disabled. However,
      follow-up patches in this series will make some resources disabled,
      making this preliminary change necessary.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      3aeb93a0
    • Thomas Petazzoni's avatar
      arch/sh: make the DMA mapping operations observe dev->dma_pfn_offset · ce883130
      Thomas Petazzoni authored
      Some devices may have a non-zero DMA offset, i.e an offset between the
      DMA address and the physical address. Such an offset can be encoded
      into the dma_pfn_offset field of "struct device", but the SuperH
      implementation of the DMA mapping API does not observe this
      information.
      
      This commit fixes that by ensuring the DMA address is properly
      calculated depending on this DMA offset.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      ce883130
    • Thomas Petazzoni's avatar
      arch/sh: add sh7786_mm_sel() function · bc05aa6e
      Thomas Petazzoni authored
      The SH7786 has different physical memory layout configurations,
      configurable through the MMSELR register. The configuration is
      typically defined by the bootloader, so Linux generally doesn't care.
      
      Except that depending on the configuration, some PCI MEM areas may or
      may not be available. This commit adds a helper function that allows
      to retrieve the current physical memory layout configuration. It will
      be used in a following patch to exclude unusable PCI MEM areas during
      the PCI initialization.
      Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      bc05aa6e
    • Rich Felker's avatar
      sh: fix debug trap failure to process signals before return to user · 96a59899
      Rich Felker authored
      When responding to a debug trap (breakpoint) in userspace, the
      kernel's trap handler raised SIGTRAP but returned from the trap via a
      code path that ignored pending signals, resulting in an infinite loop
      re-executing the trapping instruction.
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      96a59899
    • Rich Felker's avatar
      sh: fix memory corruption of unflattened device tree · eb6b6930
      Rich Felker authored
      unflatten_device_tree() makes use of memblock allocation, and
      therefore must be called before paging_init() migrates the memblock
      allocation data to the bootmem framework. Otherwise the record of the
      allocation for the expanded device tree will be lost, and will
      eventually be clobbered when allocated for another use.
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      eb6b6930
    • Aurelien Jarno's avatar
      sh: fix futex FUTEX_OP_SET op on userspace addresses · 9b7e30ab
      Aurelien Jarno authored
      Commit 00b73d8d ("sh: add working futex atomic ops on userspace
      addresses for smp") changed the futex_atomic_op_inuser function to
      use a loop. In case of the FUTEX_OP_SET op with a userspace address
      containing a value different of 0, this loop is an endless loop.
      
      Fix that by loading the value of oldval from the userspace before doing
      the cmpxchg op, also for the FUTEX_OP_SET case.
      Signed-off-by: default avatarAurelien Jarno <aurelien@aurel32.net>
      Signed-off-by: default avatarRich Felker <dalias@libc.org>
      9b7e30ab
    • Dave Airlie's avatar
      Merge branch 'drm-next-4.17' of git://people.freedesktop.org/~agd5f/linux into drm-next · a10beabb
      Dave Airlie authored
      - Add a PX quirk for radeon
      - Fix flickering and stability issues with DC on some platforms
      - Fix HDMI audio regression
      - Few other misc DC and base driver fixes
      
      * 'drm-next-4.17' of git://people.freedesktop.org/~agd5f/linux:
        Revert "drm/amd/display: disable CRTCs with NULL FB on their primary plane (V2)"
        Revert "drm/amd/display: fix dereferencing possible ERR_PTR()"
        drm/amd/display: Fix regamma not affecting full-intensity color values
        drm/amd/display: Fix FBC text console corruption
        drm/amd/display: Only register backlight device if embedded panel connected
        drm/amd/display: fix brightness level after resume from suspend
        drm/amd/display: HDMI has no sound after Panel power off/on
        drm/amdgpu: add MP1 and THM hw ip base reg offset
        drm/amdgpu: fix null pointer panic with direct fw loading on gpu reset
        drm/radeon: add PX quirk for Asus K73TK
      a10beabb
    • Dave Airlie's avatar
      Merge tag 'drm-misc-next-fixes-2018-04-11' of... · dece02f7
      Dave Airlie authored
      Merge tag 'drm-misc-next-fixes-2018-04-11' of git://anongit.freedesktop.org/drm/drm-misc into drm-next
      
      omap: Fix crash on AM4 EVM, and all OMAP2/3 boards (Tomi)
      
      Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
      
      * tag 'drm-misc-next-fixes-2018-04-11' of git://anongit.freedesktop.org/drm/drm-misc:
        drm/omap: fix crash if there's no video PLL
      dece02f7
    • Linus Torvalds's avatar
      Merge tag 'xfs-4.17-merge-4' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux · 80aa76bc
      Linus Torvalds authored
      Pull more xfs updates from Darrick Wong:
       "Most of these are code cleanups, but there are a couple of notable
        use-after-free bug fixes.
      
        This series has been run through a full xfstests run over the week and
        through a quick xfstests run against this morning's master, with no
        major failures reported.
      
         - clean up unnecessary function call parameters
      
         - fix a use-after-free bug when aborting logging intents
      
         - refactor filestreams state data to avoid use-after-free bug
      
         - fix incorrect removal of cow extents when truncating extended
           attributes.
      
         - refactor open-coded __set_page_dirty in favor of using vfs
           function.
      
         - fix a deadlock when fstrim and fs shutdown race"
      
      * tag 'xfs-4.17-merge-4' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
        Force log to disk before reading the AGF during a fstrim
        Export __set_page_dirty
        xfs: only cancel cow blocks when truncating the data fork
        xfs: non-scrub - remove unused function parameters
        xfs: remove filestream item xfs_inode reference
        xfs: fix intent use-after-free on abort
        xfs: Remove "committed" argument of xfs_dir_ialloc
      80aa76bc
    • Linus Torvalds's avatar
      Merge tag 'gfs2-4.17.fixes2' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2 · 4ac1800f
      Linus Torvalds authored
      Pull more gfs2 updates from Bob Peterson:
       "We decided to request the latest three patches to be merged into this
        merge window while it's still open.
      
         - The first patch adds a new function to lockref:
           lockref_put_not_zero
      
         - The second patch fixes GFS2's glock dump code so it uses the new
           lockref function. This fixes a problem whereby lock dumps could
           miss glocks.
      
         - I made a minor patch to update some comments and fix the lock
           ordering text in our gfs2-glocks.txt Documentation file"
      
      * tag 'gfs2-4.17.fixes2' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2:
        GFS2: Minor improvements to comments and documentation
        gfs2: Stop using rhashtable_walk_peek
        lockref: Add lockref_put_not_zero
      4ac1800f
    • Linus Torvalds's avatar
      Merge tag 'nfs-for-4.17-1' of git://git.linux-nfs.org/projects/anna/linux-nfs · a1bf4c7d
      Linus Torvalds authored
      Pull NFS client updates from Anna Schumaker:
       "Stable bugfixes:
         - xprtrdma: Fix corner cases when handling device removal # v4.12+
         - xprtrdma: Fix latency regression on NUMA NFS/RDMA clients # v4.15+
      
        Features:
         - New sunrpc tracepoint for RPC pings
         - Finer grained NFSv4 attribute checking
         - Don't unnecessarily return NFS v4 delegations
      
        Other bugfixes and cleanups:
         - Several other small NFSoRDMA cleanups
         - Improvements to the sunrpc RTT measurements
         - A few sunrpc tracepoint cleanups
         - Various fixes for NFS v4 lock notifications
         - Various sunrpc and NFS v4 XDR encoding cleanups
         - Switch to the ida_simple API
         - Fix NFSv4.1 exclusive create
         - Forget acl cache after setattr operation
         - Don't advance the nfs_entry readdir cookie if xdr decoding fails"
      
      * tag 'nfs-for-4.17-1' of git://git.linux-nfs.org/projects/anna/linux-nfs: (47 commits)
        NFS: advance nfs_entry cookie only after decoding completes successfully
        NFSv3/acl: forget acl cache after setattr
        NFSv4.1: Fix exclusive create
        NFSv4: Declare the size up to date after it was set.
        nfs: Use ida_simple API
        NFSv4: Fix the nfs_inode_set_delegation() arguments
        NFSv4: Clean up CB_GETATTR encoding
        NFSv4: Don't ask for attributes when ACCESS is protected by a delegation
        NFSv4: Add a helper to encode/decode struct timespec
        NFSv4: Clean up encode_attrs
        NFSv4; Clean up XDR encoding of type bitmap4
        NFSv4: Allow GFP_NOIO sleeps in decode_attr_owner/decode_attr_group
        SUNRPC: Add a helper for encoding opaque data inline
        SUNRPC: Add helpers for decoding opaque and string types
        NFSv4: Ignore change attribute invalidations if we hold a delegation
        NFS: More fine grained attribute tracking
        NFS: Don't force unnecessary cache invalidation in nfs_update_inode()
        NFS: Don't redirty the attribute cache in nfs_wcc_update_inode()
        NFS: Don't force a revalidation of all attributes if change is missing
        NFS: Convert NFS_INO_INVALID flags to unsigned long
        ...
      a1bf4c7d
    • Linus Torvalds's avatar
      Merge branch 'work.thaw' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 7214dd4e
      Linus Torvalds authored
      Pull vfs thaw updates from Al Viro:
       "An ancient series that has fallen through the cracks in the previous
        cycle"
      
      * 'work.thaw' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        buffer.c: call thaw_super during emergency thaw
        vfs: factor sb iteration out of do_emergency_remount
      7214dd4e
    • Harry Wentland's avatar
      Revert "drm/amd/display: disable CRTCs with NULL FB on their primary plane (V2)" · 1cb19e82
      Harry Wentland authored
      This seems to cause flickering and lock-ups for a wide range of users.
      Revert until we've found a proper fix for the flickering and lock-ups.
      
      This reverts commit 36cc549d.
      
      Cc: Shirish S <shirish.s@amd.com>
      Cc: Alex Deucher <alexander.deucher@amd.com>
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarMichel Dänzer <michel.daenzer@amd.com>
      Signed-off-by: default avatarHarry Wentland <harry.wentland@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      1cb19e82
    • Linus Torvalds's avatar
      Merge branch 'afs-dh' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 19e8a2f8
      Linus Torvalds authored
      Pull AFS updates from Al Viro:
       "The AFS series posted by dhowells depended upon lookup_one_len()
        rework; now that prereq is in the mainline, that series had been
        rebased on top of it and got some exposure and testing..."
      
      * 'afs-dh' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        afs: Do better accretion of small writes on newly created content
        afs: Add stats for data transfer operations
        afs: Trace protocol errors
        afs: Locally edit directory data for mkdir/create/unlink/...
        afs: Adjust the directory XDR structures
        afs: Split the directory content defs into a header
        afs: Fix directory handling
        afs: Split the dynroot stuff out and give it its own ops tables
        afs: Keep track of invalid-before version for dentry coherency
        afs: Rearrange status mapping
        afs: Make it possible to get the data version in readpage
        afs: Init inode before accessing cache
        afs: Introduce a statistics proc file
        afs: Dump bad status record
        afs: Implement @cell substitution handling
        afs: Implement @sys substitution handling
        afs: Prospectively look up extra files when doing a single lookup
        afs: Don't over-increment the cell usage count when pinning it
        afs: Fix checker warnings
        vfs: Remove the const from dir_context::actor
      19e8a2f8
    • Harry Wentland's avatar
      Revert "drm/amd/display: fix dereferencing possible ERR_PTR()" · 1bc8ffbd
      Harry Wentland authored
      This reverts commit cd2d6c92.
      
      Cc: Shirish S <shirish.s@amd.com>
      Cc: Alex Deucher <alexander.deucher@amd.com>
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarMichel Dänzer <michel.daenzer@amd.com>
      Signed-off-by: default avatarHarry Wentland <harry.wentland@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      1bc8ffbd
    • Leo (Sunpeng) Li's avatar
      drm/amd/display: Fix regamma not affecting full-intensity color values · b2f3f592
      Leo (Sunpeng) Li authored
      Hardware understands the regamma LUT as a piecewise linear function,
      with points spaced exponentially along the range. We previously
      programmed the LUT for range [2^-10, 2^0). This causes (normalized)
      color values of 1 (=2^0) to miss the programmed LUT, and fall onto the
      end region.
      
      For DCE, the end region is extrapolated using a single (base, slope)
      pair, using the max y-value from the last point in the curve as base.
      This presents a problem, since this value affects all three color
      channels. Scaling down the intensity of say - the blue regamma curve -
      will not affect it's end region. This is especially noticiable when
      using RedShift. It scales down the blue and green channels, but leaves
      full-intensity colors unshifted.
      
      Therefore, extend the range to cover [2^-10, 2^1) by programming another
      hardware segment, containing only one point. That way, we won't be
      hitting the end region.
      
      Note that things are a bit different for DCN, since the end region can
      be set per-channel.
      Signed-off-by: default avatarLeo (Sunpeng) Li <sunpeng.li@amd.com>
      Reviewed-by: default avatarKrunoslav Kovac <Krunoslav.Kovac@amd.com>
      Acked-by: default avatarHarry Wentland <harry.wentland@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      b2f3f592
    • Roman Li's avatar
    • Harry Wentland's avatar
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 5d136594
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) In ip_gre tunnel, handle the conflict between TUNNEL_{SEQ,CSUM} and
          GSO/LLTX properly. From Sabrina Dubroca.
      
       2) Stop properly on error in lan78xx_read_otp(), from Phil Elwell.
      
       3) Don't uncompress in slip before rstate is initialized, from Tejaswi
          Tanikella.
      
       4) When using 1.x firmware on aquantia, issue a deinit before we
          hardware reset the chip, otherwise we break dirty wake WOL. From
          Igor Russkikh.
      
       5) Correct log check in vhost_vq_access_ok(), from Stefan Hajnoczi.
      
       6) Fix ethtool -x crashes in bnxt_en, from Michael Chan.
      
       7) Fix races in l2tp tunnel creation and duplicate tunnel detection,
          from Guillaume Nault.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (22 commits)
        l2tp: fix race in duplicate tunnel detection
        l2tp: fix races in tunnel creation
        tun: send netlink notification when the device is modified
        tun: set the flags before registering the netdevice
        lan78xx: Don't reset the interface on open
        bnxt_en: Fix NULL pointer dereference at bnxt_free_irq().
        bnxt_en: Need to include RDMA rings in bnxt_check_rings().
        bnxt_en: Support max-mtu with VF-reps
        bnxt_en: Ignore src port field in decap filter nodes
        bnxt_en: do not allow wildcard matches for L2 flows
        bnxt_en: Fix ethtool -x crash when device is down.
        vhost: return bool from *_access_ok() functions
        vhost: fix vhost_vq_access_ok() log check
        vhost: Fix vhost_copy_to_user()
        net: aquantia: oops when shutdown on already stopped device
        net: aquantia: Regression on reset with 1.x firmware
        cdc_ether: flag the Cinterion AHS8 modem by gemalto as WWAN
        slip: Check if rstate is initialized before uncompressing
        lan78xx: Avoid spurious kevent 4 "error"
        lan78xx: Correctly indicate invalid OTP
        ...
      5d136594
    • Linus Torvalds's avatar
      Merge tag 'for-linus-4.17-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · 67a7a8ff
      Linus Torvalds authored
      Pull xen fixes from Juergen Gross:
       "A few fixes of Xen related core code and drivers"
      
      * tag 'for-linus-4.17-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        xen/pvh: Indicate XENFEAT_linux_rsdp_unrestricted to Xen
        xen/acpi: off by one in read_acpi_id()
        xen/acpi: upload _PSD info for non Dom0 CPUs too
        x86/xen: Delay get_cpu_cap until stack canary is established
        xen: xenbus_dev_frontend: Verify body of XS_TRANSACTION_END
        xen: xenbus: Catch closing of non existent transactions
        xen: xenbus_dev_frontend: Fix XS_TRANSACTION_END handling
      67a7a8ff
    • Linus Torvalds's avatar
      Merge tag 'dma-mapping-4.17-2' of git://git.infradead.org/users/hch/dma-mapping · c5c177c5
      Linus Torvalds authored
      Pull dma-mapping fix from Christoph Hellwig:
       "Fix for one swiotlb regression in 2.16 from Takashi"
      
      * tag 'dma-mapping-4.17-2' of git://git.infradead.org/users/hch/dma-mapping:
        swiotlb: fix unexpected swiotlb_alloc_coherent failures
      c5c177c5
    • Linus Torvalds's avatar
      Merge tag 'mmc-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc · d1cb7718
      Linus Torvalds authored
      Pull MMC fixes from Ulf Hansson:
       "MMC core:
         - Prevent bus reference leak in mmc_blk_init()
      
        MMC host:
         - tmio: Fix error handling when issuing CMD23
         - jz4740: Fix race condition in IRQ mask update"
      
      * tag 'mmc-v4.17-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc:
        mmc: tmio: Fix error handling when issuing CMD23
        mmc: core: Prevent bus reference leak in mmc_blk_init()
        mmc: jz4740: Fix race condition in IRQ mask update
      d1cb7718
    • Linus Torvalds's avatar
      Merge tag 'for_linus-4.16' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb · cb098d50
      Linus Torvalds authored
      Pull kdb updates from Jason Wessel:
      
       - fix 2032 time access issues and new compiler warnings
      
       - minor regression test cleanup
      
       - formatting fixes for end user use of kdb
      
      * tag 'for_linus-4.16' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb:
        kdb: use memmove instead of overlapping memcpy
        kdb: use ktime_get_mono_fast_ns() instead of ktime_get_ts()
        kdb: bl: don't use tab character in output
        kdb: drop newline in unknown command output
        kdb: make "mdr" command repeat
        kdb: use __ktime_get_real_seconds instead of __current_kernel_time
        misc: kgdbts: Display progress of asynchronous tests
      cb098d50
    • Linus Torvalds's avatar
      Merge tag 'microblaze-4.17-rc1' of git://git.monstr.eu/linux-2.6-microblaze · 07820c3b
      Linus Torvalds authored
      Pull microblaze updates from Michal Simek:
       "Use generic pci_mmap_resource_range()"
      
      * tag 'microblaze-4.17-rc1' of git://git.monstr.eu/linux-2.6-microblaze:
        microblaze: Use generic pci_mmap_resource_range()
        microblaze: Provide pgprot_device/writecombine macros for nommu
      07820c3b