02 Jan, 2017

1 commit

  • Pull DAX updates from Dan Williams:
    "The completion of Jan's DAX work for 4.10.

    As I mentioned in the libnvdimm-for-4.10 pull request, these are some
    final fixes for the DAX dirty-cacheline-tracking invalidation work
    that was merged through the -mm, ext4, and xfs trees in -rc1. These
    patches were prepared prior to the merge window, but we waited for
    4.10-rc1 to have a stable merge base after all the prerequisites were
    merged.

    Quoting Jan on the overall changes in these patches:

    "So I'd like all these 6 patches to go for rc2. The first three
    patches fix invalidation of exceptional DAX entries (a bug which
    is there for a long time) - without these patches data loss can
    occur on power failure even though user called fsync(2). The other
    three patches change locking of DAX faults so that ->iomap_begin()
    is called in a more relaxed locking context and we are safe to
    start a transaction there for ext4"

    These have received a build success notification from the kbuild
    robot, and pass the latest libnvdimm unit tests. There have not been
    any -next releases since -rc1, so they have not appeared there"

    * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
    ext4: Simplify DAX fault path
    dax: Call ->iomap_begin without entry lock during dax fault
    dax: Finish fault completely when loading holes
    dax: Avoid page invalidation races and unnecessary radix tree traversals
    mm: Invalidate DAX radix tree entries only if appropriate
    ext2: Return BH_New buffers for zeroed blocks

    Linus Torvalds
     

30 Dec, 2016

1 commit

  • In commit 62906027091f ("mm: add PageWaiters indicating tasks are
    waiting for a page bit") Nick Piggin made our page locking no longer
    unconditionally touch the hashed page waitqueue, which not only helps
    performance in general, but is particularly helpful on NUMA machines
    where the hashed wait queues can bounce around a lot.

    However, the "clear lock bit atomically and then test the waiters bit"
    sequence turns out to be much more expensive than it needs to be,
    because you get a nasty stall when trying to access the same word that
    just got updated atomically.

    On architectures where locking is done with LL/SC, this would be trivial
    to fix with a new primitive that clears one bit and tests another
    atomically, but that ends up not working on x86, where the only atomic
    operations that return the result end up being cmpxchg and xadd. The
    atomic bit operations return the old value of the same bit we changed,
    not the value of an unrelated bit.

    On x86, we could put the lock bit in the high bit of the byte, and use
    "xadd" with that bit (where the overflow ends up not touching other
    bits), and look at the other bits of the result. However, an even
    simpler model is to just use a regular atomic "and" to clear the lock
    bit, and then the sign bit in eflags will indicate the resulting state
    of the unrelated bit #7.

    So by moving the PageWaiters bit up to bit #7, we can atomically clear
    the lock bit and test the waiters bit on x86 too. And architectures
    with LL/SC (which is all the usual RISC suspects), the particular bit
    doesn't matter, so they are fine with this approach too.

    This avoids the extra access to the same atomic word, and thus avoids
    the costly stall at page unlock time.

    The only downside is that the interface ends up being a bit odd and
    specialized: clear a bit in a byte, and test the sign bit. Nick doesn't
    love the resulting name of the new primitive, but I'd rather make the
    name be descriptive and very clear about the limitation imposed by
    trying to work across all relevant architectures than make it be some
    generic thing that doesn't make the odd semantics explicit.

    So this introduces the new architecture primitive

    clear_bit_unlock_is_negative_byte();

    and adds the trivial implementation for x86. We have a generic
    non-optimized fallback (that just does a "clear_bit()"+"test_bit(7)"
    combination) which can be overridden by any architecture that can do
    better. According to Nick, Power has the same hickup x86 has, for
    example, but some other architectures may not even care.

    All these optimizations mean that my page locking stress-test (which is
    just executing a lot of small short-lived shell scripts: "make test" in
    the git source tree) no longer makes our page locking look horribly bad.
    Before all these optimizations, just the unlock_page() costs were just
    over 3% of all CPU overhead on "make test". After this, it's down to
    0.66%, so just a quarter of the cost it used to be.

    (The difference on NUMA is bigger, but there this micro-optimization is
    likely less noticeable, since the big issue on NUMA was not the accesses
    to 'struct page', but the waitqueue accesses that were already removed
    by Nick's earlier commit).

    Acked-by: Nick Piggin
    Cc: Dave Hansen
    Cc: Bob Peterson
    Cc: Steven Whitehouse
    Cc: Andrew Lutomirski
    Cc: Andreas Gruenbacher
    Cc: Peter Zijlstra
    Cc: Mel Gorman
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

28 Dec, 2016

2 commits

  • Pull networking fixes from David Miller:

    1) Various ipvlan fixes from Eric Dumazet and Mahesh Bandewar.

    The most important is to not assume the packet is RX just because
    the destination address matches that of the device. Such an
    assumption causes problems when an interface is put into loopback
    mode.

    2) If we retry when creating a new tc entry (because we dropped the
    RTNL mutex in order to load a module, for example) we end up with
    -EAGAIN and then loop trying to replay the request. But we didn't
    reset some state when looping back to the top like this, and if
    another thread meanwhile inserted the same tc entry we were trying
    to, we re-link it creating an enless loop in the tc chain. Fix from
    Daniel Borkmann.

    3) There are two different WRITE bits in the MDIO address register for
    the stmmac chip, depending upon the chip variant. Due to a bug we
    could set them both, fix from Hock Leong Kweh.

    4) Fix mlx4 bug in XDP_TX handling, from Tariq Toukan.

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
    net: stmmac: fix incorrect bit set in gmac4 mdio addr register
    r8169: add support for RTL8168 series add-on card.
    net: xdp: remove unused bfp_warn_invalid_xdp_buffer()
    openvswitch: upcall: Fix vlan handling.
    ipv4: Namespaceify tcp_tw_reuse knob
    net: korina: Fix NAPI versus resources freeing
    net, sched: fix soft lockup in tc_classify
    net/mlx4_en: Fix user prio field in XDP forward
    tipc: don't send FIN message from connectionless socket
    ipvlan: fix multicast processing
    ipvlan: fix various issues in ipvlan_process_multicast()

    Linus Torvalds
     
  • After commit 73b62bd085f4737679ea9afc7867fa5f99ba7d1b ("virtio-net:
    remove the warning before XDP linearizing"), there's no users for
    bpf_warn_invalid_xdp_buffer(), so remove it. This is a revert for
    commit f23bc46c30ca5ef58b8549434899fcbac41b2cfc.

    Cc: Daniel Borkmann
    Cc: John Fastabend
    Signed-off-by: Jason Wang
    Acked-by: Daniel Borkmann
    Signed-off-by: David S. Miller

    Jason Wang
     

27 Dec, 2016

1 commit

  • Currently invalidate_inode_pages2_range() and invalidate_mapping_pages()
    just delete all exceptional radix tree entries they find. For DAX this
    is not desirable as we track cache dirtiness in these entries and when
    they are evicted, we may not flush caches although it is necessary. This
    can for example manifest when we write to the same block both via mmap
    and via write(2) (to different offsets) and fsync(2) then does not
    properly flush CPU caches when modification via write(2) was the last
    one.

    Create appropriate DAX functions to handle invalidation of DAX entries
    for invalidate_inode_pages2_range() and invalidate_mapping_pages() and
    wire them up into the corresponding mm functions.

    Acked-by: Johannes Weiner
    Reviewed-by: Ross Zwisler
    Signed-off-by: Jan Kara
    Signed-off-by: Dan Williams

    Jan Kara
     

26 Dec, 2016

7 commits

  • Pull timer type cleanups from Thomas Gleixner:
    "This series does a tree wide cleanup of types related to
    timers/timekeeping.

    - Get rid of cycles_t and use a plain u64. The type is not really
    helpful and caused more confusion than clarity

    - Get rid of the ktime union. The union has become useless as we use
    the scalar nanoseconds storage unconditionally now. The 32bit
    timespec alike storage got removed due to the Y2038 limitations
    some time ago.

    That leaves the odd union access around for no reason. Clean it up.

    Both changes have been done with coccinelle and a small amount of
    manual mopping up"

    * 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    ktime: Get rid of ktime_equal()
    ktime: Cleanup ktime_set() usage
    ktime: Get rid of the union
    clocksource: Use a plain u64 instead of cycle_t

    Linus Torvalds
     
  • Pull SMP hotplug notifier removal from Thomas Gleixner:
    "This is the final cleanup of the hotplug notifier infrastructure. The
    series has been reintgrated in the last two days because there came a
    new driver using the old infrastructure via the SCSI tree.

    Summary:

    - convert the last leftover drivers utilizing notifiers

    - fixup for a completely broken hotplug user

    - prevent setup of already used states

    - removal of the notifiers

    - treewide cleanup of hotplug state names

    - consolidation of state space

    There is a sphinx based documentation pending, but that needs review
    from the documentation folks"

    * 'smp-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    irqchip/armada-xp: Consolidate hotplug state space
    irqchip/gic: Consolidate hotplug state space
    coresight/etm3/4x: Consolidate hotplug state space
    cpu/hotplug: Cleanup state names
    cpu/hotplug: Remove obsolete cpu hotplug register/unregister functions
    staging/lustre/libcfs: Convert to hotplug state machine
    scsi/bnx2i: Convert to hotplug state machine
    scsi/bnx2fc: Convert to hotplug state machine
    cpu/hotplug: Prevent overwriting of callbacks
    x86/msr: Remove bogus cleanup from the error path
    bus: arm-ccn: Prevent hotplug callback leak
    perf/x86/intel/cstate: Prevent hotplug callback leak
    ARM/imx/mmcd: Fix broken cpu hotplug handling
    scsi: qedi: Convert to hotplug state machine

    Linus Torvalds
     
  • Add a new page flag, PageWaiters, to indicate the page waitqueue has
    tasks waiting. This can be tested rather than testing waitqueue_active
    which requires another cacheline load.

    This bit is always set when the page has tasks on page_waitqueue(page),
    and is set and cleared under the waitqueue lock. It may be set when
    there are no tasks on the waitqueue, which will cause a harmless extra
    wakeup check that will clears the bit.

    The generic bit-waitqueue infrastructure is no longer used for pages.
    Instead, waitqueues are used directly with a custom key type. The
    generic code was not flexible enough to have PageWaiters manipulation
    under the waitqueue lock (which simplifies concurrency).

    This improves the performance of page lock intensive microbenchmarks by
    2-3%.

    Putting two bits in the same word opens the opportunity to remove the
    memory barrier between clearing the lock bit and testing the waiters
    bit, after some work on the arch primitives (e.g., ensuring memory
    operand widths match and cover both bits).

    Signed-off-by: Nicholas Piggin
    Cc: Dave Hansen
    Cc: Bob Peterson
    Cc: Steven Whitehouse
    Cc: Andrew Lutomirski
    Cc: Andreas Gruenbacher
    Cc: Peter Zijlstra
    Cc: Mel Gorman
    Signed-off-by: Linus Torvalds

    Nicholas Piggin
     
  • A page is not added to the swap cache without being swap backed,
    so PageSwapBacked mappings can use PG_owner_priv_1 for PageSwapCache.

    Signed-off-by: Nicholas Piggin
    Acked-by: Hugh Dickins
    Cc: Dave Hansen
    Cc: Bob Peterson
    Cc: Steven Whitehouse
    Cc: Andrew Lutomirski
    Cc: Andreas Gruenbacher
    Cc: Peter Zijlstra
    Cc: Mel Gorman
    Signed-off-by: Linus Torvalds

    Nicholas Piggin
     
  • No point in going through loops and hoops instead of just comparing the
    values.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra

    Thomas Gleixner
     
  • ktime_set(S,N) was required for the timespec storage type and is still
    useful for situations where a Seconds and Nanoseconds part of a time value
    needs to be converted. For anything where the Seconds argument is 0, this
    is pointless and can be replaced with a simple assignment.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra

    Thomas Gleixner
     
  • ktime is a union because the initial implementation stored the time in
    scalar nanoseconds on 64 bit machine and in a endianess optimized timespec
    variant for 32bit machines. The Y2038 cleanup removed the timespec variant
    and switched everything to scalar nanoseconds. The union remained, but
    become completely pointless.

    Get rid of the union and just keep ktime_t as simple typedef of type s64.

    The conversion was done with coccinelle and some manual mopping up.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra

    Thomas Gleixner
     

25 Dec, 2016

10 commits

  • There is no point in having an extra type for extra confusion. u64 is
    unambiguous.

    Conversion was done with the following coccinelle script:

    @rem@
    @@
    -typedef u64 cycle_t;

    @fix@
    typedef cycle_t;
    @@
    -cycle_t
    +u64

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra
    Cc: John Stultz

    Thomas Gleixner
     
  • The mpic is either the main interrupt controller or is cascaded behind a
    GIC. The mpic is single instance and the modes are mutually exclusive, so
    there is no reason to have seperate cpu hotplug states.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra
    Cc: Thomas Petazzoni
    Cc: Sebastian Siewior
    Cc: Marc Zyngier
    Link: http://lkml.kernel.org/r/20161221192112.333161745@linutronix.de
    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • Even if both drivers are compiled in only one instance can run on a given
    system depending on the available GIC version.

    So having seperate hotplug states for them is pointless.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra
    Cc: Marc Zyngier
    Cc: Sebastian Siewior
    Link: http://lkml.kernel.org/r/20161221192112.252416267@linutronix.de
    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • Even if both drivers are compiled in only one instance can run on a given
    system depending on the available tracer cell.

    So having seperate hotplug states for them is pointless.

    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra
    Cc: Sebastian Siewior
    Cc: Mathieu Poirier
    Link: http://lkml.kernel.org/r/20161221192112.162765484@linutronix.de
    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • hotcpu_notifier(), cpu_notifier(), __hotcpu_notifier(), __cpu_notifier(),
    register_hotcpu_notifier(), register_cpu_notifier(),
    __register_hotcpu_notifier(), __register_cpu_notifier(),
    unregister_hotcpu_notifier(), unregister_cpu_notifier(),
    __unregister_hotcpu_notifier(), __unregister_cpu_notifier()

    are unused now. Remove them and all related code.

    Remove also the now pointless cpu notifier error injection mechanism. The
    states can be executed step by step and error rollback is the same as cpu
    down, so any state transition can be tested w/o requiring the notifier
    error injection.

    Some CPU hotplug states are kept as they are (ab)used for hotplug state
    tracking.

    Signed-off-by: Sebastian Andrzej Siewior
    Signed-off-by: Thomas Gleixner
    Cc: Peter Zijlstra
    Cc: rt@linutronix.de
    Link: http://lkml.kernel.org/r/20161221192112.005642358@linutronix.de
    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • Install the callbacks via the state machine. No functional change.

    Signed-off-by: Anna-Maria Gleixner
    Signed-off-by: Sebastian Andrzej Siewior
    Cc: devel@driverdev.osuosl.org
    Cc: Andreas Dilger
    Cc: Peter Zijlstra
    Cc: Greg Kroah-Hartman
    Cc: Oleg Drokin
    Cc: rt@linutronix.de
    Cc: lustre-devel@lists.lustre.org
    Link: http://lkml.kernel.org/r/20161202110027.htzzeervzkoc4muv@linutronix.de
    Link: http://lkml.kernel.org/r/20161221192111.922872524@linutronix.de
    Signed-off-by: Thomas Gleixner

    Anna-Maria Gleixner
     
  • Install the callbacks via the state machine. No functional change.

    This is the minimal fixup so we can remove the hotplug notifier mess
    completely.

    The real rework of this driver to use work queues is still stuck in
    review/testing on the SCSI mailing list.

    Signed-off-by: Sebastian Andrzej Siewior
    Cc: "James E.J. Bottomley"
    Cc: linux-scsi@vger.kernel.org
    Cc: "Martin K. Petersen"
    Cc: Peter Zijlstra
    Cc: Chad Dupuis
    Cc: QLogic-Storage-Upstream@qlogic.com
    Cc: Johannes Thumshirn
    Cc: Christoph Hellwig
    Link: http://lkml.kernel.org/r/20161221192111.836895753@linutronix.de
    Signed-off-by: Thomas Gleixner

    Sebastian Andrzej Siewior
     
  • Install the callbacks via the state machine. No functional change.

    This is the minimal fixup so we can remove the hotplug notifier mess
    completely.

    The real rework of this driver to use work queues is still stuck in
    review/testing on the SCSI mailing list.

    Signed-off-by: Sebastian Andrzej Siewior
    Cc: "James E.J. Bottomley"
    Cc: linux-scsi@vger.kernel.org
    Cc: "Martin K. Petersen"
    Cc: Peter Zijlstra
    Cc: Chad Dupuis
    Cc: QLogic-Storage-Upstream@qlogic.com
    Cc: Johannes Thumshirn
    Cc: Christoph Hellwig
    Link: http://lkml.kernel.org/r/20161221192111.757309869@linutronix.de
    Signed-off-by: Thomas Gleixner

    Sebastian Andrzej Siewior
     
  • This was entirely automated, using the script by Al:

    PATT='^[[:blank:]]*#[[:blank:]]*include[[:blank:]]*'
    sed -i -e "s!$PATT!#include !" \
    $(git grep -l "$PATT"|grep -v ^include/linux/uaccess.h)

    to do the replacement at the end of the merge window.

    Requested-by: Al Viro
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • Pull NTB update from Jon Mason:

    - NTB bug fixes for removing an unnecessary call to ntb_peer_spad_read,
    and correcting a free_irq inconsistency

    - add Intel SKX support

    - change the AMD NTB maintainer, and fix some bugs present there

    * tag 'ntb-4.10' of git://github.com/jonmason/ntb:
    ntb_transport: Remove unnecessary call to ntb_peer_spad_read
    NTB: Fix 'request_irq()' and 'free_irq()' inconsistancy
    ntb: fix SKX NTB config space size register offsets
    NTB: correct ntb_peer_spad_read for case when callback is not supplied.
    MAINTAINERS: Change in maintainer for AMD NTB
    ntb_transport: Limit memory windows based on available, scratchpads
    NTB: Register and offset values fix for memory window
    NTB: add support for hotplug feature
    ntb: Adding Skylake Xeon NTB support

    Linus Torvalds
     

24 Dec, 2016

2 commits

  • Correct ntb_peer_spad_read for case when callback is not supplied

    Signed-off-by: Steve Wahl
    Acked-by: Allen Hubbe
    Signed-off-by: Jon Mason

    Steven Wahl
     
  • Pull final vfs updates from Al Viro:
    "Assorted cleanups and fixes all over the place"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
    sg_write()/bsg_write() is not fit to be called under KERNEL_DS
    ufs: fix function declaration for ufs_truncate_blocks
    fs: exec: apply CLOEXEC before changing dumpable task flags
    seq_file: reset iterator to first record for zero offset
    vfs: fix isize/pos/len checks for reflink & dedupe
    [iov_iter] fix iterate_all_kinds() on empty iterators
    move aio compat to fs/aio.c
    reorganize do_make_slave()
    clone_private_mount() doesn't need to touch namespace_sem
    remove a bogus claim about namespace_sem being held by callers of mnt_alloc_id()

    Linus Torvalds
     

23 Dec, 2016

3 commits

  • ... and fix the minor buglet in compat io_submit() - native one
    kills ioctx as cleanup when put_user() fails. Get rid of
    bogus compat_... in !CONFIG_AIO case, while we are at it - they
    should simply fail with ENOSYS, same as for native counterparts.

    Signed-off-by: Al Viro

    Al Viro
     
  • Pull block layer fixes from Jens Axboe:
    "Just a set of small fixes that have either been queued up after the
    original pull for this merge window, or just missed the original pull
    request.

    - a few bcache fixes/changes from Eric and Kent

    - add WRITE_SAME to the command filter whitelist frm Mauricio

    - kill an unused struct member from Ritesh

    - partition IO alignment fix from Stefan

    - nvme sysfs printf fix from Stephen"

    * 'for-linus' of git://git.kernel.dk/linux-block:
    block: check partition alignment
    nvme : Use correct scnprintf in cmb show
    block: allow WRITE_SAME commands with the SG_IO ioctl
    block: Remove unused member (busy) from struct blk_queue_tag
    bcache: partition support: add 16 minors per bcacheN device
    bcache: Make gc wakeup sane, remove set_task_state()

    Linus Torvalds
     
  • Pull x86 cache allocation interface from Thomas Gleixner:
    "This provides support for Intel's Cache Allocation Technology, a cache
    partitioning mechanism.

    The interface is odd, but the hardware interface of that CAT stuff is
    odd as well.

    We tried hard to come up with an abstraction, but that only allows
    rather simple partitioning, but no way of sharing and dealing with the
    per package nature of this mechanism.

    In the end we decided to expose the allocation bitmaps directly so all
    combinations of the hardware can be utilized.

    There are two ways of associating a cache partition:

    - Task

    A task can be added to a resource group. It uses the cache
    partition associated to the group.

    - CPU

    All tasks which are not member of a resource group use the group to
    which the CPU they are running on is associated with.

    That allows for simple CPU based partitioning schemes.

    The main expected user sare:

    - Virtualization so a VM can only trash only the associated part of
    the cash w/o disturbing others

    - Real-Time systems to seperate RT and general workloads.

    - Latency sensitive enterprise workloads

    - In theory this also can be used to protect against cache side
    channel attacks"

    [ Intel RDT is "Resource Director Technology". The interface really is
    rather odd and very specific, which delayed this pull request while I
    was thinking about it. The pull request itself came in early during
    the merge window, I just delayed it until things had calmed down and I
    had more time.

    But people tell me they'll use this, and the good news is that it is
    _so_ specific that it's rather independent of anything else, and no
    user is going to depend on the interface since it's pretty rare. So if
    push comes to shove, we can just remove the interface and nothing will
    break ]

    * 'x86-cache-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (31 commits)
    x86/intel_rdt: Implement show_options() for resctrlfs
    x86/intel_rdt: Call intel_rdt_sched_in() with preemption disabled
    x86/intel_rdt: Update task closid immediately on CPU in rmdir and unmount
    x86/intel_rdt: Fix setting of closid when adding CPUs to a group
    x86/intel_rdt: Update percpu closid immeditately on CPUs affected by changee
    x86/intel_rdt: Reset per cpu closids on unmount
    x86/intel_rdt: Select KERNFS when enabling INTEL_RDT_A
    x86/intel_rdt: Prevent deadlock against hotplug lock
    x86/intel_rdt: Protect info directory from removal
    x86/intel_rdt: Add info files to Documentation
    x86/intel_rdt: Export the minimum number of set mask bits in sysfs
    x86/intel_rdt: Propagate error in rdt_mount() properly
    x86/intel_rdt: Add a missing #include
    MAINTAINERS: Add maintainer for Intel RDT resource allocation
    x86/intel_rdt: Add scheduler hook
    x86/intel_rdt: Add schemata file
    x86/intel_rdt: Add tasks files
    x86/intel_rdt: Add cpus file
    x86/intel_rdt: Add mkdir to resctrl file system
    x86/intel_rdt: Add "info" files to resctrl file system
    ...

    Linus Torvalds
     

22 Dec, 2016

2 commits

  • Pull more NFS client updates from Trond Myklebust:
    "Highlights include:

    - further attribute cache improvements to make revalidation more fine
    grained

    - NFSv4 locking improvements

    Bugfixes:

    - nfs4_fl_prepare_ds must be careful about reporting success in files
    layout

    - pNFS/flexfiles: Instead of marking a device inactive, remove it
    from the cache"

    * tag 'nfs-for-4.10-2' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
    NFSv4: Retry the DELEGRETURN if the embedded GETATTR is rejected with EACCES
    NFS: Retry the CLOSE if the embedded GETATTR is rejected with EACCES
    NFSv4: Place the GETATTR operation before the CLOSE
    NFSv4: Also ask for attributes when downgrading to a READ-only state
    NFS: Don't abuse NFS_INO_REVAL_FORCED in nfs_post_op_update_inode_locked()
    pNFS: Return RW layouts on OPEN_DOWNGRADE
    NFSv4: Add encode/decode of the layoutreturn op in OPEN_DOWNGRADE
    NFS: Don't disconnect open-owner on NFS4ERR_BAD_SEQID
    NFSv4: ensure __nfs4_find_lock_state returns consistent result.
    NFSv4.1: nfs4_fl_prepare_ds must be careful about reporting success.
    pNFS/flexfiles: delete deviceid, don't mark inactive
    NFS: Clean up nfs_attribute_timeout()
    NFS: Remove unused function nfs_revalidate_inode_rcu()
    NFS: Fix and clean up the access cache validity checking
    NFS: Only look at the change attribute cache state in nfs_weak_revalidate()
    NFS: Clean up cache validity checking
    NFS: Don't revalidate the file on close if we hold a delegation
    NFSv4: Don't discard the attributes returned by asynchronous DELEGRETURN
    NFSv4: Update the attribute cache info in update_changeattr

    Linus Torvalds
     
  • …l/git/bvanassche/linux

    Pull scsi target cleanups from Bart Van Assche:
    "The changes here are:

    - a few small bug fixes for the iSCSI and user space target drivers.

    - minimize the target build time by about 30% by rearranging #include
    directives

    - fix the second argument passed to percpu_ida_alloc()

    - reduce the number of false positive warnings reported by sparse

    These patches pass Wu Fengguang's build bot tests and also the
    linux-next tests"

    * 'scsi-target-for-v4.10' of git://git.kernel.org/pub/scm/linux/kernel/git/bvanassche/linux:
    iscsi-target: Return error if unable to add network portal
    target: Fix spelling mistake and unwrap multi-line text
    target/iscsi: Fix double free in lio_target_tiqn_addtpg()
    target/user: Fix use-after-free of tcmu_cmds if they are expired
    target: Minimize #include directives
    target/user: Add an #include directive
    cxgbit: Add an #include directive
    ibmvscsi_tgt: Add two #include directives
    sbp-target: Add an #include directive
    qla2xxx: Add an #include directive
    configfs: Minimize #include directives
    usb: gadget: Fix second argument of percpu_ida_alloc()
    sbp-target: Fix second argument of percpu_ida_alloc()
    target/user: Fix a data type in tcmu_queue_cmd()
    target: Use NULL instead of 0 to represent a pointer

    Linus Torvalds
     

21 Dec, 2016

2 commits

  • The macro is to be used similarly as WARN_ON as:

    if (WARN_ON_RATELIMIT(condition, state))
    do_something();

    One would expect only 'condition' to affect the 'if', but
    WARN_ON_RATELIMIT does internally only:

    WARN_ON((condition) && __ratelimit(state))

    So the 'if' is affected by the ratelimiting state too. Fix this by
    returning 'condition' in any case.

    Note that nobody uses WARN_ON_RATELIMIT yet, so there is nothing to
    worry about. But I was about to use it and was a bit surprised.

    Link: http://lkml.kernel.org/r/20161215093224.23126-1-jslaby@suse.cz
    Signed-off-by: Jiri Slaby
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • The TPM PCRs are only reset on a hard reboot. In order to validate a
    TPM's quote after a soft reboot (eg. kexec -e), the IMA measurement
    list of the running kernel must be saved and restored on boot.

    This patch uses the kexec buffer passing mechanism to pass the
    serialized IMA binary_runtime_measurements to the next kernel.

    Link: http://lkml.kernel.org/r/1480554346-29071-7-git-send-email-zohar@linux.vnet.ibm.com
    Signed-off-by: Thiago Jung Bauermann
    Signed-off-by: Mimi Zohar
    Acked-by: "Eric W. Biederman"
    Acked-by: Dmitry Kasatkin
    Cc: Andreas Steffen
    Cc: Josh Sklar
    Cc: Dave Young
    Cc: Vivek Goyal
    Cc: Baoquan He
    Cc: Michael Ellerman
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Stewart Smith
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mimi Zohar
     

20 Dec, 2016

4 commits

  • It can be made static.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • Pull quota, fsnotify and ext2 updates from Jan Kara:
    "Changes to locking of some quota operations from dedicated quota mutex
    to s_umount semaphore, a fsnotify fix and a simple ext2 fix"

    * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs:
    quota: Fix bogus warning in dquot_disable()
    fsnotify: Fix possible use-after-free in inode iteration on umount
    ext2: reject inodes with negative size
    quota: Remove dqonoff_mutex
    ocfs2: Use s_umount for quota recovery protection
    quota: Remove dqonoff_mutex from dquot_scan_active()
    ocfs2: Protect periodic quota syncing with s_umount semaphore
    quota: Use s_umount protection for quota operations
    quota: Hold s_umount in exclusive mode when enabling / disabling quotas
    fs: Provide function to get superblock with exclusive s_umount

    Linus Torvalds
     
  • Pull MFD updates from Lee Jones:
    "New Device Support
    - Add support for Ricoh RC5T619 PMIC to rn5t618
    - Add support for PM8821 PMIC to qcom-pm8xxx

    New Functionality:
    - Add support for GPIO to lpc_ich
    - Add support for GPADC to sun4i
    - Add ability for rk808 to shutdown

    Fix-ups:
    - Simplify/strip unnecessary code; tps65218, palmas, tps65217
    - Device Tree binding updates; tps65218, altera-a10sr
    - Provide/export device ID info; tps65218, axp20x-i2c, hi655x-pmic,
    fsl-imx25-tsadc, intel_soc_pmic_bxtwc
    - Use MFD API instead of of_platform_populate(); tps65218
    - Generalise name-space; pm8xxx
    - Supply/edit regmap configuration; axp20x, cs47l24-tables, axp20x
    - Enable compile testing; max77620, max77686, exynos-lpass,
    abx500-core
    - Coding style issues; wm8994-core, wm5102-tables
    - Supply endian support; syscon
    - Remove module support; ab3100-core, ab8500-debugfs, ab8500-gpadc,
    abx500-core

    Bug Fixes:
    - Fix ordering issues; wm8994
    - Fix dependencies (build-time/run-time); exynos_lpass, sun4i-gpadc
    - Fix compiler warnings; sun4i-gpadc
    - Fix leaks; mfd-core
    - Fix page fault during module unload; tps65217"

    * tag 'mfd-for-linus-4.10' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (49 commits)
    mfd: tps65217: Support an interrupt pin as the system wakeup
    mfd: tps65217: Make an interrupt handler simpler
    mfd: tps65217: Update register interrupt mask bits instead of writing operation
    mfd: tps65217: Specify the IRQ name
    mfd: tps65217: Fix page fault on unloading modules
    mfd: palmas: Remove redundant check in palmas_power_off
    mfd: arizona: Disable IRQs during driver remove
    mfd: pm8xxx: add support to pm8821
    mfd: intel-lpss: Try to enable Memory-Write-Invalidate
    mfd: rn5t618: Add Ricoh RC5T619 PMIC support
    mfd: axp20x: Add address extension registers for AXP806 regmap
    mfd: intel_soc_pmic_bxtwc: Fix a typo in MODULE_DEVICE_TABLE()
    mfd: core: Fix device reference leak in mfd_clone_cell
    mfd: bcm590xx: Simplify a test
    mfd: sun4i-gpadc: Select regmap-irq
    mfd: abx500-core: drop unused MODULE_ tags from non-modular code
    mfd: ab8500: make sysctrl explicitly non-modular
    mfd: ab8500-gpadc: Make it explicitly non-modular
    mfd: ab8500-debugfs: Make it explicitly non-modular
    mfd: ab8500-core: Make it explicitly non-modular
    ...

    Linus Torvalds
     

19 Dec, 2016

4 commits

  • …/linux-platform-drivers-x86

    Pull more x86 platform driver updates from Darren Hart:
    "Move and add registration for the mlx-platform driver. Introduce
    button and lid drivers for the surface3 (different from the
    surface3-pro). Add BXT PMIC TMU support. Add Y700 to existing
    ideapad-laptop quirk.

    Summary:

    ideapad-laptop:
    - Add Y700 15-ACZ to no_hw_rfkill DMI list

    surface3_button:
    - Introduce button support for the Surface 3

    surface3-wmi:
    - Add custom surface3 platform device for controlling LID
    - Balance locking on error path

    mlx-platform:
    - Add mlxcpld-hotplug driver registration
    - Fix semicolon.cocci warnings
    - Move module from arch/x86

    platform/x86:
    - Add Whiskey Cove PMIC TMU support"

    * tag 'platform-drivers-x86-v4.10-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86:
    platform/x86: surface3-wmi: Balance locking on error path
    platform/x86: Add Whiskey Cove PMIC TMU support
    platform/x86: ideapad-laptop: Add Y700 15-ACZ to no_hw_rfkill DMI list
    platform/x86: Introduce button support for the Surface 3
    platform/x86: Add custom surface3 platform device for controlling LID
    platform/x86: mlx-platform: Add mlxcpld-hotplug driver registration
    platform/x86: mlx-platform: Fix semicolon.cocci warnings
    platform/x86: mlx-platform: Move module from arch/x86

    Linus Torvalds
     
  • This adds TMU (Time Management Unit) support for Intel BXT platform.
    It enables the alarm wake-up functionality in the TMU unit of Whiskey Cove
    PMIC.

    Signed-off-by: Nilesh Bacchewar
    Reviewed-by: Mika Westerberg
    [andy: resolve merge conflict in Kconfig]
    Signed-off-by: Andy Shevchenko

    Nilesh Bacchewar
     
  • Pull x86 fixes and cleanups from Thomas Gleixner:
    "This set of updates contains:

    - Robustification for the logical package managment. Cures the AMD
    and virtualization issues.

    - Put the correct start_cpu() return address on the stack of the idle
    task.

    - Fixups for the fallout of the nodeid cpuid persistent mapping
    modifciations

    - Move the x86/MPX specific mm_struct member to the arch specific
    mm_context where it belongs

    - Cleanups for C89 struct initializers and useless function
    arguments"

    * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    x86/floppy: Use designated initializers
    x86/mpx: Move bd_addr to mm_context_t
    x86/mm: Drop unused argument 'removed' from sync_global_pgds()
    ACPI/NUMA: Do not map pxm to node when NUMA is turned off
    x86/acpi: Use proper macro for invalid node
    x86/smpboot: Prevent false positive out of bounds cpumask access warning
    x86/boot/64: Push correct start_cpu() return address
    x86/boot/64: Use 'push' instead of 'call' in start_cpu()
    x86/smpboot: Make logical package management more robust

    Linus Torvalds
     
  • Pull SMP hotplug fixes from Thomas Gleixner:
    "Two fixlets for cpu hotplug:

    - Fix a subtle ordering problem with the dummy timer. This happened
    to work before the conversion by chance due to initcall ordering.

    - Fix the function comment for __cpuhp_setup_state()"

    * 'smp-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    cpu/hotplug: Clarify description of __cpuhp_setup_state() return value
    clocksource/dummy_timer: Move hotplug callback after the real timers

    Linus Torvalds
     

18 Dec, 2016

1 commit

  • Pull networking fixes and cleanups from David Miller:

    1) Revert bogus nla_ok() change, from Alexey Dobriyan.

    2) Various bpf validator fixes from Daniel Borkmann.

    3) Add some necessary SET_NETDEV_DEV() calls to hsis_femac and hip04
    drivers, from Dongpo Li.

    4) Several ethtool ksettings conversions from Philippe Reynes.

    5) Fix bugs in inet port management wrt. soreuseport, from Tom Herbert.

    6) XDP support for virtio_net, from John Fastabend.

    7) Fix NAT handling within a vrf, from David Ahern.

    8) Endianness fixes in dpaa_eth driver, from Claudiu Manoil

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (63 commits)
    net: mv643xx_eth: fix build failure
    isdn: Constify some function parameters
    mlxsw: spectrum: Mark split ports as such
    cgroup: Fix CGROUP_BPF config
    qed: fix old-style function definition
    net: ipv6: check route protocol when deleting routes
    r6040: move spinlock in r6040_close as SOFTIRQ-unsafe lock order detected
    irda: w83977af_ir: cleanup an indent issue
    net: sfc: use new api ethtool_{get|set}_link_ksettings
    net: davicom: dm9000: use new api ethtool_{get|set}_link_ksettings
    net: cirrus: ep93xx: use new api ethtool_{get|set}_link_ksettings
    net: chelsio: cxgb3: use new api ethtool_{get|set}_link_ksettings
    net: chelsio: cxgb2: use new api ethtool_{get|set}_link_ksettings
    bpf: fix mark_reg_unknown_value for spilled regs on map value marking
    bpf: fix overflow in prog accounting
    bpf: dynamically allocate digest scratch buffer
    gtp: Fix initialization of Flags octet in GTPv1 header
    gtp: gtp_check_src_ms_ipv4() always return success
    net/x25: use designated initializers
    isdn: use designated initializers
    ...

    Linus Torvalds