[OpenBIOS] [PATCH 2/3] SPARC32: fix build warnings on gcc6

Mark Cave-Ayland mark.cave-ayland at ilande.co.uk
Fri Mar 11 17:25:32 CET 2016


Remove unused functions from the sbus and obio drivers.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland at ilande.co.uk>
---
 openbios-devel/drivers/obio.c |   64 -----------------------------------------
 openbios-devel/drivers/sbus.c |   25 ----------------
 2 files changed, 89 deletions(-)

diff --git a/openbios-devel/drivers/obio.c b/openbios-devel/drivers/obio.c
index 7c135a3..3fd8ece 100644
--- a/openbios-devel/drivers/obio.c
+++ b/openbios-devel/drivers/obio.c
@@ -397,45 +397,6 @@ ob_smp_init(unsigned long mem_size)
 }
 
 static void
-ob_obio_open(__attribute__((unused))int *idx)
-{
-	int ret=1;
-	RET ( -ret );
-}
-
-static void
-ob_obio_close(__attribute__((unused))int *idx)
-{
-	selfword("close-deblocker");
-}
-
-static void
-ob_obio_initialize(__attribute__((unused))int *idx)
-{
-    push_str("/");
-    fword("find-device");
-    fword("new-device");
-
-    push_str("obio");
-    fword("device-name");
-
-    push_str("hierarchical");
-    fword("device-type");
-
-    PUSH(2);
-    fword("encode-int");
-    push_str("#address-cells");
-    fword("property");
-
-    PUSH(1);
-    fword("encode-int");
-    push_str("#size-cells");
-    fword("property");
-
-    fword("finish-device");
-}
-
-static void
 ob_set_obio_ranges(uint64_t base)
 {
     push_str("/obio");
@@ -458,27 +419,6 @@ ob_set_obio_ranges(uint64_t base)
     fword("property");
 }
 
-static void
-ob_obio_decodeunit(__attribute__((unused)) int *idx)
-{
-    fword("decode-unit-sbus");
-}
-
-
-static void
-ob_obio_encodeunit(__attribute__((unused)) int *idx)
-{
-    fword("encode-unit-sbus");
-}
-
-NODE_METHODS(ob_obio) = {
-	{ NULL,			ob_obio_initialize	},
-	{ "open",		ob_obio_open		},
-	{ "close",		ob_obio_close		},
-	{ "encode-unit",	ob_obio_encodeunit	},
-	{ "decode-unit",	ob_obio_decodeunit	},
-};
-
 
 int
 ob_obio_init(uint64_t slavio_base, unsigned long fd_offset,
@@ -491,10 +431,6 @@ ob_obio_init(uint64_t slavio_base, unsigned long fd_offset,
     // http://www.ibiblio.org/pub/historic-linux/early-ports/Sparc/NCR/NCR89C105.txt
 
     //printk("Initializing OBIO devices...\n");
-#if 0 // XXX
-    REGISTER_NAMED_NODE(ob_obio, "/obio");
-    device_end();
-#endif
     ob_set_obio_ranges(slavio_base);
 
     // Zilog Z8530 serial ports, see http://www.zilog.com
diff --git a/openbios-devel/drivers/sbus.c b/openbios-devel/drivers/sbus.c
index a9b26c0..4caa59a 100644
--- a/openbios-devel/drivers/sbus.c
+++ b/openbios-devel/drivers/sbus.c
@@ -369,31 +369,6 @@ sbus_probe_slot_ss600mp(unsigned int slot, uint64_t base)
     }
 }
 
-static void
-ob_sbus_open(void)
-{
-	int ret=1;
-	RET ( -ret );
-}
-
-static void
-ob_sbus_close(void)
-{
-	selfword("close-deblocker");
-}
-
-static void
-ob_sbus_initialize(void)
-{
-}
-
-
-NODE_METHODS(ob_sbus_node) = {
-	{ NULL,			ob_sbus_initialize	},
-	{ "open",		ob_sbus_open		},
-	{ "close",		ob_sbus_close		},
-};
-
 struct sbus_offset {
     int slot, type;
     uint64_t base;
-- 
1.7.10.4




More information about the OpenBIOS mailing list