aboutsummaryrefslogtreecommitdiff
path: root/fs/pstore
diff options
context:
space:
mode:
authorPetr Mladek2021-04-27 14:32:09 +0200
committerPetr Mladek2021-04-27 14:32:09 +0200
commitc8dbea6df351df211216b5f8877b020f21ecf75f (patch)
tree85e752c1543e08ec217eb901379d56ce31213d20 /fs/pstore
parentda34b03fbd0a6e58770d5fe00830674633a57d60 (diff)
parentacebb5597ff182e52a225400a459052a70dae706 (diff)
Merge branch 'printk-rework' into for-linus
Diffstat (limited to 'fs/pstore')
-rw-r--r--fs/pstore/platform.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/pstore/platform.c b/fs/pstore/platform.c
index d963ae7902f9..b9614db48b1d 100644
--- a/fs/pstore/platform.c
+++ b/fs/pstore/platform.c
@@ -385,6 +385,7 @@ void pstore_record_init(struct pstore_record *record,
static void pstore_dump(struct kmsg_dumper *dumper,
enum kmsg_dump_reason reason)
{
+ struct kmsg_dump_iter iter;
unsigned long total = 0;
const char *why;
unsigned int part = 1;
@@ -405,6 +406,8 @@ static void pstore_dump(struct kmsg_dumper *dumper,
}
}
+ kmsg_dump_rewind(&iter);
+
oopscount++;
while (total < kmsg_bytes) {
char *dst;
@@ -435,7 +438,7 @@ static void pstore_dump(struct kmsg_dumper *dumper,
dst_size -= header_size;
/* Write dump contents. */
- if (!kmsg_dump_get_buffer(dumper, true, dst + header_size,
+ if (!kmsg_dump_get_buffer(&iter, true, dst + header_size,
dst_size, &dump_size))
break;