diff options
Diffstat (limited to 'kernel/printk/printk.c')
-rw-r--r-- | kernel/printk/printk.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index fd63b4d06139..6613e3437b91 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c @@ -497,7 +497,7 @@ static int syslog_action_restricted(int type) type != SYSLOG_ACTION_SIZE_BUFFER; } -int check_syslog_permissions(int type, int source) +static int check_syslog_permissions(int type, int source) { /* * If this is from /proc/kmsg and we've already opened it, then we've @@ -525,7 +525,6 @@ int check_syslog_permissions(int type, int source) ok: return security_syslog(type); } -EXPORT_SYMBOL_GPL(check_syslog_permissions); static void append_char(char **pp, char *e, char c) { @@ -2040,6 +2039,16 @@ static int __init console_setup(char *str) char *s, *options, *brl_options = NULL; int idx; + /* + * console="" or console=null have been suggested as a way to + * disable console output. Use ttynull that has been created + * for exacly this purpose. + */ + if (str[0] == 0 || strcmp(str, "null") == 0) { + __add_preferred_console("ttynull", 0, NULL, NULL); + return 1; + } + if (_braille_console_setup(&str, &brl_options)) return 1; |