Module Name:    src
Committed By:   knakahara
Date:           Fri Sep 16 03:12:03 UTC 2022

Modified Files:
        src/sys/dev/pci: files.pci if_ixl.c

Log Message:
Add ALWAYS_TXDEFER option to ixl(4), too.


To generate a diff of this commit:
cvs rdiff -u -r1.443 -r1.444 src/sys/dev/pci/files.pci
cvs rdiff -u -r1.87 -r1.88 src/sys/dev/pci/if_ixl.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/dev/pci/files.pci
diff -u src/sys/dev/pci/files.pci:1.443 src/sys/dev/pci/files.pci:1.444
--- src/sys/dev/pci/files.pci:1.443	Fri Sep 16 03:10:12 2022
+++ src/sys/dev/pci/files.pci	Fri Sep 16 03:12:03 2022
@@ -1,4 +1,4 @@
-#	$NetBSD: files.pci,v 1.443 2022/09/16 03:10:12 knakahara Exp $
+#	$NetBSD: files.pci,v 1.444 2022/09/16 03:12:03 knakahara Exp $
 #
 # Config file and device description for machine-independent PCI code.
 # Included by ports that need it.  Requires that the SCSI files be
@@ -1166,7 +1166,7 @@ file	dev/pci/qat/qat_d15xx.c		qat
 device	ixl: ether, ifnet, arp
 attach	ixl at pci
 file	dev/pci/if_ixl.c	ixl
-defflag	opt_if_ixl.h	IXL_DEBUG
+defflag	opt_if_ixl.h	IXL_DEBUG IXL_ALWAYS_TXDEFER
 defparam opt_if_ixl.h	IXL_STATS_INTERVAL_MSEC
 			IXL_QUEUE_NUM
 

Index: src/sys/dev/pci/if_ixl.c
diff -u src/sys/dev/pci/if_ixl.c:1.87 src/sys/dev/pci/if_ixl.c:1.88
--- src/sys/dev/pci/if_ixl.c:1.87	Sun Aug 28 07:54:03 2022
+++ src/sys/dev/pci/if_ixl.c	Fri Sep 16 03:12:03 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ixl.c,v 1.87 2022/08/28 07:54:03 skrll Exp $	*/
+/*	$NetBSD: if_ixl.c,v 1.88 2022/09/16 03:12:03 knakahara Exp $	*/
 
 /*
  * Copyright (c) 2013-2015, Intel Corporation
@@ -74,7 +74,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_ixl.c,v 1.87 2022/08/28 07:54:03 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ixl.c,v 1.88 2022/09/16 03:12:03 knakahara Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -2883,6 +2883,11 @@ ixl_transmit(struct ifnet *ifp, struct m
 		return ENOBUFS;
 	}
 
+#ifdef IXL_ALWAYS_TXDEFER
+	kpreempt_disable();
+	softint_schedule(txr->txr_si);
+	kpreempt_enable();
+#else
 	if (mutex_tryenter(&txr->txr_lock)) {
 		ixl_tx_common_locked(ifp, txr, true);
 		mutex_exit(&txr->txr_lock);
@@ -2891,6 +2896,7 @@ ixl_transmit(struct ifnet *ifp, struct m
 		softint_schedule(txr->txr_si);
 		kpreempt_enable();
 	}
+#endif
 
 	return 0;
 }

Reply via email to