lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <5da9036914a5c84c20b6af55f1801f0c734a96bb.1694613528.git.geert@linux-m68k.org>
Date:   Wed, 13 Sep 2023 16:08:13 +0200
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     linux-m68k@...ts.linux-m68k.org
Cc:     Arnd Bergmann <arnd@...db.de>, Finn Thain <fthain@...ux-m68k.org>,
        Michael Schmitz <schmitzmic@...il.com>,
        Philip Blundell <philb@....org>,
        Greg Ungerer <gerg@...ux-m68k.org>,
        Joshua Thompson <funaho@...ai.org>,
        Sam Creasey <sammy@...my.net>,
        Laurent Vivier <laurent@...ier.eu>,
        linux-kernel@...r.kernel.org,
        Geert Uytterhoeven <geert@...ux-m68k.org>
Subject: [PATCH v2 23/52] 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@...ux-m68k.org>
Acked-by: Arnd Bergmann <arnd@...db.de>
---
v2:
  - Add Acked-by.
---
 arch/m68k/apollo/config.c | 28 ----------------------------
 1 file changed, 28 deletions(-)

diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c
index 42a8b8e2b664226a..fccbb40772dca6b9 100644
--- a/arch/m68k/apollo/config.c
+++ b/arch/m68k/apollo/config.c
@@ -4,7 +4,6 @@
 #include <linux/kernel.h>
 #include <linux/mm.h>
 #include <linux/tty.h>
-#include <linux/console.h>
 #include <linux/rtc.h>
 #include <linux/vt_kern.h>
 #include <linux/interrupt.h>
@@ -108,27 +107,6 @@ static void __init dn_setup_model(void)
 
 }
 
-int dn_serial_console_wait_key(struct console *co) {
-
-	while(!(sio01.srb_csrb & 1))
-		barrier();
-	return sio01.rhrb_thrb;
-}
-
-void dn_serial_console_write (struct console *co, const char *str,unsigned int count)
-{
-   while(count--) {
-	if (*str == '\n') {
-	sio01.rhrb_thrb = (unsigned char)'\r';
-	while (!(sio01.srb_csrb & 0x4))
-                ;
-	}
-    sio01.rhrb_thrb = (unsigned char)*str++;
-    while (!(sio01.srb_csrb & 0x4))
-            ;
-  }
-}
-
 void dn_serial_print (const char *str)
 {
     while (*str) {
@@ -237,12 +215,6 @@ void dn_dummy_reset(void) {
 
 }
 
-void dn_dummy_waitbut(void) {
-
-  dn_serial_print("waitbut\n");
-
-}
-
 static void dn_get_model(char *model)
 {
     strcpy(model, "Apollo ");
-- 
2.34.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ