Module Name:    src
Committed By:   yamaguchi
Date:           Mon May 25 07:20:15 UTC 2020

Modified Files:
        src/sys/arch/amd64/conf: ALL
        src/sys/arch/i386/conf: ALL
        src/sys/dev/pci: if_vioif.c

Log Message:
Obsolete VIOIF_SOFTINT_INTR

The kernel option is introduced to realize softint-based if_input.
Since the same scheme has been implemented in if_percpuq_enqueue(),
the option is no longer needed.

pointed out by [email protected].


To generate a diff of this commit:
cvs rdiff -u -r1.150 -r1.151 src/sys/arch/amd64/conf/ALL
cvs rdiff -u -r1.492 -r1.493 src/sys/arch/i386/conf/ALL
cvs rdiff -u -r1.52 -r1.53 src/sys/dev/pci/if_vioif.c

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

Modified files:

Index: src/sys/arch/amd64/conf/ALL
diff -u src/sys/arch/amd64/conf/ALL:1.150 src/sys/arch/amd64/conf/ALL:1.151
--- src/sys/arch/amd64/conf/ALL:1.150	Sat May 16 13:46:10 2020
+++ src/sys/arch/amd64/conf/ALL	Mon May 25 07:20:14 2020
@@ -1,4 +1,4 @@
-# $NetBSD: ALL,v 1.150 2020/05/16 13:46:10 maya Exp $
+# $NetBSD: ALL,v 1.151 2020/05/25 07:20:14 yamaguchi Exp $
 # From NetBSD: GENERIC,v 1.787 2006/10/01 18:37:54 bouyer Exp
 #
 # ALL machine description file
@@ -17,7 +17,7 @@ include 	"arch/amd64/conf/std.amd64"
 
 options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident		"ALL-$Revision: 1.150 $"
+#ident		"ALL-$Revision: 1.151 $"
 
 maxusers	64		# estimated number of users
 
@@ -2160,7 +2160,6 @@ options SMB_VNODE_DEBUG
 options SNAPPER_DEBUG
 options SNDEBUG
 options SOCKBUF_DEBUG
-options SOFTINT_INTR
 options SONIC_DEBUG
 options SPARC_PCI_DEBUG
 options SPC_DEBUG

Index: src/sys/arch/i386/conf/ALL
diff -u src/sys/arch/i386/conf/ALL:1.492 src/sys/arch/i386/conf/ALL:1.493
--- src/sys/arch/i386/conf/ALL:1.492	Sat May 16 13:46:11 2020
+++ src/sys/arch/i386/conf/ALL	Mon May 25 07:20:15 2020
@@ -1,4 +1,4 @@
-# $NetBSD: ALL,v 1.492 2020/05/16 13:46:11 maya Exp $
+# $NetBSD: ALL,v 1.493 2020/05/25 07:20:15 yamaguchi Exp $
 # From NetBSD: GENERIC,v 1.787 2006/10/01 18:37:54 bouyer Exp
 #
 # ALL machine description file
@@ -17,7 +17,7 @@ include 	"arch/i386/conf/std.i386"
 
 options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident		"ALL-$Revision: 1.492 $"
+#ident		"ALL-$Revision: 1.493 $"
 
 maxusers	64		# estimated number of users
 
@@ -2276,7 +2276,6 @@ options SMB_VNODE_DEBUG
 options SNAPPER_DEBUG
 options SNDEBUG
 options SOCKBUF_DEBUG
-options SOFTINT_INTR
 options SONIC_DEBUG
 options SPARC_PCI_DEBUG
 options SPC_DEBUG

Index: src/sys/dev/pci/if_vioif.c
diff -u src/sys/dev/pci/if_vioif.c:1.52 src/sys/dev/pci/if_vioif.c:1.53
--- src/sys/dev/pci/if_vioif.c:1.52	Thu Jan 30 14:02:14 2020
+++ src/sys/dev/pci/if_vioif.c	Mon May 25 07:20:15 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_vioif.c,v 1.52 2020/01/30 14:02:14 thorpej Exp $	*/
+/*	$NetBSD: if_vioif.c,v 1.53 2020/05/25 07:20:15 yamaguchi Exp $	*/
 
 /*
  * Copyright (c) 2010 Minoura Makoto.
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_vioif.c,v 1.52 2020/01/30 14:02:14 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_vioif.c,v 1.53 2020/05/25 07:20:15 yamaguchi Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -63,10 +63,6 @@ __KERNEL_RCSID(0, "$NetBSD: if_vioif.c,v
 #define VIOIF_MULTIQ	1
 #endif
 
-#ifdef SOFTINT_INTR
-#define VIOIF_SOFTINT_INTR	1
-#endif
-
 /*
  * if_vioifreg.h:
  */
@@ -696,9 +692,6 @@ vioif_attach(device_t parent, device_t s
 #ifdef VIOIF_MPSAFE
 	req_flags |= VIRTIO_F_PCI_INTR_MPSAFE;
 #endif
-#ifdef VIOIF_SOFTINT_INTR
-	req_flags |= VIRTIO_F_PCI_INTR_SOFTINT;
-#endif
 	req_flags |= VIRTIO_F_PCI_INTR_MSIX;
 
 	req_features =
@@ -1466,10 +1459,6 @@ vioif_rx_vq_done(struct virtqueue *vq)
 	struct vioif_rxqueue *rxq = vq->vq_done_ctx;
 	int r = 0;
 
-#ifdef VIOIF_SOFTINT_INTR
-	KASSERT(!cpu_intr_p());
-#endif
-
 	mutex_enter(rxq->rxq_lock);
 
 	if (rxq->rxq_stopping)
@@ -1477,11 +1466,7 @@ vioif_rx_vq_done(struct virtqueue *vq)
 
 	r = vioif_rx_deq_locked(rxq);
 	if (r)
-#ifdef VIOIF_SOFTINT_INTR
-		vioif_populate_rx_mbufs_locked(rxq);
-#else
 		softint_schedule(rxq->rxq_softint);
-#endif
 
 out:
 	mutex_exit(rxq->rxq_lock);
@@ -2011,18 +1996,7 @@ vioif_config_change(struct virtio_softc 
 {
 	struct vioif_softc *sc = device_private(virtio_child(vsc));
 
-#ifdef VIOIF_SOFTINT_INTR
-	struct ifnet *ifp = &sc->sc_ethercom.ec_if;
-#endif
-
-#ifdef VIOIF_SOFTINT_INTR
-	KASSERT(!cpu_intr_p());
-	vioif_update_link_status(sc);
-	vioif_start(ifp);
-#else
 	softint_schedule(sc->sc_ctl_softint);
-#endif
-
 	return 0;
 }
 

Reply via email to