Module Name:    src
Committed By:   jakllsch
Date:           Sun Apr 26 16:14:14 UTC 2020

Modified Files:
        src/sys/dev/pci: if_msk.c if_mskvar.h

Log Message:
Remove written-only sk_next member of struct (m)sk_chain.


To generate a diff of this commit:
cvs rdiff -u -r1.100 -r1.101 src/sys/dev/pci/if_msk.c
cvs rdiff -u -r1.22 -r1.23 src/sys/dev/pci/if_mskvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/if_msk.c
diff -u src/sys/dev/pci/if_msk.c:1.100 src/sys/dev/pci/if_msk.c:1.101
--- src/sys/dev/pci/if_msk.c:1.100	Wed Apr 22 14:26:27 2020
+++ src/sys/dev/pci/if_msk.c	Sun Apr 26 16:14:14 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: if_msk.c,v 1.100 2020/04/22 14:26:27 jdolecek Exp $ */
+/* $NetBSD: if_msk.c,v 1.101 2020/04/26 16:14:14 jakllsch Exp $ */
 /*	$OpenBSD: if_msk.c,v 1.79 2009/10/15 17:54:56 deraadt Exp $	*/
 
 /*
@@ -52,7 +52,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_msk.c,v 1.100 2020/04/22 14:26:27 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_msk.c,v 1.101 2020/04/26 16:14:14 jakllsch Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -419,17 +419,12 @@ msk_init_rx_ring(struct sk_if_softc *sc_
 	struct msk_chain_data	*cd = &sc_if->sk_cdata;
 	struct msk_ring_data	*rd = sc_if->sk_rdata;
 	struct msk_rx_desc	*r;
-	int			i, nexti;
+	int			i;
 
 	memset(rd->sk_rx_ring, 0, sizeof(struct msk_rx_desc) * MSK_RX_RING_CNT);
 
 	for (i = 0; i < MSK_RX_RING_CNT; i++) {
 		cd->sk_rx_chain[i].sk_le = &rd->sk_rx_ring[i];
-		if (i == (MSK_RX_RING_CNT - 1))
-			nexti = 0;
-		else
-			nexti = i + 1;
-		cd->sk_rx_chain[i].sk_next = &cd->sk_rx_chain[nexti];
 	}
 
 	sc_if->sk_cdata.sk_rx_prod = 0;
@@ -459,17 +454,12 @@ msk_init_tx_ring(struct sk_if_softc *sc_
 	struct msk_chain_data	*cd = &sc_if->sk_cdata;
 	struct msk_ring_data	*rd = sc_if->sk_rdata;
 	struct msk_tx_desc	*t;
-	int			i, nexti;
+	int			i;
 
 	memset(rd->sk_tx_ring, 0, sizeof(struct msk_tx_desc) * MSK_TX_RING_CNT);
 
 	for (i = 0; i < MSK_TX_RING_CNT; i++) {
 		cd->sk_tx_chain[i].sk_le = &rd->sk_tx_ring[i];
-		if (i == (MSK_TX_RING_CNT - 1))
-			nexti = 0;
-		else
-			nexti = i + 1;
-		cd->sk_tx_chain[i].sk_next = &cd->sk_tx_chain[nexti];
 	}
 
 	sc_if->sk_cdata.sk_tx_prod = 0;

Index: src/sys/dev/pci/if_mskvar.h
diff -u src/sys/dev/pci/if_mskvar.h:1.22 src/sys/dev/pci/if_mskvar.h:1.23
--- src/sys/dev/pci/if_mskvar.h:1.22	Fri Sep 13 07:55:07 2019
+++ src/sys/dev/pci/if_mskvar.h	Sun Apr 26 16:14:14 2020
@@ -1,5 +1,5 @@
 /*	$OpenBSD: if_mskvar.h,v 1.3 2006/12/28 16:34:42 kettenis Exp $	*/
-/*	$NetBSD: if_mskvar.h,v 1.22 2019/09/13 07:55:07 msaitoh Exp $	*/
+/*	$NetBSD: if_mskvar.h,v 1.23 2020/04/26 16:14:14 jakllsch Exp $	*/
 
 /*-
  * Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -91,7 +91,6 @@ struct sk_jpool_entry {
 struct sk_chain {
 	void			*sk_le;
 	struct mbuf		*sk_mbuf;
-	struct sk_chain		*sk_next;
 };
 
 /*

Reply via email to