Skip to content

Commit

Permalink
UBI: dump stack when switching to R/O mode
Browse files Browse the repository at this point in the history
If we have debugging enabled and switching to R/O mode because of an error -
dump the stack to improve UBI error reporting and make the further diagnostics
easier to do.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
  • Loading branch information
Artem Bityutskiy authored and Artem Bityutskiy committed Jun 1, 2011
1 parent 01a4110 commit 2a82606
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/mtd/ubi/ubi.h
Original file line number Diff line number Diff line change
Expand Up @@ -667,6 +667,7 @@ static inline void ubi_ro_mode(struct ubi_device *ubi)
if (!ubi->ro_mode) {
ubi->ro_mode = 1;
ubi_warn("switch to read-only mode");
ubi_dbg_dump_stack();
}
}

Expand Down

0 comments on commit 2a82606

Please sign in to comment.