[PATCH 03/30] UBIFS: dump stack when pnode or nnode reading fails
Artem Bityutskiy
dedekind1 at gmail.com
Thu Jun 9 05:04:43 EDT 2011
From: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
When we fail to read a pnode or nnode - print stacktrace if debugging is enabled.
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
---
fs/ubifs/lpt.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/fs/ubifs/lpt.c b/fs/ubifs/lpt.c
index ef5155e..04713cd 100644
--- a/fs/ubifs/lpt.c
+++ b/fs/ubifs/lpt.c
@@ -1247,6 +1247,7 @@ int ubifs_read_nnode(struct ubifs_info *c, struct ubifs_nnode *parent, int iip)
out:
ubifs_err("error %d reading nnode at %d:%d", err, lnum, offs);
+ dbg_dump_stack();
kfree(nnode);
return err;
}
@@ -1312,6 +1313,7 @@ static int read_pnode(struct ubifs_info *c, struct ubifs_nnode *parent, int iip)
out:
ubifs_err("error %d reading pnode at %d:%d", err, lnum, offs);
dbg_dump_pnode(c, pnode, parent, iip);
+ dbg_dump_stack();
dbg_msg("calc num: %d", calc_pnode_num_from_parent(c, parent, iip));
kfree(pnode);
return err;
--
1.7.2.3
More information about the linux-mtd
mailing list