aboutsummaryrefslogtreecommitdiffstats
path: root/fs/proc/kmsg.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/proc/kmsg.c')
-rw-r--r--fs/proc/kmsg.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/fs/proc/kmsg.c b/fs/proc/kmsg.c
index 9fd5df3f40ce..7ca78346d3f0 100644
--- a/fs/proc/kmsg.c
+++ b/fs/proc/kmsg.c
@@ -10,13 +10,12 @@
10#include <linux/time.h> 10#include <linux/time.h>
11#include <linux/kernel.h> 11#include <linux/kernel.h>
12#include <linux/poll.h> 12#include <linux/poll.h>
13#include <linux/proc_fs.h>
13#include <linux/fs.h> 14#include <linux/fs.h>
14 15
15#include <asm/uaccess.h> 16#include <asm/uaccess.h>
16#include <asm/io.h> 17#include <asm/io.h>
17 18
18#include "internal.h"
19
20extern wait_queue_head_t log_wait; 19extern wait_queue_head_t log_wait;
21 20
22extern int do_syslog(int type, char __user *bug, int count); 21extern int do_syslog(int type, char __user *bug, int count);
@@ -49,9 +48,16 @@ static unsigned int kmsg_poll(struct file *file, poll_table *wait)
49} 48}
50 49
51 50
52const struct file_operations proc_kmsg_operations = { 51static const struct file_operations proc_kmsg_operations = {
53 .read = kmsg_read, 52 .read = kmsg_read,
54 .poll = kmsg_poll, 53 .poll = kmsg_poll,
55 .open = kmsg_open, 54 .open = kmsg_open,
56 .release = kmsg_release, 55 .release = kmsg_release,
57}; 56};
57
58static int __init proc_kmsg_init(void)
59{
60 proc_create("kmsg", S_IRUSR, NULL, &proc_kmsg_operations);
61 return 0;
62}
63module_init(proc_kmsg_init);