aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial/sunsab.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/serial/sunsab.c')
-rw-r--r--drivers/serial/sunsab.c22
1 files changed, 5 insertions, 17 deletions
diff --git a/drivers/serial/sunsab.c b/drivers/serial/sunsab.c
index 8a0f9e4408d4..bca57bb94939 100644
--- a/drivers/serial/sunsab.c
+++ b/drivers/serial/sunsab.c
@@ -968,22 +968,6 @@ static struct console sunsab_console = {
968 968
969static inline struct console *SUNSAB_CONSOLE(void) 969static inline struct console *SUNSAB_CONSOLE(void)
970{ 970{
971 int i;
972
973 if (con_is_present())
974 return NULL;
975
976 for (i = 0; i < num_channels; i++) {
977 int this_minor = sunsab_reg.minor + i;
978
979 if ((this_minor - 64) == (serial_console - 1))
980 break;
981 }
982 if (i == num_channels)
983 return NULL;
984
985 sunsab_console.index = i;
986
987 return &sunsab_console; 971 return &sunsab_console;
988} 972}
989#else 973#else
@@ -1080,7 +1064,12 @@ static int __devinit sab_probe(struct of_device *op, const struct of_device_id *
1080 return err; 1064 return err;
1081 } 1065 }
1082 1066
1067 sunserial_console_match(SUNSAB_CONSOLE(), op->node,
1068 &sunsab_reg, up[0].port.line);
1083 uart_add_one_port(&sunsab_reg, &up[0].port); 1069 uart_add_one_port(&sunsab_reg, &up[0].port);
1070
1071 sunserial_console_match(SUNSAB_CONSOLE(), op->node,
1072 &sunsab_reg, up[1].port.line);
1084 uart_add_one_port(&sunsab_reg, &up[1].port); 1073 uart_add_one_port(&sunsab_reg, &up[1].port);
1085 1074
1086 dev_set_drvdata(&op->dev, &up[0]); 1075 dev_set_drvdata(&op->dev, &up[0]);
@@ -1164,7 +1153,6 @@ static int __init sunsab_init(void)
1164 } 1153 }
1165 1154
1166 sunsab_reg.tty_driver->name_base = sunsab_reg.minor - 64; 1155 sunsab_reg.tty_driver->name_base = sunsab_reg.minor - 64;
1167 sunsab_reg.cons = SUNSAB_CONSOLE();
1168 sunserial_current_minor += num_channels; 1156 sunserial_current_minor += num_channels;
1169 } 1157 }
1170 1158