summaryrefslogtreecommitdiff
path: root/kernel/printk.c
diff options
context:
space:
mode:
authorMike Galbraith <efault@gmx.de>2006-12-06 20:37:42 -0800
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-07 08:39:38 -0800
commitc36264dfb2d6fa6383082de0a1bba8e12b477da1 (patch)
tree25efc8365544d12974f0633ad46f619bfbf087e1 /kernel/printk.c
parent44ddc4f5673a62c9ecdbb7b502fe7b8206b0f945 (diff)
[PATCH] remove the syslog interface when printk is disabled
Attempts to read() from the non-existent dmesg buffer will return zero and userspace tends to get stuck in a busyloop. So just remove /dev/kmsg altogether if CONFIG_PRINTK=n. Signed-off-by: Mike Galbraith <efault@gmx.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/printk.c')
-rw-r--r--kernel/printk.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/kernel/printk.c b/kernel/printk.c
index 66426552fbfe..ba59c2a30ed0 100644
--- a/kernel/printk.c
+++ b/kernel/printk.c
@@ -631,12 +631,7 @@ EXPORT_SYMBOL(vprintk);
asmlinkage long sys_syslog(int type, char __user *buf, int len)
{
- return 0;
-}
-
-int do_syslog(int type, char __user *buf, int len)
-{
- return 0;
+ return -ENOSYS;
}
static void call_console_drivers(unsigned long start, unsigned long end)