[PATCH] fault-injection: defaults likely to please a new user
authorDon Mullis <dwm@meer.net>
Fri, 8 Dec 2006 10:39:53 +0000 (02:39 -0800)
committerLinus Torvalds <torvalds@woody.osdl.org>
Fri, 8 Dec 2006 16:29:03 +0000 (08:29 -0800)
Assign defaults most likely to please a new user:
 1) generate some logging output
    (verbose=2)
 2) avoid injecting failures likely to lock up UI
    (ignore_gfp_wait=1, ignore_gfp_highmem=1)

Signed-off-by: Don Mullis <dwm@meer.net>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
include/linux/fault-inject.h
mm/page_alloc.c
mm/slab.c

index c77067916b7e3639485ad861d0c2fb274a2cc1c8..32368c4f032644bd9b501cc60db32c14843fb2bb 100644 (file)
@@ -52,6 +52,7 @@ struct fault_attr {
                .times = ATOMIC_INIT(1),                        \
                .require_end = ULONG_MAX,                       \
                .stacktrace_depth = 32,                         \
+               .verbose = 2,                                   \
        }
 
 #define DECLARE_FAULT_ATTR(name) struct fault_attr name = FAULT_ATTR_INITIALIZER
index 0cc8b4376e91795c20147cf310c7ef9d014a4f8e..e6b17b2989e099636dcb1ec64587f130b8ad27c0 100644 (file)
@@ -910,6 +910,8 @@ static struct fail_page_alloc_attr {
 
 } fail_page_alloc = {
        .attr = FAULT_ATTR_INITIALIZER,
+       .ignore_gfp_wait = 1,
+       .ignore_gfp_highmem = 1,
 };
 
 static int __init setup_fail_page_alloc(char *str)
index 47011e2ef3c9216bba4e9a249e9e48070a131fba..56af694c9e6a386f75aa718f339a54eef6e27b8d 100644 (file)
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -3102,6 +3102,7 @@ static struct failslab_attr {
 
 } failslab = {
        .attr = FAULT_ATTR_INITIALIZER,
+       .ignore_gfp_wait = 1,
 };
 
 static int __init setup_failslab(char *str)