summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2019-07-08 09:47:09 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2019-07-09 10:20:28 +0200
commit297ac72881b89d34f7940020319fd3e2a68fbe67 (patch)
tree542d39ba08f524475b55d06385d84522456f3a45 /include/linux
parenta34fd3272a88101483f74a608b07db4312a64015 (diff)
downloadbarebox-297ac72881b89d34f7940020319fd3e2a68fbe67.tar.gz
barebox-297ac72881b89d34f7940020319fd3e2a68fbe67.tar.xz
pstore: Only capture log messages
With this pstore only captures barebox log messages printed with pr_* and dev_*, but no longer anything printed with printf and friends. When capturing the barebox output with pstore only the log messages are of interest, but not the ones printed with printf and certainly not the things typed interactively on the command line. These are logged currently because we register pstore as a barebox console. Instead, hook into pr_puts which only outputs the barebox log messages. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/pstore.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/pstore.h b/include/linux/pstore.h
index 15e1e3d6fa..dabb639111 100644
--- a/include/linux/pstore.h
+++ b/include/linux/pstore.h
@@ -85,6 +85,7 @@ struct pstore_info {
#ifdef CONFIG_FS_PSTORE
extern int pstore_register(struct pstore_info *);
extern bool pstore_cannot_block_path(enum kmsg_dump_reason reason);
+extern void pstore_log(const char *msg);
#else
static inline int
pstore_register(struct pstore_info *psi)
@@ -96,6 +97,9 @@ pstore_cannot_block_path(enum kmsg_dump_reason reason)
{
return false;
}
+static inline void pstore_log(const char *msg)
+{
+}
#endif
#endif /*_LINUX_PSTORE_H*/