aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDavidlohr Bueso <dave@stgolabs.net>2015-06-30 02:26:02 -0400
committerThomas Gleixner <tglx@linutronix.de>2015-07-20 05:45:45 -0400
commitab51fbab39d864f3223e44a2600fd951df261f0b (patch)
treecd8106193d0d15b9690a8e80ceec85d202f8e1cb /lib
parent767f509ca11269c2bcd92e3972a93096f2173ac0 (diff)
futex: Fault/error injection capabilities
Although futexes are well known for being a royal pita, we really have very little debugging capabilities - except for relying on tglx's eye half the time. By simply making use of the existing fault-injection machinery, we can improve this situation, allowing generating artificial uaddress faults and deadlock scenarios. Of course, when this is disabled in production systems, the overhead for failure checks is practically zero -- so this is very cheap at the same time. Future work would be nice to now enhance trinity to make use of this. There is a special tunable 'ignore-private', which can filter out private futexes. Given the tsk->make_it_fail filter and this option, pi futexes can be narrowed down pretty closely. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Darren Hart <darren@dvhart.com> Cc: Davidlohr Bueso <dave@stgolabs.net> Link: http://lkml.kernel.org/r/1435645562-975-3-git-send-email-dave@stgolabs.net Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/Kconfig.debug7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index e2894b23efb6..22554d6f720f 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -1542,6 +1542,13 @@ config FAIL_MMC_REQUEST
1542 and to test how the mmc host driver handles retries from 1542 and to test how the mmc host driver handles retries from
1543 the block device. 1543 the block device.
1544 1544
1545config FAIL_FUTEX
1546 bool "Fault-injection capability for futexes"
1547 select DEBUG_FS
1548 depends on FAULT_INJECTION && FUTEX
1549 help
1550 Provide fault-injection capability for futexes.
1551
1545config FAULT_INJECTION_DEBUG_FS 1552config FAULT_INJECTION_DEBUG_FS
1546 bool "Debugfs entries for fault-injection capabilities" 1553 bool "Debugfs entries for fault-injection capabilities"
1547 depends on FAULT_INJECTION && SYSFS && DEBUG_FS 1554 depends on FAULT_INJECTION && SYSFS && DEBUG_FS