diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-06-20 17:41:57 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-06-20 17:41:57 -0400 |
commit | a2a2609c97c1e21996b9d87d10d2c9ff07277524 (patch) | |
tree | c9db50783d6727f95d2a6b4c019c2d66952969d9 /lib | |
parent | a4d7a122385e27bdd91101635c704327d7c0d87f (diff) | |
parent | 48c3b583bbddad2220ca4c22319ca5d1f78b2090 (diff) |
Merge branch 'akpm' (Andrew's patch-bomb)
* emailed from Andrew Morton <akpm@linux-foundation.org>: (21 patches)
mm/memblock: fix overlapping allocation when doubling reserved array
c/r: prctl: Move PR_GET_TID_ADDRESS to a proper place
pidns: find_new_reaper() can no longer switch to init_pid_ns.child_reaper
pidns: guarantee that the pidns init will be the last pidns process reaped
fault-inject: avoid call to random32() if fault injection is disabled
Viresh has moved
get_maintainer: Fix --help warning
mm/memory.c: fix kernel-doc warnings
mm: fix kernel-doc warnings
mm: correctly synchronize rss-counters at exit/exec
mm, thp: print useful information when mmap_sem is unlocked in zap_pmd_range
h8300: use the declarations provided by <asm/sections.h>
h8300: fix use of extinct _sbss and _ebss
xtensa: use the declarations provided by <asm/sections.h>
xtensa: use "test -e" instead of bashism "test -a"
xtensa: replace xtensa-specific _f{data,text} by _s{data,text}
memcg: fix use_hierarchy css_is_ancestor oops regression
mm, oom: fix and cleanup oom score calculations
nilfs2: ensure proper cache clearing for gc-inodes
thp: avoid atomic64_read in pmd_read_atomic for 32bit PAE
...
Diffstat (limited to 'lib')
-rw-r--r-- | lib/fault-inject.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/fault-inject.c b/lib/fault-inject.c index 6805453c18e7..f7210ad6cffd 100644 --- a/lib/fault-inject.c +++ b/lib/fault-inject.c | |||
@@ -101,6 +101,10 @@ static inline bool fail_stacktrace(struct fault_attr *attr) | |||
101 | 101 | ||
102 | bool should_fail(struct fault_attr *attr, ssize_t size) | 102 | bool should_fail(struct fault_attr *attr, ssize_t size) |
103 | { | 103 | { |
104 | /* No need to check any other properties if the probability is 0 */ | ||
105 | if (attr->probability == 0) | ||
106 | return false; | ||
107 | |||
104 | if (attr->task_filter && !fail_task(attr, current)) | 108 | if (attr->task_filter && !fail_task(attr, current)) |
105 | return false; | 109 | return false; |
106 | 110 | ||