22 Sep, 2016

1 commit


28 Apr, 2016

1 commit


04 Nov, 2015

1 commit

  • Pull locking changes from Ingo Molnar:
    "The main changes in this cycle were:

    - More gradual enhancements to atomic ops: new atomic*_read_ctrl()
    ops, synchronize atomic_{read,set}() ordering requirements between
    architectures, add atomic_long_t bitops. (Peter Zijlstra)

    - Add _{relaxed|acquire|release}() variants for inc/dec atomics and
    use them in various locking primitives: mutex, rtmutex, mcs, rwsem.
    This enables weakly ordered architectures (such as arm64) to make
    use of more locking related optimizations. (Davidlohr Bueso)

    - Implement atomic[64]_{inc,dec}_relaxed() on ARM. (Will Deacon)

    - Futex kernel data cache footprint micro-optimization. (Rasmus
    Villemoes)

    - pvqspinlock runtime overhead micro-optimization. (Waiman Long)

    - misc smaller fixlets"

    * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    ARM, locking/atomics: Implement _relaxed variants of atomic[64]_{inc,dec}
    locking/rwsem: Use acquire/release semantics
    locking/mcs: Use acquire/release semantics
    locking/rtmutex: Use acquire/release semantics
    locking/mutex: Use acquire/release semantics
    locking/asm-generic: Add _{relaxed|acquire|release}() variants for inc/dec atomics
    atomic: Implement atomic_read_ctrl()
    atomic, arch: Audit atomic_{read,set}()
    atomic: Add atomic_long_t bitops
    futex: Force hot variables into a single cache line
    locking/pvqspinlock: Kick the PV CPU unconditionally when _Q_SLOW_VAL
    locking/osq: Relax atomic semantics
    locking/qrwlock: Rename ->lock to ->wait_lock
    locking/Documentation/lockstat: Fix typo - lokcing -> locking
    locking/atomics, cmpxchg: Privatize the inclusion of asm/cmpxchg.h

    Linus Torvalds
     

07 Oct, 2015

1 commit

  • Real time mutexes is one of the few general primitives
    that we do not have in locktorture. Address this -- a few
    considerations:

    o To spice things up, enable competing thread(s) to become
    rt, such that we can stress different prio boosting paths
    in the rtmutex code. Introduce a ->task_boost callback,
    only used by rtmutex-torturer. Tasks will boost/deboost
    around every 50k (arbitrarily) lock/unlock operations.

    o Hold times are similar to what we have for other locks:
    only occasionally having longer hold times (per ~200k ops).
    So we roughly do two full rt boost+deboosting ops with
    short hold times.

    Signed-off-by: Davidlohr Bueso
    Signed-off-by: Paul E. McKenney
    Reviewed-by: Josh Triplett

    Davidlohr Bueso
     

18 Sep, 2015

1 commit


12 Feb, 2015

1 commit

  • Pull documentation updates from Jonathan Corbet:
    "Highlights this time around include:

    - A thrashing of SubmittingPatches to bring it out of the "send
    everything to Linus" era of kernel development.

    - A new document on completions from Nicholas McGuire

    - Lots of typo fixes, formatting improvements, corrections, build
    fixes, and more"

    * tag 'docs-for-linus' of git://git.lwn.net/linux-2.6: (35 commits)
    Documentation: Fix the wrong command `echo -1 > set_ftrace_pid` for cleaning the filter.
    can-doc: Fixed a wrong filepath in can.txt
    Documentation: Fix trivial typo in comment.
    kgdb,docs: Fix typo and minor style issues
    Documentation: add description for FTRACE probe status
    doc: brief user documentation for completion
    Documentation/misc-devices/mei: Fix indentation of embedded code.
    Documentation/misc-devices/mei: Fix indentation of enumeration.
    Documentation/misc-devices/mei: Fix spacing around parentheses.
    Documentation/misc-devices/mei: Fix formatting of headings.
    Documentation: devicetree: Fix double words in Doumentation/devicetree
    Documentation: mm: Fix typo in vm.txt
    lockstat: Add documentation on contention and contenting points
    Documentation: fix blackfin gptimers-example build errors
    Fixes column alignment in table of contents entry 1.9 in Documentation/filesystems/proc.txt
    CodingStyle: enable emacs display of trailing whitespace
    DocBook: Do not exceed argument list limit
    gpio: board.txt: Fix the gpio name example
    Documentation/SubmittingPatches: unify whitespace/tabs for the DCO
    MAINTAINERS: Add the docs-next git tree to the maintainer entry
    ...

    Linus Torvalds
     

29 Jan, 2015

1 commit


16 Jan, 2015

1 commit

  • lockdep code has been moved from kernel/ to kernel/locking/ by commit
    8eddac3f103736163f49255bcb109edadea167f6 ("locking: Move the lockdep
    code to kernel/locking/"). But, path to lockdep code in document was not
    updated.

    This commit updates the path.

    Signed-off-by: SeongJae Park
    Signed-off-by: Peter Zijlstra (Intel)
    Link: http://lkml.kernel.org/r/1421176921-27688-1-git-send-email-sj38.park@gmail.com
    Cc: Jonathan Corbet
    Cc: Linus Torvalds
    Cc: linux-doc@vger.kernel.org
    Signed-off-by: Ingo Molnar

    SeongJae Park
     

30 Dec, 2014

1 commit

  • Added files
    - hsi.txt was added by 3a8ab8af (HSI: Add some general description for
    the HSI subsystem)
    - lzo.txt was added by d98a0526 (lzo: document part of the encoding)
    - xillybus.txt was added by 7051924f (xillybus: Move out of staging)
    - mailbox.txt was added by 15320fbc (add documentation for mailbox
    framework)

    Moved files
    - xommit 214e0aed (Move locking related docs into Documentation/locking/):
    * lockdep-design.txt
    * lockstat.txt
    * mutex-design.txt
    * rt-mutex-design.txt
    * rt-mutex.txt
    * spinlocks.txt
    * ww-mutex-design.txt
    - kselftest.txt was moved by 3c415707 (kselftest: Move the docs to the
    Documentation dir)

    CC: Davidlohr Bueso
    CC: Willy Tarreau
    CC: Randy Dunlap
    CC: Greg Kroah-Hartman
    CC: Sebastian Reichel
    CC: Eli Billauer
    CC: Jonathan Corbet
    CC: Jiri Kosina
    CC: linux-doc@vger.kernel.org
    CC: linux-kernel@vger.kernel.org
    Cc: Tim Bird
    Cc: Shuah Khan

    Signed-off-by: Henrik Austad
    Signed-off-by: Jonathan Corbet

    Henrik Austad
     

10 Dec, 2014

1 commit


08 Dec, 2014

1 commit

  • Local/global locks are currently not documented anywhere other
    than in an somewhat out-of-date LWN article - this is an attempt
    to document the current state of lglocks.

    This patch is against linux-next 3.18.0-rc6

    Signed-off-by: Nicholas Mc Guire
    Cc: Paul E. McKenney
    Cc: Carsten Emde
    Cc: Steven Rostedt
    Cc: Jonathan Corbet
    Cc: Linus Torvalds
    Cc: Andrew Morton
    Cc: Peter Zijlstra
    Link: http://lkml.kernel.org/r/20141208083326.GA29895@opentech.at
    Signed-off-by: Ingo Molnar

    Nicholas Mc Guire
     

13 Oct, 2014

1 commit

  • Pull core locking updates from Ingo Molnar:
    "The main updates in this cycle were:

    - mutex MCS refactoring finishing touches: improve comments, refactor
    and clean up code, reduce debug data structure footprint, etc.

    - qrwlock finishing touches: remove old code, self-test updates.

    - small rwsem optimization

    - various smaller fixes/cleanups"

    * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    locking/lockdep: Revert qrwlock recusive stuff
    locking/rwsem: Avoid double checking before try acquiring write lock
    locking/rwsem: Move EXPORT_SYMBOL() lines to follow function definition
    locking/rwlock, x86: Delete unused asm/rwlock.h and rwlock.S
    locking/rwlock, x86: Clean up asm/spinlock*.h to remove old rwlock code
    locking/semaphore: Resolve some shadow warnings
    locking/selftest: Support queued rwlock
    locking/lockdep: Restrict the use of recursive read_lock() with qrwlock
    locking/spinlocks: Always evaluate the second argument of spin_lock_nested()
    locking/Documentation: Update locking/mutex-design.txt disadvantages
    locking/Documentation: Move locking related docs into Documentation/locking/
    locking/mutexes: Use MUTEX_SPIN_ON_OWNER when appropriate
    locking/mutexes: Refactor optimistic spinning code
    locking/mcs: Remove obsolete comment
    locking/mutexes: Document quick lock release when unlocking
    locking/mutexes: Standardize arguments in lock/unlock slowpaths
    locking: Remove deprecated smp_mb__() barriers

    Linus Torvalds
     

30 Sep, 2014

1 commit

  • Add a "rw_lock" torture test to stress kernel rwlocks and their irq
    variant. Reader critical regions are 5x longer than writers. As such
    a similar ratio of lock acquisitions is seen in the statistics. In the
    case of massive contention, both hold the lock for 1/10 of a second.

    Signed-off-by: Davidlohr Bueso
    Signed-off-by: Paul E. McKenney

    Davidlohr Bueso
     

17 Sep, 2014

4 commits

  • We can easily do so with our new reader lock support. Just an arbitrary
    design default: readers have higher (5x) critical region latencies than
    writers: 50 ms and 10 ms, respectively.

    Signed-off-by: Davidlohr Bueso
    Signed-off-by: Paul E. McKenney

    Davidlohr Bueso
     
  • Most of it is based on what we already have for writers. This allows
    readers to be very independent (and thus configurable), enabling
    future module parameters to control things such as rw distribution.
    Furthermore, readers have their own delaying function, allowing us
    to test different rw critical region latencies, and stress locking
    internals. Similarly, statistics, for now will only serve for the
    number of lock acquisitions -- as opposed to writers, readers have
    no failure detection.

    In addition, introduce a new nreaders_stress module parameter. The
    default number of readers will be the same number of writers threads.
    Writer threads are interleaved with readers. Documentation is updated,
    respectively.

    Signed-off-by: Davidlohr Bueso
    Signed-off-by: Paul E. McKenney

    Davidlohr Bueso
     
  • Add a "mutex_lock" torture test. The main difference with the already
    existing spinlock tests is that the latency of the critical region
    is much larger. We randomly delay for (arbitrarily) either 500 ms or,
    otherwise, 25 ms. While this can considerably reduce the amount of
    writes compared to non blocking locks, if run long enough it can have
    the same torturous effect. Furthermore it is more representative of
    mutex hold times and can stress better things like thrashing.

    Signed-off-by: Davidlohr Bueso
    Signed-off-by: Paul E. McKenney

    Davidlohr Bueso
     
  • Just like Documentation/RCU/torture.txt, begin a document for the
    locktorture module. This module is still pretty green, so I have
    just added some specific sections to the doc (general desc, params,
    usage, etc.). Further development should update the file.

    Signed-off-by: Davidlohr Bueso
    [ paulmck: Apply Randy Dunlap review comments. ]
    Signed-off-by: Paul E. McKenney

    Davidlohr Bueso
     

13 Aug, 2014

2 commits

  • Fortunately Jason was able to reduce some of the overhead we
    had introduced in the original rwsem optimistic spinning -
    an it is now the same size as mutexes. Update the documentation
    accordingly.

    Signed-off-by: Davidlohr Bueso
    Acked-by: Jason Low
    Signed-off-by: Peter Zijlstra
    Cc: aswin@hp.com
    Cc: Linus Torvalds
    Cc: Randy Dunlap
    Link: http://lkml.kernel.org/r/1406752916-3341-7-git-send-email-davidlohr@hp.com
    Signed-off-by: Ingo Molnar

    Davidlohr Bueso
     
  • Specifically:
    Documentation/locking/lockdep-design.txt
    Documentation/locking/lockstat.txt
    Documentation/locking/mutex-design.txt
    Documentation/locking/rt-mutex-design.txt
    Documentation/locking/rt-mutex.txt
    Documentation/locking/spinlocks.txt
    Documentation/locking/ww-mutex-design.txt

    Signed-off-by: Davidlohr Bueso
    Acked-by: Randy Dunlap
    Signed-off-by: Peter Zijlstra
    Cc: jason.low2@hp.com
    Cc: aswin@hp.com
    Cc: Alexei Starovoitov
    Cc: Al Viro
    Cc: Andrew Morton
    Cc: Chris Mason
    Cc: Dan Streetman
    Cc: David Airlie
    Cc: Davidlohr Bueso
    Cc: David S. Miller
    Cc: Greg Kroah-Hartman
    Cc: Heiko Carstens
    Cc: Jason Low
    Cc: Josef Bacik
    Cc: Kees Cook
    Cc: Linus Torvalds
    Cc: Lubomir Rintel
    Cc: Masanari Iida
    Cc: Paul E. McKenney
    Cc: Randy Dunlap
    Cc: Tim Chen
    Cc: Vineet Gupta
    Cc: fengguang.wu@intel.com
    Link: http://lkml.kernel.org/r/1406752916-3341-6-git-send-email-davidlohr@hp.com
    Signed-off-by: Ingo Molnar

    Davidlohr Bueso