From: Greg Kroah-Hartman Date: Mon, 11 Jul 2016 23:57:08 +0000 (-0700) Subject: delete queue-3.14/locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch X-Git-Tag: v4.6.5~33 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3db20337ad5da5fbadb6594c103ff04d1a500371;p=thirdparty%2Fkernel%2Fstable-queue.git delete queue-3.14/locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch --- diff --git a/queue-3.14/locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch b/queue-3.14/locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch deleted file mode 100644 index 4b697fc494c..00000000000 --- a/queue-3.14/locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch +++ /dev/null @@ -1,60 +0,0 @@ -From 0422e83d84ae24b933e4b0d4c1e0f0b4ae8a0a3b Mon Sep 17 00:00:00 2001 -From: Chris Wilson -Date: Thu, 26 May 2016 21:08:17 +0100 -Subject: locking/ww_mutex: Report recursive ww_mutex locking early - -From: Chris Wilson - -commit 0422e83d84ae24b933e4b0d4c1e0f0b4ae8a0a3b upstream. - -Recursive locking for ww_mutexes was originally conceived as an -exception. However, it is heavily used by the DRM atomic modesetting -code. Currently, the recursive deadlock is checked after we have queued -up for a busy-spin and as we never release the lock, we spin until -kicked, whereupon the deadlock is discovered and reported. - -A simple solution for the now common problem is to move the recursive -deadlock discovery to the first action when taking the ww_mutex. - -Suggested-by: Maarten Lankhorst -Signed-off-by: Chris Wilson -Signed-off-by: Peter Zijlstra (Intel) -Reviewed-by: Maarten Lankhorst -Cc: Andrew Morton -Cc: Linus Torvalds -Cc: Paul E. McKenney -Cc: Peter Zijlstra -Cc: Thomas Gleixner -Link: http://lkml.kernel.org/r/1464293297-19777-1-git-send-email-chris@chris-wilson.co.uk -Signed-off-by: Ingo Molnar -Signed-off-by: Greg Kroah-Hartman - ---- - kernel/locking/mutex.c | 9 ++++++--- - 1 file changed, 6 insertions(+), 3 deletions(-) - ---- a/kernel/locking/mutex.c -+++ b/kernel/locking/mutex.c -@@ -304,9 +304,6 @@ __mutex_lock_check_stamp(struct mutex *l - if (!hold_ctx) - return 0; - -- if (unlikely(ctx == hold_ctx)) -- return -EALREADY; -- - if (ctx->stamp - hold_ctx->stamp <= LONG_MAX && - (ctx->stamp != hold_ctx->stamp || ctx > hold_ctx)) { - #ifdef CONFIG_DEBUG_MUTEXES -@@ -417,6 +414,12 @@ __mutex_lock_common(struct mutex *lock, - unsigned long flags; - int ret; - -+ if (use_ww_ctx) { -+ struct ww_mutex *ww = container_of(lock, struct ww_mutex, base); -+ if (unlikely(ww_ctx == READ_ONCE(ww->ctx))) -+ return -EALREADY; -+ } -+ - preempt_disable(); - mutex_acquire_nest(&lock->dep_map, subclass, 0, nest_lock, ip); - diff --git a/queue-3.14/series b/queue-3.14/series index ad9f3e2e8f6..3f0dea31407 100644 --- a/queue-3.14/series +++ b/queue-3.14/series @@ -13,7 +13,6 @@ powerpc-iommu-remove-the-dependency-on-eeh-struct-in-ddw-mechanism.patch powerpc-pseries-fix-pci-config-address-for-ddw.patch powerpc-tm-always-reclaim-in-start_thread-for-exec-class-syscalls.patch usb-ehci-declare-hostpc-register-as-zero-length-array.patch -locking-ww_mutex-report-recursive-ww_mutex-locking-early.patch x86-build-copy-ldlinux.c32-to-image.iso.patch kprobes-x86-clear-tf-bit-in-fault-on-single-stepping.patch x86-amd_nb-fix-boot-crash-on-non-amd-systems.patch