shithub: riscv

Download patch

ref: 3c8246a31ce776976ee95310efa2c6e64a471993
parent: c325c491f61696e81ab0ee9e6aea840c3636ed3d
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Jan 28 13:58:38 EST 2024

ether7688: fix compiler warnings

--- a/sys/src/9/mt7688/ether7688.c
+++ b/sys/src/9/mt7688/ether7688.c
@@ -191,7 +191,7 @@
 
 
 static int
-miird(Mii *mii, int pa, int ra)
+miird(Mii*, int pa, int ra)
 {
 	int val = 0;
 	int	timeout;
@@ -220,7 +220,7 @@
 
 
 static int
-miiwr(Mii *mii, int pa, int ra, int val)
+miiwr(Mii*, int pa, int ra, int val)
 {
 	int timeout;
 
@@ -542,10 +542,7 @@
  * 	is handled by the switch start up
  */
 
-	MiiPhy *phy;
-	Ether	*edev = ctlr->edev;
-	int		i, buf;
-	
+	Ether	*edev = ctlr->edev;	
 
 	if((ctlr->mii = malloc(sizeof(Mii))) == nil)
 		return -1;
@@ -554,7 +551,7 @@
 	ctlr->mii->mir	= miird;
 	ctlr->mii->miw	= miiwr;
 
-	if(mii(ctlr->mii, ~0) == 0 || (phy = ctlr->mii->curphy) == nil){
+	if(mii(ctlr->mii, ~0) == 0 || ctlr->mii->curphy == nil){
 		iprint("#l%d: init mii failure\n", edev->ctlrno);
 		free(ctlr->mii);
 		ctlr->mii = nil;
@@ -747,7 +744,6 @@
 	char* p;
 	Ctlr* ctlr;
 	int l;
-	Desc	*t, *r;
 
 	ctlr = edev->ctlr;