07 Mar, 2010
1 commit
-
Add adds a debugfs interface and additional failure modes to LKDTM to
provide similar functionality to the provoke-crash driver submitted here:http://lwn.net/Articles/371208/
Crashes can now be induced either through module parameters (as before)
or through the debugfs interface as in provoke-crash.The patch also provides a new "direct" interface, where KPROBES are not
used, i.e., the crash is invoked directly upon write to the debugfs
file. When built without KPROBES configured, only this mode is available.Signed-off-by: Simon Kagstrom
Cc: M. Mohan Kumar
Cc: Americo Wang
Cc: David Woodhouse
Cc: Ingo Molnar
Cc: "Eric W. Biederman" ,
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
03 Feb, 2010
1 commit
-
init_fault_attr_entries() should be init_fault_attr_dentries().
cleanup_fault_attr_entries() should be cleanup_fault_attr_dentries().
Signed-off-by: Anton Blanchard
Acked-by: Akinobu Mita
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
16 Jun, 2009
1 commit
-
Many developers use "/debug/" or "/debugfs/" or "/sys/kernel/debug/"
directory name to mount debugfs filesystem for ftrace according to
./Documentation/tracers/ftrace.txt file.And, three directory names(ex:/debug/, /debugfs/, /sys/kernel/debug/) is
existed in kernel source like ftrace, DRM, Wireless, Documentation,
Network[sky2]files to mount debugfs filesystem.debugfs means debug filesystem for debugging easy to use by greg kroah
hartman. "/sys/kernel/debug/" name is suitable as directory name
of debugfs filesystem.
- debugfs related reference: http://lwn.net/Articles/334546/Fix inconsistency of directory name to mount debugfs filesystem.
* From Steven Rostedt
- find_debugfs() and tracing_files() in this patch.Signed-off-by: GeunSik Lim
Acked-by : Inaky Perez-Gonzalez
Reviewed-by : Steven Rostedt
Reviewed-by : James Smart
CC: Jiri Kosina
CC: David Airlie
CC: Peter Osterlund
CC: Ananth N Mavinakayanahalli
CC: Anil S Keshavamurthy
CC: Masami Hiramatsu
Signed-off-by: Greg Kroah-Hartman
17 Jul, 2007
2 commits
-
Fix and cleanup example scripts in fault injection documentation.
1. Eliminate broken oops() shell function.
2. Fold failcmd.sh and failmodule.sh into example scripts. It makes
the example scripts work independent of current working directory.3. Set "space" parameter to 0 to start injecting errors immediately.
4. Use /sys/module//sections/.data as upper bound of
.text section. Because some module doesn't have .exit.text section.Signed-off-by: Akinobu Mita
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Limiting smaller allocation failures by fault injection helps to find real
possible bugs. Because higher order allocations are likely to fail and
zero-order allocations are not likely to fail.This patch adds min-order parameter to fail_page_alloc. It specifies the
minimum page allocation order to be injected failures.Signed-off-by: Akinobu Mita
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
09 Dec, 2006
4 commits
-
Correct, disambiguate, and reformat documentation.
Signed-off-by: Don Mullis
Cc: Akinobu Mita
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch provides stacktrace filtering feature.
The stacktrace filter allows failing only for the caller you are
interested in.For example someone may want to inject kmalloc() failures into
only e100 module. they want to inject not only direct kmalloc() call,
but also indirect allocation, too.- e100_poll --> netif_receive_skb --> packet_rcv_spkt --> skb_clone
--> kmem_cache_allocThis patch enables to detect function calls like this by stacktrace
and inject failures. The script Documentaion/fault-injection/failmodule.sh
helps it.The range of text section of loaded e100 is expected to be
[/sys/module/e100/sections/.text, /sys/module/e100/sections/.exit.text)So failmodule.sh stores these values into /debug/failslab/address-start
and /debug/failslab/address-end. The maximum stacktrace depth is specified
by /debug/failslab/stacktrace-depth.Please see the example that demonstrates how to inject slab allocation
failures only for a specific module
in Documentation/fault-injection/fault-injection.txt[dwm@meer.net: reject failure if any caller lies within specified range]
Signed-off-by: Akinobu Mita
Signed-off-by: Don Mullis
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch provides fault-injection capability for kmalloc.
Boot option:
failslab=,,,
-- specifies the interval of failures.
-- specifies how often it should fail in percent.
-- specifies the size of free space where memory can be
allocated safely in bytes.-- specifies how many times failures may happen at most.
Debugfs:
/debug/failslab/interval
/debug/failslab/probability
/debug/failslab/specifies
/debug/failslab/times
/debug/failslab/ignore-gfp-highmem
/debug/failslab/ignore-gfp-waitExample:
failslab=10,100,0,-1
slab allocation (kmalloc(), kmem_cache_alloc(),..) fails once per 10 times.
Cc: Pekka Enberg
Signed-off-by: Akinobu Mita
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch set provides some fault-injection capabilities.
- kmalloc() failures
- alloc_pages() failures
- disk IO errors
We can see what really happens if those failures happen.
In order to enable these fault-injection capabilities:
1. Enable relevant config options (CONFIG_FAILSLAB, CONFIG_PAGE_ALLOC,
CONFIG_MAKE_REQUEST) and if you want to configure them via debugfs,
enable CONFIG_FAULT_INJECTION_DEBUG_FS.2. Build and boot with this kernel
3. Configure fault-injection capabilities behavior by boot option or debugfs
- Boot option
failslab=
fail_page_alloc=
fail_make_request=- Debugfs
/debug/failslab/*
/debug/fail_page_alloc/*
/debug/fail_make_request/*Please refer to the Documentation/fault-injection/fault-injection.txt
for details.4. See what really happens.
Signed-off-by: Akinobu Mita
Signed-off-by: Don Mullis
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds