Skip to content

Commit 93c12e3

Browse files
committed
m68k: apollo: Remove unused debug console functions
When building with W=1: arch/m68k/apollo/config.c:111:5: warning: no previous prototype for ‘dn_serial_console_wait_key’ [-Wmissing-prototypes] 111 | int dn_serial_console_wait_key(struct console *co) { | ^~~~~~~~~~~~~~~~~~~~~~~~~~ arch/m68k/apollo/config.c:118:6: warning: no previous prototype for ‘dn_serial_console_write’ [-Wmissing-prototypes] 118 | void dn_serial_console_write (struct console *co, const char *str,unsigned int count) | ^~~~~~~~~~~~~~~~~~~~~~~ arch/m68k/apollo/config.c:238:6: warning: no previous prototype for ‘dn_dummy_waitbut’ [-Wmissing-prototypes] 240 | void dn_dummy_waitbut(void) { | ^~~~~~~~~~~~~~~~ Fix this by removing these unused functions. The last user of dn_serial_console_write() was removed in v2.3.41. The other functions never had any users. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/5da9036914a5c84c20b6af55f1801f0c734a96bb.1694613528.git.geert@linux-m68k.org
1 parent 5642236 commit 93c12e3

1 file changed

Lines changed: 0 additions & 28 deletions

File tree

arch/m68k/apollo/config.c

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
#include <linux/kernel.h>
55
#include <linux/mm.h>
66
#include <linux/tty.h>
7-
#include <linux/console.h>
87
#include <linux/rtc.h>
98
#include <linux/vt_kern.h>
109
#include <linux/interrupt.h>
@@ -108,27 +107,6 @@ static void __init dn_setup_model(void)
108107

109108
}
110109

111-
int dn_serial_console_wait_key(struct console *co) {
112-
113-
while(!(sio01.srb_csrb & 1))
114-
barrier();
115-
return sio01.rhrb_thrb;
116-
}
117-
118-
void dn_serial_console_write (struct console *co, const char *str,unsigned int count)
119-
{
120-
while(count--) {
121-
if (*str == '\n') {
122-
sio01.rhrb_thrb = (unsigned char)'\r';
123-
while (!(sio01.srb_csrb & 0x4))
124-
;
125-
}
126-
sio01.rhrb_thrb = (unsigned char)*str++;
127-
while (!(sio01.srb_csrb & 0x4))
128-
;
129-
}
130-
}
131-
132110
void dn_serial_print (const char *str)
133111
{
134112
while (*str) {
@@ -237,12 +215,6 @@ void dn_dummy_reset(void) {
237215

238216
}
239217

240-
void dn_dummy_waitbut(void) {
241-
242-
dn_serial_print("waitbut\n");
243-
244-
}
245-
246218
static void dn_get_model(char *model)
247219
{
248220
strcpy(model, "Apollo ");

0 commit comments

Comments
 (0)