Merge branch 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
authorLinus Torvalds <torvalds@linux-foundation.org>
Mon, 13 Apr 2015 17:27:28 +0000 (10:27 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 13 Apr 2015 17:27:28 +0000 (10:27 -0700)
Pull core locking changes from Ingo Molnar:
 "Main changes:

   - jump label asm preparatory work for PowerPC (Anton Blanchard)

   - rwsem optimizations and cleanups (Davidlohr Bueso)

   - mutex optimizations and cleanups (Jason Low)

   - futex fix (Oleg Nesterov)

   - remove broken atomicity checks from {READ,WRITE}_ONCE() (Peter
     Zijlstra)"

* 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  powerpc, jump_label: Include linux/jump_label.h to get HAVE_JUMP_LABEL define
  jump_label: Allow jump labels to be used in assembly
  jump_label: Allow asm/jump_label.h to be included in assembly
  locking/mutex: Further simplify mutex_spin_on_owner()
  locking: Remove atomicy checks from {READ,WRITE}_ONCE
  locking/rtmutex: Rename argument in the rt_mutex_adjust_prio_chain() documentation as well
  locking/rwsem: Fix lock optimistic spinning when owner is not running
  locking: Remove ACCESS_ONCE() usage
  locking/rwsem: Check for active lock before bailing on spinning
  locking/rwsem: Avoid deceiving lock spinners
  locking/rwsem: Set lock ownership ASAP
  locking/rwsem: Document barrier need when waking tasks
  locking/futex: Check PF_KTHREAD rather than !p->mm to filter out kthreads
  locking/mutex: Refactor mutex_spin_on_owner()
  locking/mutex: In mutex_spin_on_owner(), return true when owner changes

1  2 
Makefile
kernel/locking/rtmutex.c

diff --combined Makefile
index fbd43bfe4445bc8a11d3d7ab946a3e61738cf1b3,a2aa475543e9c17f59a228daa76fe5caae88d47a..9b76ce1e08bbb80d15e3f2ee4859157323a23ee0
+++ b/Makefile
@@@ -1,7 -1,7 +1,7 @@@
  VERSION = 4
  PATCHLEVEL = 0
  SUBLEVEL = 0
 -EXTRAVERSION = -rc1
 +EXTRAVERSION =
  NAME = Hurr durr I'ma sheep
  
  # *DOCUMENTATION*
@@@ -779,6 -779,7 +779,7 @@@ KBUILD_ARFLAGS := $(call ar-option,D
  # check for 'asm goto'
  ifeq ($(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-goto.sh $(CC)), y)
        KBUILD_CFLAGS += -DCC_HAVE_ASM_GOTO
+       KBUILD_AFLAGS += -DCC_HAVE_ASM_GOTO
  endif
  
  include $(srctree)/scripts/Makefile.kasan
diff --combined kernel/locking/rtmutex.c
index 6357265a31ad1a34b881aba31abe27ab6d3921ec,c0b8e9db6b2e050e22448a6185f4e93ac0c75e8c..b73279367087ca779072b79a784f69224929c149
@@@ -349,7 -349,7 +349,7 @@@ static inline struct rt_mutex *task_blo
   *
   * @task:     the task owning the mutex (owner) for which a chain walk is
   *            probably needed
-  * @deadlock_detect: do we have to carry out deadlock detection?
+  * @chwalk:   do we have to carry out deadlock detection?
   * @orig_lock:        the mutex (can be NULL if we are walking the chain to recheck
   *            things for a task that has just got its priority adjusted, and
   *            is waiting on a mutex)
@@@ -1193,7 -1193,6 +1193,7 @@@ rt_mutex_slowlock(struct rt_mutex *lock
                ret = __rt_mutex_slowlock(lock, state, timeout, &waiter);
  
        if (unlikely(ret)) {
 +              __set_current_state(TASK_RUNNING);
                if (rt_mutex_has_waiters(lock))
                        remove_waiter(lock, &waiter);
                rt_mutex_handle_deadlock(ret, chwalk, &waiter);