diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c index c2ebf5084977bafaa2566e4e010040d8ed2b7f47..08597c52443911cc436a8415cbc8e9d4a03a8d26 100644 --- a/fs/pstore/ram.c +++ b/fs/pstore/ram.c @@ -623,7 +623,13 @@ static int ramoops_probe(struct platform_device *pdev) goto fail_clear; } - cxt->pstore.flags = PSTORE_FLAGS_ALL; + cxt->pstore.flags = PSTORE_FLAGS_DMESG; + if (cxt->console_size) + cxt->pstore.flags |= PSTORE_FLAGS_CONSOLE; + if (cxt->ftrace_size) + cxt->pstore.flags |= PSTORE_FLAGS_FTRACE; + if (cxt->pmsg_size) + cxt->pstore.flags |= PSTORE_FLAGS_PMSG; err = pstore_register(&cxt->pstore); if (err) { diff --git a/include/linux/pstore.h b/include/linux/pstore.h index f5806b2a6f7a440870c913111d305d0788e5c192..50d475228d979d8a9ac341cd69e01de6b39f8394 100644 --- a/include/linux/pstore.h +++ b/include/linux/pstore.h @@ -80,8 +80,6 @@ struct pstore_info { #define PSTORE_FLAGS_FTRACE (1 << 2) #define PSTORE_FLAGS_PMSG (1 << 3) -#define PSTORE_FLAGS_ALL ((1 << 4) - 1) - extern int pstore_register(struct pstore_info *); extern void pstore_unregister(struct pstore_info *); extern bool pstore_cannot_block_path(enum kmsg_dump_reason reason);