diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c index 67bdbd3da52e5b5110143607df94d3ccdeed3ece..f20ccdeb6b59cce9a19d5163505ec8fca18a41f6 100644 --- a/fs/pstore/ram.c +++ b/fs/pstore/ram.c @@ -299,6 +299,7 @@ static ssize_t ramoops_pstore_read(struct pstore_record *record) GFP_KERNEL); if (!tmp_prz) return -ENOMEM; + prz = tmp_prz; free_prz = true; while (cxt->ftrace_read_cnt < cxt->max_ftrace_cnt) { @@ -321,7 +322,6 @@ static ssize_t ramoops_pstore_read(struct pstore_record *record) goto out; } record->id = 0; - prz = tmp_prz; } }