Paul E. McKenney
9c85fc004e
locktorture: Print ratio of acquisitions, not failures
...
commit 80c503e0e68fbe271680ab48f0fe29bc034b01b7 upstream.
The __torture_print_stats() function in locktorture.c carefully
initializes local variable "min" to statp[0].n_lock_acquired, but
then compares it to statp[i].n_lock_fail. Given that the .n_lock_fail
field should normally be zero, and given the initialization, it seems
reasonable to display the maximum and minimum number acquisitions
instead of miscomputing the maximum and minimum number of failures.
This commit therefore switches from failures to acquisitions.
And this turns out to be not only a day-zero bug, but entirely my
own fault. I hate it when that happens!
Fixes: 0af3fe1efa ("locktorture: Add a lock-torture kernel module")
Reported-by: Will Deacon <will@kernel.org>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Acked-by: Will Deacon <will@kernel.org>
Cc: Davidlohr Bueso <dave@stgolabs.net>
Cc: Josh Triplett <josh@joshtriplett.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-23 10:30:23 +02:00
..
lockdep.c
locking/lockdep: Avoid recursion in lockdep_count_{for,back}ward_deps()
2020-04-17 10:48:42 +02:00
lockdep_internals.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
lockdep_proc.c
locking/lockdep: Hide unused 'class' variable
2019-07-31 07:27:09 +02:00
lockdep_states.h
locking/lockdep: Rework FS_RECLAIM annotation
2017-08-10 12:29:03 +02:00
locktorture.c
locktorture: Print ratio of acquisitions, not failures
2020-04-23 10:30:23 +02:00
Makefile
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
mcs_spinlock.h
locking/mcs: Use smp_cond_load_acquire() in MCS spin loop
2018-04-27 09:48:49 +02:00
mutex-debug.c
locking/mutex: Rework mutex::owner
2016-10-25 11:31:50 +02:00
mutex-debug.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
mutex.c
locking/mutex: Fix mutex debug call and ww_mutex documentation
2018-09-10 10:05:10 +02:00
mutex.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
osq_lock.c
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
percpu-rwsem.c
locking/percpu-rwsem: Replace waitqueue with rcuwait
2017-01-14 11:14:35 +01:00
qrwlock.c
locking/qrwlock: Prevent slowpath writers getting held up by fastpath
2017-10-25 10:57:25 +02:00
qspinlock.c
locking/qspinlock, x86: Provide liveness guarantee
2018-12-21 14:15:12 +01:00
qspinlock_paravirt.h
Revert "locking/pvqspinlock: Don't wait if vCPU is preempted"
2019-10-11 18:21:06 +02:00
qspinlock_stat.h
locking/qspinlock: Add stat tracking for pending vs. slowpath
2018-04-27 09:48:53 +02:00
rtmutex-debug.c
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
rtmutex-debug.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
rtmutex.c
futex: Handle early deadlock return correctly
2019-02-12 19:47:24 +01:00
rtmutex.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
rtmutex_common.h
locking/rtmutex: Handle non enqueued waiters gracefully in remove_waiter()
2018-03-28 23:01:30 +02:00
rwsem-spinlock.c
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
2017-11-02 11:10:55 +01:00
rwsem-xadd.c
locking/rwsem: Prevent decrement of reader count before increment
2019-05-22 07:37:34 +02:00
rwsem.c
locking/rwsem: Fix up_read_non_owner() warning with DEBUG_RWSEMS
2018-06-20 11:29:23 +02:00
rwsem.h
locking/rwsem: Add a new RWSEM_ANONYMOUSLY_OWNED flag
2018-05-16 11:45:15 +02:00
semaphore.c
sched/headers: Prepare for new header dependencies before moving code to <linux/sched/debug.h>
2017-03-02 08:42:34 +01:00
spinlock.c
locking/core: Remove break_lock field when CONFIG_GENERIC_LOCKBREAK=y
2017-12-12 11:24:01 +01:00
spinlock_debug.c
locking/spinlock/debug: Fix various data races
2020-01-12 12:17:05 +01:00
test-ww_mutex.c
locking/ww_mutex: Fix runtime warning in the WW mutex selftest
2018-10-03 08:56:31 +02:00