1. 20 Sep, 2015 3 commits
    • Linus Torvalds's avatar
      Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm · 2673ee56
      Linus Torvalds authored
      Pull libnvdimm fixes from Dan Williams:
      
       - a boot regression (since v4.2) fix for some ARM configurations from
         Tyler
      
       - regression (since v4.1) fixes for mkfs.xfs on a DAX enabled device
         from Jeff.  These are tagged for -stable.
      
       - a pair of locking fixes from Axel that are hidden from lockdep since
         they involve device_lock().  The "btt" one is tagged for -stable, the
         other only applies to the new "pfn" mechanism in v4.3.
      
       - a fix for the pmem ->rw_page() path to use wmb_pmem() from Ross.
      
      * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
        mm: fix type cast in __pfn_to_phys()
        pmem: add proper fencing to pmem_rw_page()
        libnvdimm: pfn_devs: Fix locking in namespace_store
        libnvdimm: btt_devs: Fix locking in namespace_store
        blockdev: don't set S_DAX for misaligned partitions
        dax: fix O_DIRECT I/O to the last block of a blockdev
      2673ee56
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.dk/linux-block · 133bb595
      Linus Torvalds authored
      Pull block updates from Jens Axboe:
       "This is a bit bigger than it should be, but I could (did) not want to
        send it off last week due to both wanting extra testing, and expecting
        a fix for the bounce regression as well.  In any case, this contains:
      
         - Fix for the blk-merge.c compilation warning on gcc 5.x from me.
      
         - A set of back/front SG gap merge fixes, from me and from Sagi.
           This ensures that we honor SG gapping for integrity payloads as
           well.
      
         - Two small fixes for null_blk from Matias, fixing a leak and a
           capacity propagation issue.
      
         - A blkcg fix from Tejun, fixing a NULL dereference.
      
         - A fast clone optimization from Ming, fixing a performance
           regression since the arbitrarily sized bio's were introduced.
      
         - Also from Ming, a regression fix for bouncing IOs"
      
      * 'for-linus' of git://git.kernel.dk/linux-block:
        block: fix bounce_end_io
        block: blk-merge: fast-clone bio when splitting rw bios
        block: blkg_destroy_all() should clear q->root_blkg and ->root_rl.blkg
        block: Copy a user iovec if it includes gaps
        block: Refuse adding appending a gapped integrity page to a bio
        block: Refuse request/bio merges with gaps in the integrity payload
        block: Check for gaps on front and back merges
        null_blk: fix wrong capacity when bs is not 512 bytes
        null_blk: fix memory leak on cleanup
        block: fix bogus compiler warnings in blk-merge.c
      133bb595
    • Chris Mason's avatar
      fs-writeback: unplug before cond_resched in writeback_sb_inodes · 590dca3a
      Chris Mason authored
      Commit 505a666e ("writeback: plug writeback in wb_writeback() and
      writeback_inodes_wb()") has us holding a plug during writeback_sb_inodes,
      which increases the merge rate when relatively contiguous small files
      are written by the filesystem.  It helps both on flash and spindles.
      
      For an fs_mark workload creating 4K files in parallel across 8 drives,
      this commit improves performance ~9% more by unplugging before calling
      cond_resched().  cond_resched() doesn't trigger an implicit unplug, so
      explicitly getting the IO down to the device before scheduling reduces
      latencies for anyone waiting on clean pages.
      
      It also cuts down on how often we use kblockd to unplug, which means
      less work bouncing from one workqueue to another.
      
      Many more details about how we got here:
      
        https://lkml.org/lkml/2015/9/11/570Signed-off-by: default avatarChris Mason <clm@fb.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      590dca3a
  2. 19 Sep, 2015 1 commit
  3. 18 Sep, 2015 17 commits
    • Linus Torvalds's avatar
      Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost · 00ade1f5
      Linus Torvalds authored
      Pull virtio fixes and cleanups from Michael Tsirkin:
       "This fixes the virtio-test tool, and improves the error handling for
        virtio-ccw"
      
      * tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
        virtio/s390: handle failures of READ_VQ_CONF ccw
        tools/virtio: propagate V=X to kernel build
        vhost: move features to core
        tools/virtio: fix build after 4.2 changes
      00ade1f5
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · 3ae83945
      Linus Torvalds authored
      Pull KVM fixes from Paolo Bonzini:
       "Mostly stable material, a lot of ARM fixes"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (22 commits)
        sched: access local runqueue directly in single_task_running
        arm/arm64: KVM: Remove 'config KVM_ARM_MAX_VCPUS'
        arm64: KVM: Remove all traces of the ThumbEE registers
        arm: KVM: Disable virtual timer even if the guest is not using it
        arm64: KVM: Disable virtual timer even if the guest is not using it
        arm/arm64: KVM: vgic: Check for !irqchip_in_kernel() when mapping resources
        KVM: s390: Replace incorrect atomic_or with atomic_andnot
        arm: KVM: Fix incorrect device to IPA mapping
        arm64: KVM: Fix user access for debug registers
        KVM: vmx: fix VPID is 0000H in non-root operation
        KVM: add halt_attempted_poll to VCPU stats
        kvm: fix zero length mmio searching
        kvm: fix double free for fast mmio eventfd
        kvm: factor out core eventfd assign/deassign logic
        kvm: don't try to register to KVM_FAST_MMIO_BUS for non mmio eventfd
        KVM: make the declaration of functions within 80 characters
        KVM: arm64: add workaround for Cortex-A57 erratum #852523
        KVM: fix polling for guest halt continued even if disable it
        arm/arm64: KVM: Fix PSCI affinity info return value for non valid cores
        arm64: KVM: set {v,}TCR_EL2 RES1 bits
        ...
      3ae83945
    • Linus Torvalds's avatar
      Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · fadb97b0
      Linus Torvalds authored
      Pull irq updates from Thomas Gleixner:
       "This is a rather large update post rc1 due to the final steps of
        cleanups and API changes which had to wait for the preparatory patches
        to hit your tree.
      
         - Regression fixes for ARM GIC irqchips
      
         - Regression fixes and lockdep anotations for renesas irq chips
      
         - The leftovers of the cleanup and preparatory patches which have
           been ignored by maintainers
      
         - Final conversions of the newly merged users of obsolete APIs
      
         - Final removal of obsolete APIs
      
         - Final removal of ARM artifacts which had been introduced during the
           conversion of ARM to the generic interrupt code.
      
         - Final split of the irq_data into chip specific and common data to
           reflect the needs of hierarchical irq domains.
      
         - Treewide removal of the first argument of interrupt flow handlers,
           i.e. the irq number, which is not used by the majority of handlers
           and simple to retrieve from the other argument the irq descriptor.
      
         - A few comment updates and build warning fixes"
      
      * 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (40 commits)
        arm64: Remove ununsed set_irq_flags
        ARM: Remove ununsed set_irq_flags
        sh: Kill off set_irq_flags usage
        irqchip: Kill off set_irq_flags usage
        gpu/drm: Kill off set_irq_flags usage
        genirq: Remove irq argument from irq flow handlers
        genirq: Move field 'msi_desc' from irq_data into irq_common_data
        genirq: Move field 'affinity' from irq_data into irq_common_data
        genirq: Move field 'handler_data' from irq_data into irq_common_data
        genirq: Move field 'node' from irq_data into irq_common_data
        irqchip/gic-v3: Use IRQD_FORWARDED_TO_VCPU flag
        irqchip/gic: Use IRQD_FORWARDED_TO_VCPU flag
        genirq: Provide IRQD_FORWARDED_TO_VCPU status flag
        genirq: Simplify irq_data_to_desc()
        genirq: Remove __irq_set_handler_locked()
        pinctrl/pistachio: Use irq_set_handler_locked
        gpio: vf610: Use irq_set_handler_locked
        powerpc/mpc8xx: Use irq_set_handler_locked()
        powerpc/ipic: Use irq_set_handler_locked()
        powerpc/cpm2: Use irq_set_handler_locked()
        ...
      fadb97b0
    • Linus Torvalds's avatar
      Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 09784fb8
      Linus Torvalds authored
      Pull x86 fix from Thomas Gleixner:
       "A single regression fix for the x86 dma allocator which got wreckaged
        in the merge window"
      
      * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/pci/dma: Fix gfp flags for coherent DMA memory allocation
      09784fb8
    • Linus Torvalds's avatar
      Merge tag 'powerpc-4.3-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · f240bdd2
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
      
       - Fix 32-bit TCE table init in kdump kernel from Nish
      
       - Fix kdump with non-power-of-2 crashkernel= from Nish
      
       - Abort cxl_pci_enable_device_hook() if PCI channel is offline from
         Andrew
      
       - Fix to release DRC when configure_connector() fails from Bharata
      
       - Wire up sys_userfaultfd()
      
       - Fix race condition in tearing down MSI interrupts from Paul
      
       - Fix unbalanced pci_dev_get() in cxl_probe() from Daniel
      
       - Fix cxl build failure due to -Wunused-variable gcc behaviour change
         from Ian
      
       - Tell the toolchain to use ABI v2 when building an LE boot wrapper
         from Benh
      
       - Fix THP to recompute hash value after a failed update from Aneesh
      
       - 32-bit memcpy/memset: only use dcbz once cache is enabled from
         Christophe
      
      * tag 'powerpc-4.3-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc32: memset: only use dcbz once cache is enabled
        powerpc32: memcpy: only use dcbz once cache is enabled
        powerpc/mm: Recompute hash value after a failed update
        powerpc/boot: Specify ABI v2 when building an LE boot wrapper
        cxl: Fix build failure due to -Wunused-variable behaviour change
        cxl: Fix unbalanced pci_dev_get in cxl_probe
        powerpc/MSI: Fix race condition in tearing down MSI interrupts
        powerpc: Wire up sys_userfaultfd()
        powerpc/pseries: Release DRC when configure_connector fails
        cxl: abort cxl_pci_enable_device_hook() if PCI channel is offline
        powerpc/powernv/pci-ioda: fix kdump with non-power-of-2 crashkernel=
        powerpc/powernv/pci-ioda: fix 32-bit TCE table init in kdump kernel
      f240bdd2
    • Dominik Dingel's avatar
      sched: access local runqueue directly in single_task_running · 00cc1633
      Dominik Dingel authored
      Commit 2ee507c4 ("sched: Add function single_task_running to let a task
      check if it is the only task running on a cpu") referenced the current
      runqueue with the smp_processor_id.  When CONFIG_DEBUG_PREEMPT is enabled,
      that is only allowed if preemption is disabled or the currrent task is
      bound to the local cpu (e.g. kernel worker).
      
      With commit f7819512 ("kvm: add halt_poll_ns module parameter") KVM
      calls single_task_running. If CONFIG_DEBUG_PREEMPT is enabled that
      generates a lot of kernel messages.
      
      To avoid adding preemption in that cases, as it would limit the usefulness,
      we change single_task_running to access directly the cpu local runqueue.
      
      Cc: Tim Chen <tim.c.chen@linux.intel.com>
      Suggested-by: default avatarPeter Zijlstra <peterz@infradead.org>
      Acked-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
      Cc: <stable@vger.kernel.org>
      Fixes: 2ee507c4Signed-off-by: default avatarDominik Dingel <dingel@linux.vnet.ibm.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      00cc1633
    • Linus Torvalds's avatar
      Merge tag 'platform-drivers-x86-v4.3-2' of... · a7d5c189
      Linus Torvalds authored
      Merge tag 'platform-drivers-x86-v4.3-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86
      
      Pull x86 platform driver fixes from Darren Hart:
       "Fix an issue introduced by the previous major toshiba rework.  Add a
        quirk.  Workaround a few platform specific firmware items.  One
        cleanup to wmi I inadvertently dropped from a previous pull request.
      
        Details:
      
        hp-wmi:
         - limit hotkey enable
      
        toshiba_acpi:
         - Fix hotkeys registration on some toshiba models
         - Fix USB Sleep and Music always disabled
      
        wmi:
         - Remove private %pUL implementation
      
        asus-nb-wmi:
         - Add wapf=4 quirk for X456UA/X456UF"
      
      * tag 'platform-drivers-x86-v4.3-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86:
        hp-wmi: limit hotkey enable
        toshiba_acpi: Fix hotkeys registration on some toshiba models
        toshiba_acpi: Fix USB Sleep and Music always disabled
        wmi: Remove private %pUL implementation
        asus-nb-wmi: Add wapf=4 quirk for X456UA/X456UF
      a7d5c189
    • Linus Torvalds's avatar
      Merge branch 'akpm' (patches from Andrew) · a8f15585
      Linus Torvalds authored
      Merge misc fixes from ANdrew Morton:
       "8 fixes"
      
      * emailed patches from Andrew Morton <akpm@linux-foundation.org>:
        revert "mm: make sure all file VMAs have ->vm_ops set"
        MAINTAINERS: update LTP mailing list
        userfaultfd: add missing mmput() in error path
        lib/string_helpers.c: fix infinite loop in string_get_size()
        alpha: lib: export __delay
        alpha: io: define ioremap_uc
        kasan: fix last shadow judgement in memory_is_poisoned_16()
        zram: fix possible use after free in zcomp_create()
      a8f15585
    • Andrew Morton's avatar
      revert "mm: make sure all file VMAs have ->vm_ops set" · 28c553d0
      Andrew Morton authored
      Revert commit 6dc296e7 "mm: make sure all file VMAs have ->vm_ops
      set".
      
      Will Deacon reports that it "causes some mmap regressions in LTP, which
      appears to use a MAP_PRIVATE mmap of /dev/zero as a way to get anonymous
      pages in some of its tests (specifically mmap10 [1])".
      
      William Shuman reports Oracle crashes.
      
      So revert the patch while we work out what to do.
      Reported-by: default avatarWilliam Shuman <wshuman3@gmail.com>
      Reported-by: default avatarWill Deacon <will.deacon@arm.com>
      Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Cc: Oleg Nesterov <oleg@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      28c553d0
    • Cyril Hrubis's avatar
      MAINTAINERS: update LTP mailing list · 0526109a
      Cyril Hrubis authored
      [akpm@linux-foundation.org: Wanlong Gao has moved]
      Signed-off-by: default avatarCyril Hrubis <chrubis@suse.cz>
      Cc: Jan Stancek <jstancek@redhat.com>
      Cc: Stanislav Kholmanskikh <stanislav.kholmanskikh@oracle.com>
      Cc: Alexey Kodanev <alexey.kodanev@oracle.com>
      Cc: Wanlong Gao <wanlong.gao@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      0526109a
    • Eric Biggers's avatar
      userfaultfd: add missing mmput() in error path · c03e946f
      Eric Biggers authored
      This fixes a memleak if anon_inode_getfile() fails in userfaultfd().
      Signed-off-by: default avatarEric Biggers <ebiggers3@gmail.com>
      Signed-off-by: default avatarAndrea Arcangeli <aarcange@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      c03e946f
    • Vitaly Kuznetsov's avatar
      lib/string_helpers.c: fix infinite loop in string_get_size() · 62bef58a
      Vitaly Kuznetsov authored
      Some string_get_size() calls (e.g.:
       string_get_size(1, 512, STRING_UNITS_10, ..., ...)
       string_get_size(15, 64, STRING_UNITS_10, ..., ...)
      ) result in an infinite loop. The problem is that if size is equal to
      divisor[units]/blk_size and is smaller than divisor[units] we'll end
      up with size == 0 when we start doing sf_cap calculations:
      
      For string_get_size(1, 512, STRING_UNITS_10, ..., ...) case:
         ...
         remainder = do_div(size, divisor[units]); -> size is 0, remainder is 1
         remainder *= blk_size; -> remainder is 512
         ...
         size *= blk_size; -> size is still 0
         size += remainder / divisor[units]; -> size is still 0
      
      The caller causing the issue is sd_read_capacity(), the problem was
      noticed on Hyper-V, such weird size was reported by host when scanning
      collides with device removal.  This is probably a separate issue worth
      fixing, this patch is intended to prevent the library routine from
      infinite looping.
      Signed-off-by: default avatarVitaly Kuznetsov <vkuznets@redhat.com>
      Acked-by: default avatarJames Bottomley <JBottomley@Odin.com>
      Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
      Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk>
      Cc: "K. Y. Srinivasan" <kys@microsoft.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      62bef58a
    • Sudip Mukherjee's avatar
      alpha: lib: export __delay · 14b97ded
      Sudip Mukherjee authored
      __delay was not exported as a result while building with allmodconfig we
      were getting build error of undefined symbol.  __delay is being used by:
      drivers/net/phy/mdio-octeon.c
      Signed-off-by: default avatarSudip Mukherjee <sudip@vectorindia.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Matt Turner <mattst88@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      14b97ded
    • Sudip Mukherjee's avatar
      alpha: io: define ioremap_uc · 969560d2
      Sudip Mukherjee authored
      ioremap_uc was not defined and as a result while building with
      allmodconfig were getting build error of: implicit declaration of
      function 'ioremap_uc'.
      Signed-off-by: default avatarSudip Mukherjee <sudip@vectorindia.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Matt Turner <mattst88@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      969560d2
    • Xishi Qiu's avatar
      kasan: fix last shadow judgement in memory_is_poisoned_16() · 8d77a6d1
      Xishi Qiu authored
      The shadow which correspond 16 bytes memory may span 2 or 3 bytes.  If
      the memory is aligned on 8, then the shadow takes only 2 bytes.  So we
      check "shadow_first_bytes" is enough, and need not to call
      "memory_is_poisoned_1(addr + 15);".  But the code "if
      (likely(!last_byte))" is wrong judgement.
      
      e.g.  addr=0, so last_byte = 15 & KASAN_SHADOW_MASK = 7, then the code
      will continue to call "memory_is_poisoned_1(addr + 15);"
      Signed-off-by: default avatarXishi Qiu <qiuxishi@huawei.com>
      Acked-by: default avatarAndrey Ryabinin <aryabinin@virtuozzo.com>
      Cc: Andrey Konovalov <adech.fo@gmail.com>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Michal Marek <mmarek@suse.cz>
      Cc: <zhongjiang@huawei.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      8d77a6d1
    • Luis Henriques's avatar
      zram: fix possible use after free in zcomp_create() · 3aaf14da
      Luis Henriques authored
      zcomp_create() verifies the success of zcomp_strm_{multi,single}_create()
      through comp->stream, which can potentially be pointing to memory that
      was freed if these functions returned an error.
      
      While at it, replace a 'ERR_PTR(-ENOMEM)' by a more generic
      'ERR_PTR(error)' as in the future zcomp_strm_{multi,siggle}_create()
      could return other error codes.  Function documentation updated
      accordingly.
      
      Fixes: beca3ec7 ("zram: add multi stream functionality")
      Signed-off-by: default avatarLuis Henriques <luis.henriques@canonical.com>
      Acked-by: default avatarSergey Senozhatsky <sergey.senozhatsky@gmail.com>
      Acked-by: default avatarMinchan Kim <minchan@kernel.org>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      3aaf14da
    • Kyle Evans's avatar
      hp-wmi: limit hotkey enable · 8a1513b4
      Kyle Evans authored
      Do not write initialize magic on systems that do not have
      feature query 0xb. Fixes Bug #82451.
      
      Redefine FEATURE_QUERY to align with 0xb and FEATURE2 with 0xd
      for code clearity.
      
      Add a new test function, hp_wmi_bios_2008_later() & simplify
      hp_wmi_bios_2009_later(), which fixes a bug in cases where
      an improper value is returned. Probably also fixes Bug #69131.
      
      Add missing __init tag.
      Signed-off-by: default avatarKyle Evans <kvans32@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarDarren Hart <dvhart@linux.intel.com>
      8a1513b4
  4. 17 Sep, 2015 19 commits