projects/linux·commit 8ccf863f

Merge tag 'please-pull-pstore' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux

8ccf863f · Linus Torvalds <[email protected]> · 2014-10-18 13:25:03 -07:00

Pull pstore fix from Tony Luck:
 "Ensure unique filenames in pstore"

* tag 'please-pull-pstore' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux:
  pstore: Fix duplicate {console,ftrace}-efi entries
Commit
8ccf863f09bbff209b124cbd90644c0b75b8fefd
Parents
4869447d · d4bf205d

Merge commit. Changes below are compared with the first parent: 4869447d.

Changes

1 files changed · +2 −2

FileStatusAddDelContent
fs/pstore/inode.cmodified+2−2View file

fs/pstore/inode.c

View file
diff --git a/fs/pstore/inode.c b/fs/pstore/inode.c
index 192297b..fafb7a0 100644
--- a/fs/pstore/inode.c
+++ b/fs/pstore/inode.c
@@ -320,10 +320,10 @@ int pstore_mkfile(enum pstore_type_id type, char *psname, u64 id, int count,
compressed ? ".enc.z" : "");
break;
case PSTORE_TYPE_CONSOLE:
- sprintf(name, "console-%s", psname);
+ sprintf(name, "console-%s-%lld", psname, id);
break;
case PSTORE_TYPE_FTRACE:
- sprintf(name, "ftrace-%s", psname);
+ sprintf(name, "ftrace-%s-%lld", psname, id);
break;
case PSTORE_TYPE_MCE:
sprintf(name, "mce-%s-%lld", psname, id);