[GIT PULL] locking changes for v5.5
From: Ingo Molnar
Date: Mon Nov 25 2019 - 06:35:51 EST
Linus,
Please pull the latest locking-core-for-linus git tree from:
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git locking-core-for-linus
# HEAD: 500543c53a54134ced386aed85cd93cf1363f981 lkdtm: Remove references to CONFIG_REFCOUNT_FULL
The main changes in this cycle were:
- A comprehensive rewrite of the robust/PI futex code's exit handling to
fix various exit races. (Thomas Gleixner et al)
- Rework the generic REFCOUNT_FULL implementation using atomic_fetch_*
operations so that the performance impact of the cmpxchg() loops is
mitigated for common refcount operations.
With these performance improvements the generic implementation of
refcount_t should be good enough for everybody - and this got
confirmed by performance testing, so remove ARCH_HAS_REFCOUNT and
REFCOUNT_FULL entirely, leaving the generic implementation enabled
unconditionally. (Will Deacon)
- Other misc changes, fixes, cleanups.
Thanks,
Ingo
------------------>
Dan Carpenter (1):
locking/lockdep: Update the comment for __lock_release()
Davidlohr Bueso (2):
futex: Drop leftover wake_q_add() comment
locking/mutex: Complain upon mutex API misuse in IRQ contexts
Qian Cai (1):
locking/lockdep: Remove unused @nested argument from lock_release()
Thomas Gleixner (11):
futex: Move futex exit handling into futex code
futex: Replace PF_EXITPIDONE with a state
exit/exec: Seperate mm_release()
futex: Split futex_mm_release() for exit/exec
futex: Set task::futex_state to DEAD right after handling futex exit
futex: Mark the begin of futex exit explicitly
futex: Sanitize exit state handling
futex: Provide state handling for exec() as well
futex: Add mutex around futex exit
futex: Provide distinct return value when owner is exiting
futex: Prevent exit livelock
Waiman Long (1):
lib/smp_processor_id: Don't use cpumask_equal()
Will Deacon (10):
locking/refcount: Define constants for saturation and max refcount values
locking/refcount: Ensure integer operands are treated as signed
locking/refcount: Remove unused refcount_*_checked() variants
locking/refcount: Move the bulk of the REFCOUNT_FULL implementation into the <linux/refcount.h> header
locking/refcount: Improve performance of generic REFCOUNT_FULL code
locking/refcount: Move saturation warnings out of line
locking/refcount: Consolidate REFCOUNT_{MAX,SATURATED} definitions
locking/refcount: Consolidate implementations of refcount_t
locking/refcount: Remove unused 'refcount_error_report()' function
lkdtm: Remove references to CONFIG_REFCOUNT_FULL
Yang Tao (1):
futex: Prevent robust futex exit race
arch/Kconfig | 21 --
arch/arm/Kconfig | 1 -
arch/arm64/Kconfig | 1 -
arch/s390/configs/debug_defconfig | 1 -
arch/x86/Kconfig | 1 -
arch/x86/include/asm/asm.h | 6 -
arch/x86/include/asm/refcount.h | 126 ----------
arch/x86/mm/extable.c | 49 ----
drivers/gpu/drm/drm_connector.c | 2 +-
drivers/gpu/drm/i915/Kconfig.debug | 1 -
drivers/gpu/drm/i915/gem/i915_gem_shrinker.c | 6 +-
drivers/gpu/drm/i915/gt/intel_engine_pm.c | 2 +-
drivers/gpu/drm/i915/i915_request.c | 2 +-
drivers/misc/lkdtm/refcount.c | 11 +-
drivers/tty/tty_ldsem.c | 8 +-
fs/dcache.c | 2 +-
fs/exec.c | 2 +-
fs/jbd2/transaction.c | 4 +-
fs/kernfs/dir.c | 4 +-
fs/ocfs2/dlmglue.c | 2 +-
include/linux/compat.h | 2 -
include/linux/futex.h | 40 +++-
include/linux/jbd2.h | 2 +-
include/linux/kernel.h | 7 -
include/linux/lockdep.h | 21 +-
include/linux/percpu-rwsem.h | 4 +-
include/linux/rcupdate.h | 2 +-
include/linux/refcount.h | 269 +++++++++++++++++----
include/linux/rwlock_api_smp.h | 16 +-
include/linux/sched.h | 3 +-
include/linux/sched/mm.h | 6 +-
include/linux/seqlock.h | 4 +-
include/linux/spinlock_api_smp.h | 8 +-
include/linux/ww_mutex.h | 2 +-
include/net/sock.h | 2 +-
kernel/bpf/stackmap.c | 2 +-
kernel/cpu.c | 2 +-
kernel/exit.c | 30 +--
kernel/fork.c | 40 ++--
kernel/futex.c | 326 ++++++++++++++++++++++----
kernel/locking/lockdep.c | 7 +-
kernel/locking/mutex.c | 8 +-
kernel/locking/rtmutex.c | 6 +-
kernel/locking/rwsem.c | 10 +-
kernel/panic.c | 11 -
kernel/printk/printk.c | 10 +-
kernel/sched/core.c | 2 +-
lib/locking-selftest.c | 24 +-
lib/refcount.c | 255 +++-----------------
lib/smp_processor_id.c | 2 +-
mm/memcontrol.c | 2 +-
net/core/sock.c | 2 +-
tools/lib/lockdep/include/liblockdep/common.h | 3 +-
tools/lib/lockdep/include/liblockdep/mutex.h | 2 +-
tools/lib/lockdep/include/liblockdep/rwlock.h | 2 +-
tools/lib/lockdep/preload.c | 16 +-
56 files changed, 686 insertions(+), 716 deletions(-)
delete mode 100644 arch/x86/include/asm/refcount.h