Skip to content

Commit 8b24ef4

Browse files
committed
Merge tag 'pstore-v5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux
Pull pstore fixes from Kees Cook: - Rate-limit ECC warnings (Dmitry Osipenko) - Fix error path check for NULL (Tetsuo Handa) * tag 'pstore-v5.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux: pstore/ram: Rate-limit "uncorrectable error in header" message pstore: Fix warning in pstore_kill_sb()
2 parents 63dcd69 + 7db688e commit 8b24ef4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

fs/pstore/inode.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,7 @@ static struct dentry *pstore_mount(struct file_system_type *fs_type,
467467
static void pstore_kill_sb(struct super_block *sb)
468468
{
469469
mutex_lock(&pstore_sb_lock);
470-
WARN_ON(pstore_sb != sb);
470+
WARN_ON(pstore_sb && pstore_sb != sb);
471471

472472
kill_litter_super(sb);
473473
pstore_sb = NULL;

fs/pstore/ram_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ static int persistent_ram_init_ecc(struct persistent_ram_zone *prz,
246246
pr_info("error in header, %d\n", numerr);
247247
prz->corrected_bytes += numerr;
248248
} else if (numerr < 0) {
249-
pr_info("uncorrectable error in header\n");
249+
pr_info_ratelimited("uncorrectable error in header\n");
250250
prz->bad_blocks++;
251251
}
252252

0 commit comments

Comments
 (0)