aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ubifs/debug.h
diff options
context:
space:
mode:
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2011-06-03 08:10:33 -0400
committerArtem Bityutskiy <dedekind1@gmail.com>2011-07-04 03:54:34 -0400
commitd27462a518c31a4b1093ad866229f85b2b765e7e (patch)
treee2663f6294ad516bc3debebf394fc437a84d0de5 /fs/ubifs/debug.h
parentf57cb188ccd9c0242111d99b7283eda7827746c4 (diff)
UBIFS: rename recovery testing variables
Since the recovery testing is effectively about emulating power cuts by UBIFS, use "power cut" as the base term for all the related variables and name them correspondingly. This is just a minor clean-up for the sake of readability. Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'fs/ubifs/debug.h')
-rw-r--r--fs/ubifs/debug.h22
1 files changed, 11 insertions, 11 deletions
diff --git a/fs/ubifs/debug.h b/fs/ubifs/debug.h
index 0ab3757ef0e3..45174b534377 100644
--- a/fs/ubifs/debug.h
+++ b/fs/ubifs/debug.h
@@ -44,11 +44,11 @@ typedef int (*dbg_znode_callback)(struct ubifs_info *c,
44 * @old_zroot_level: old index root level - used by 'dbg_check_old_index()' 44 * @old_zroot_level: old index root level - used by 'dbg_check_old_index()'
45 * @old_zroot_sqnum: old index root sqnum - used by 'dbg_check_old_index()' 45 * @old_zroot_sqnum: old index root sqnum - used by 'dbg_check_old_index()'
46 * 46 *
47 * @failure_mode: failure mode for recovery testing 47 * @pc_happened: non-zero if an emulated power cut happened
48 * @fail_delay: 0=>don't delay, 1=>delay a time, 2=>delay a number of calls 48 * @pc_delay: 0=>don't delay, 1=>delay a time, 2=>delay a number of calls
49 * @fail_timeout: time in jiffies when delay of failure mode expires 49 * @pc_timeout: time in jiffies when delay of failure mode expires
50 * @fail_cnt: current number of calls to failure mode I/O functions 50 * @pc_cnt: current number of calls to failure mode I/O functions
51 * @fail_cnt_max: number of calls by which to delay failure mode 51 * @pc_cnt_max: number of calls by which to delay failure mode
52 * 52 *
53 * @chk_lpt_sz: used by LPT tree size checker 53 * @chk_lpt_sz: used by LPT tree size checker
54 * @chk_lpt_sz2: used by LPT tree size checker 54 * @chk_lpt_sz2: used by LPT tree size checker
@@ -87,11 +87,11 @@ struct ubifs_debug_info {
87 int old_zroot_level; 87 int old_zroot_level;
88 unsigned long long old_zroot_sqnum; 88 unsigned long long old_zroot_sqnum;
89 89
90 int failure_mode; 90 int pc_happened;
91 int fail_delay; 91 int pc_delay;
92 unsigned long fail_timeout; 92 unsigned long pc_timeout;
93 unsigned int fail_cnt; 93 unsigned int pc_cnt;
94 unsigned int fail_cnt_max; 94 unsigned int pc_cnt_max;
95 95
96 long long chk_lpt_sz; 96 long long chk_lpt_sz;
97 long long chk_lpt_sz2; 97 long long chk_lpt_sz2;
@@ -246,7 +246,7 @@ static inline int dbg_is_tst_rcvry(const struct ubifs_info *c)
246} 246}
247static inline int dbg_is_power_cut(const struct ubifs_info *c) 247static inline int dbg_is_power_cut(const struct ubifs_info *c)
248{ 248{
249 return !!c->dbg->failure_mode; 249 return !!c->dbg->pc_happened;
250} 250}
251 251
252int ubifs_debugging_init(struct ubifs_info *c); 252int ubifs_debugging_init(struct ubifs_info *c);