diff options
author | Andrew Morton <akpm@osdl.org> | 2007-02-10 01:45:51 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-11 10:51:31 -0800 |
commit | 100bb9349ea5cb4e667977de55bd6dc4ac7bc22f (patch) | |
tree | d5b4e61daf0c35d745846818bb89b6b7b9d2f283 | |
parent | cb799b8988e40a7871ae8e976248c33c562e3555 (diff) |
[PATCH] proc_misc warning fix
fs/proc/proc_misc.c: In function 'proc_misc_init':
fs/proc/proc_misc.c:764: warning: unused variable 'entry'
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | fs/proc/proc_misc.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c index 1d5b4fb2c72..5e2d4359c29 100644 --- a/fs/proc/proc_misc.c +++ b/fs/proc/proc_misc.c @@ -667,7 +667,6 @@ void create_seq_entry(char *name, mode_t mode, const struct file_operations *f) void __init proc_misc_init(void) { - struct proc_dir_entry *entry; static struct { char *name; int (*read_proc)(char*,char**,off_t,int,int*,void*); @@ -695,9 +694,12 @@ void __init proc_misc_init(void) /* And now for trickier ones */ #ifdef CONFIG_PRINTK - entry = create_proc_entry("kmsg", S_IRUSR, &proc_root); - if (entry) - entry->proc_fops = &proc_kmsg_operations; + { + struct proc_dir_entry *entry; + entry = create_proc_entry("kmsg", S_IRUSR, &proc_root); + if (entry) + entry->proc_fops = &proc_kmsg_operations; + } #endif create_seq_entry("devices", 0, &proc_devinfo_operations); create_seq_entry("cpuinfo", 0, &proc_cpuinfo_operations); @@ -738,8 +740,11 @@ void __init proc_misc_init(void) proc_vmcore->proc_fops = &proc_vmcore_operations; #endif #ifdef CONFIG_MAGIC_SYSRQ - entry = create_proc_entry("sysrq-trigger", S_IWUSR, NULL); - if (entry) - entry->proc_fops = &proc_sysrq_trigger_operations; + { + struct proc_dir_entry *entry; + entry = create_proc_entry("sysrq-trigger", S_IWUSR, NULL); + if (entry) + entry->proc_fops = &proc_sysrq_trigger_operations; + } #endif } |