projects
/
cascardo
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'printk-cleanups'
[cascardo/linux.git]
/
kernel
/
printk
/
printk.c
diff --git
a/kernel/printk/printk.c
b/kernel/printk/printk.c
index
170d3a8
..
d5e3973
100644
(file)
--- a/
kernel/printk/printk.c
+++ b/
kernel/printk/printk.c
@@
-253,6
+253,17
@@
static int preferred_console = -1;
int console_set_on_cmdline;
EXPORT_SYMBOL(console_set_on_cmdline);
int console_set_on_cmdline;
EXPORT_SYMBOL(console_set_on_cmdline);
+#ifdef CONFIG_OF
+static bool of_specified_console;
+
+void console_set_by_of(void)
+{
+ of_specified_console = true;
+}
+#else
+# define of_specified_console false
+#endif
+
/* Flag: console code may call schedule() */
static int console_may_schedule;
/* Flag: console code may call schedule() */
static int console_may_schedule;
@@
-2642,7
+2653,7
@@
void register_console(struct console *newcon)
* didn't select a console we take the first one
* that registers here.
*/
* didn't select a console we take the first one
* that registers here.
*/
- if (preferred_console < 0) {
+ if (preferred_console < 0
&& !of_specified_console
) {
if (newcon->index < 0)
newcon->index = 0;
if (newcon->setup == NULL ||
if (newcon->index < 0)
newcon->index = 0;
if (newcon->setup == NULL ||