Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 28 Oct 2020 21:06:17 +0000 (UTC)
From:      Vincenzo Maffione <vmaffione@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r367117 - head/sys/net
Message-ID:  <202010282106.09SL6HmM036815@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: vmaffione
Date: Wed Oct 28 21:06:17 2020
New Revision: 367117
URL: https://svnweb.freebsd.org/changeset/base/367117

Log:
  iflib: fix typo bug introduced by r367093
  
  Code was supposed to call callout_reset_sbt_on() rather than
  callout_reset_sbt(). This resulted into passing a "cpu" value
  to a "flag" argument. A recipe for subtle errors.
  
  PR:	248652
  Reported by:	sg@efficientip.com
  MFC with: r367093

Modified:
  head/sys/net/iflib.c

Modified: head/sys/net/iflib.c
==============================================================================
--- head/sys/net/iflib.c	Wed Oct 28 21:02:43 2020	(r367116)
+++ head/sys/net/iflib.c	Wed Oct 28 21:06:17 2020	(r367117)
@@ -1066,9 +1066,10 @@ iflib_netmap_txsync(struct netmap_kring *kring, int fl
 
 	if (!(ctx->ifc_flags & IFC_NETMAP_TX_IRQ))
 		if (kring->nr_hwtail != nm_prev(kring->nr_hwcur, lim)) {
-			callout_reset_sbt(&txq->ift_netmap_timer,
+			callout_reset_sbt_on(&txq->ift_netmap_timer,
 			    NETMAP_TX_TIMER_US * SBT_1US, SBT_1US,
-			    iflib_netmap_timer, txq, txq->ift_netmap_timer.c_cpu);
+			    iflib_netmap_timer, txq,
+			    txq->ift_netmap_timer.c_cpu, 0);
 		}
 	return (0);
 }



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202010282106.09SL6HmM036815>