diff options
author | Arve Hjønnevåg <arve@android.com> | 2012-12-05 21:19:51 -0800 |
---|---|---|
committer | Anton Vorontsov <anton@enomsg.org> | 2013-04-03 21:50:10 -0700 |
commit | bd08ec33b5c23833581e5a36b2a69ccae6b39a28 (patch) | |
tree | 36da2618929a667d13b1a9408c2e9427cf32456c /fs/pstore/ram_core.c | |
parent | c31ad081e8734aab3fb45d2f32e9969994dd076e (diff) |
pstore/ram: Restore ecc information block
This was lost when proc/last_kmsg moved to pstore/console-ramoops.
Signed-off-by: Arve Hjønnevåg <arve@android.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Acked-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Anton Vorontsov <anton@enomsg.org>
Diffstat (limited to 'fs/pstore/ram_core.c')
-rw-r--r-- | fs/pstore/ram_core.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/pstore/ram_core.c b/fs/pstore/ram_core.c index c6f641c1017..59337326e28 100644 --- a/fs/pstore/ram_core.c +++ b/fs/pstore/ram_core.c @@ -235,6 +235,9 @@ ssize_t persistent_ram_ecc_string(struct persistent_ram_zone *prz, { ssize_t ret; + if (!prz->ecc_info.ecc_size) + return 0; + if (prz->corrected_bytes || prz->bad_blocks) ret = snprintf(str, len, "" "\n%d Corrected bytes, %d unrecoverable blocks\n", |