aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kmsg_dump.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/kmsg_dump.h')
-rw-r--r--include/linux/kmsg_dump.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/linux/kmsg_dump.h b/include/linux/kmsg_dump.h
index 7f089ec5ef32..e32aa268efac 100644
--- a/include/linux/kmsg_dump.h
+++ b/include/linux/kmsg_dump.h
@@ -35,10 +35,26 @@ struct kmsg_dumper {
35 int registered; 35 int registered;
36}; 36};
37 37
38#ifdef CONFIG_PRINTK
38void kmsg_dump(enum kmsg_dump_reason reason); 39void kmsg_dump(enum kmsg_dump_reason reason);
39 40
40int kmsg_dump_register(struct kmsg_dumper *dumper); 41int kmsg_dump_register(struct kmsg_dumper *dumper);
41 42
42int kmsg_dump_unregister(struct kmsg_dumper *dumper); 43int kmsg_dump_unregister(struct kmsg_dumper *dumper);
44#else
45static inline void kmsg_dump(enum kmsg_dump_reason reason)
46{
47}
48
49static inline int kmsg_dump_register(struct kmsg_dumper *dumper)
50{
51 return -EINVAL;
52}
53
54static inline int kmsg_dump_unregister(struct kmsg_dumper *dumper)
55{
56 return -EINVAL;
57}
58#endif
43 59
44#endif /* _LINUX_KMSG_DUMP_H */ 60#endif /* _LINUX_KMSG_DUMP_H */