aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/printk/console_cmdline.h14
-rw-r--r--kernel/printk/printk.c12
2 files changed, 17 insertions, 9 deletions
diff --git a/kernel/printk/console_cmdline.h b/kernel/printk/console_cmdline.h
new file mode 100644
index 000000000000..cbd69d842341
--- /dev/null
+++ b/kernel/printk/console_cmdline.h
@@ -0,0 +1,14 @@
1#ifndef _CONSOLE_CMDLINE_H
2#define _CONSOLE_CMDLINE_H
3
4struct console_cmdline
5{
6 char name[8]; /* Name of the driver */
7 int index; /* Minor dev. to use */
8 char *options; /* Options for the driver */
9#ifdef CONFIG_A11Y_BRAILLE_CONSOLE
10 char *brl_options; /* Options for braille driver */
11#endif
12};
13
14#endif
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c
index 69b0890ed7e5..4da2b2c7f67d 100644
--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
@@ -51,6 +51,8 @@
51#define CREATE_TRACE_POINTS 51#define CREATE_TRACE_POINTS
52#include <trace/events/printk.h> 52#include <trace/events/printk.h>
53 53
54#include "console_cmdline.h"
55
54/* printk's without a loglevel use this.. */ 56/* printk's without a loglevel use this.. */
55#define DEFAULT_MESSAGE_LOGLEVEL CONFIG_DEFAULT_MESSAGE_LOGLEVEL 57#define DEFAULT_MESSAGE_LOGLEVEL CONFIG_DEFAULT_MESSAGE_LOGLEVEL
56 58
@@ -105,19 +107,11 @@ static struct console *exclusive_console;
105/* 107/*
106 * Array of consoles built from command line options (console=) 108 * Array of consoles built from command line options (console=)
107 */ 109 */
108struct console_cmdline
109{
110 char name[8]; /* Name of the driver */
111 int index; /* Minor dev. to use */
112 char *options; /* Options for the driver */
113#ifdef CONFIG_A11Y_BRAILLE_CONSOLE
114 char *brl_options; /* Options for braille driver */
115#endif
116};
117 110
118#define MAX_CMDLINECONSOLES 8 111#define MAX_CMDLINECONSOLES 8
119 112
120static struct console_cmdline console_cmdline[MAX_CMDLINECONSOLES]; 113static struct console_cmdline console_cmdline[MAX_CMDLINECONSOLES];
114
121static int selected_console = -1; 115static int selected_console = -1;
122static int preferred_console = -1; 116static int preferred_console = -1;
123int console_set_on_cmdline; 117int console_set_on_cmdline;