diff options
Diffstat (limited to 'arch/m68k/atari/debug.c')
-rw-r--r-- | arch/m68k/atari/debug.c | 37 |
1 files changed, 7 insertions, 30 deletions
diff --git a/arch/m68k/atari/debug.c b/arch/m68k/atari/debug.c index 043ddbc61c7b..702b15ccfab7 100644 --- a/arch/m68k/atari/debug.c +++ b/arch/m68k/atari/debug.c | |||
@@ -20,14 +20,6 @@ | |||
20 | #include <asm/atarihw.h> | 20 | #include <asm/atarihw.h> |
21 | #include <asm/atariints.h> | 21 | #include <asm/atariints.h> |
22 | 22 | ||
23 | /* Flag that Modem1 port is already initialized and used */ | ||
24 | int atari_MFP_init_done; | ||
25 | EXPORT_SYMBOL(atari_MFP_init_done); | ||
26 | |||
27 | /* Flag that Modem1 port is already initialized and used */ | ||
28 | int atari_SCC_init_done; | ||
29 | EXPORT_SYMBOL(atari_SCC_init_done); | ||
30 | |||
31 | /* Can be set somewhere, if a SCC master reset has already be done and should | 23 | /* Can be set somewhere, if a SCC master reset has already be done and should |
32 | * not be repeated; used by kgdb */ | 24 | * not be repeated; used by kgdb */ |
33 | int atari_SCC_reset_done; | 25 | int atari_SCC_reset_done; |
@@ -47,8 +39,8 @@ static inline void ata_mfp_out(char c) | |||
47 | mfp.usart_dta = c; | 39 | mfp.usart_dta = c; |
48 | } | 40 | } |
49 | 41 | ||
50 | void atari_mfp_console_write(struct console *co, const char *str, | 42 | static void atari_mfp_console_write(struct console *co, const char *str, |
51 | unsigned int count) | 43 | unsigned int count) |
52 | { | 44 | { |
53 | while (count--) { | 45 | while (count--) { |
54 | if (*str == '\n') | 46 | if (*str == '\n') |
@@ -66,8 +58,8 @@ static inline void ata_scc_out(char c) | |||
66 | scc.cha_b_data = c; | 58 | scc.cha_b_data = c; |
67 | } | 59 | } |
68 | 60 | ||
69 | void atari_scc_console_write(struct console *co, const char *str, | 61 | static void atari_scc_console_write(struct console *co, const char *str, |
70 | unsigned int count) | 62 | unsigned int count) |
71 | { | 63 | { |
72 | while (count--) { | 64 | while (count--) { |
73 | if (*str == '\n') | 65 | if (*str == '\n') |
@@ -83,8 +75,8 @@ static inline void ata_midi_out(char c) | |||
83 | acia.mid_data = c; | 75 | acia.mid_data = c; |
84 | } | 76 | } |
85 | 77 | ||
86 | void atari_midi_console_write(struct console *co, const char *str, | 78 | static void atari_midi_console_write(struct console *co, const char *str, |
87 | unsigned int count) | 79 | unsigned int count) |
88 | { | 80 | { |
89 | while (count--) { | 81 | while (count--) { |
90 | if (*str == '\n') | 82 | if (*str == '\n') |
@@ -136,7 +128,7 @@ static void atari_par_console_write(struct console *co, const char *str, | |||
136 | } | 128 | } |
137 | } | 129 | } |
138 | 130 | ||
139 | #ifdef CONFIG_SERIAL_CONSOLE | 131 | #if 0 |
140 | int atari_mfp_console_wait_key(struct console *co) | 132 | int atari_mfp_console_wait_key(struct console *co) |
141 | { | 133 | { |
142 | while (!(mfp.rcv_stat & 0x80)) /* wait for rx buf filled */ | 134 | while (!(mfp.rcv_stat & 0x80)) /* wait for rx buf filled */ |
@@ -166,11 +158,7 @@ int atari_midi_console_wait_key(struct console *co) | |||
166 | * SCC serial ports. They're used by the debugging interface, kgdb, and the | 158 | * SCC serial ports. They're used by the debugging interface, kgdb, and the |
167 | * serial console code. | 159 | * serial console code. |
168 | */ | 160 | */ |
169 | #ifndef CONFIG_SERIAL_CONSOLE | ||
170 | static void __init atari_init_mfp_port(int cflag) | 161 | static void __init atari_init_mfp_port(int cflag) |
171 | #else | ||
172 | void atari_init_mfp_port(int cflag) | ||
173 | #endif | ||
174 | { | 162 | { |
175 | /* | 163 | /* |
176 | * timer values for 1200...115200 bps; > 38400 select 110, 134, or 150 | 164 | * timer values for 1200...115200 bps; > 38400 select 110, 134, or 150 |
@@ -193,8 +181,6 @@ void atari_init_mfp_port(int cflag) | |||
193 | mfp.tim_dt_d = baud_table[baud]; | 181 | mfp.tim_dt_d = baud_table[baud]; |
194 | mfp.tim_ct_cd |= 0x01; /* start timer D, 1:4 */ | 182 | mfp.tim_ct_cd |= 0x01; /* start timer D, 1:4 */ |
195 | mfp.trn_stat |= 0x01; /* enable TX */ | 183 | mfp.trn_stat |= 0x01; /* enable TX */ |
196 | |||
197 | atari_MFP_init_done = 1; | ||
198 | } | 184 | } |
199 | 185 | ||
200 | #define SCC_WRITE(reg, val) \ | 186 | #define SCC_WRITE(reg, val) \ |
@@ -214,11 +200,7 @@ void atari_init_mfp_port(int cflag) | |||
214 | MFPDELAY(); \ | 200 | MFPDELAY(); \ |
215 | } while (0) | 201 | } while (0) |
216 | 202 | ||
217 | #ifndef CONFIG_SERIAL_CONSOLE | ||
218 | static void __init atari_init_scc_port(int cflag) | 203 | static void __init atari_init_scc_port(int cflag) |
219 | #else | ||
220 | void atari_init_scc_port(int cflag) | ||
221 | #endif | ||
222 | { | 204 | { |
223 | extern int atari_SCC_reset_done; | 205 | extern int atari_SCC_reset_done; |
224 | static int clksrc_table[9] = | 206 | static int clksrc_table[9] = |
@@ -277,14 +259,9 @@ void atari_init_scc_port(int cflag) | |||
277 | SCC_WRITE(5, reg5 | 8); | 259 | SCC_WRITE(5, reg5 | 8); |
278 | 260 | ||
279 | atari_SCC_reset_done = 1; | 261 | atari_SCC_reset_done = 1; |
280 | atari_SCC_init_done = 1; | ||
281 | } | 262 | } |
282 | 263 | ||
283 | #ifndef CONFIG_SERIAL_CONSOLE | ||
284 | static void __init atari_init_midi_port(int cflag) | 264 | static void __init atari_init_midi_port(int cflag) |
285 | #else | ||
286 | void atari_init_midi_port(int cflag) | ||
287 | #endif | ||
288 | { | 265 | { |
289 | int baud = cflag & CBAUD; | 266 | int baud = cflag & CBAUD; |
290 | int csize = ((cflag & CSIZE) == CS8) ? 0x10 : 0x00; | 267 | int csize = ((cflag & CSIZE) == CS8) ? 0x10 : 0x00; |