Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Apr 2016 11:20:56 +0000 (UTC)
From:      Wojciech Macek <wma@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r297707 - head/sys/dev/vnic
Message-ID:  <201604081120.u38BKuD1085362@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: wma
Date: Fri Apr  8 11:20:56 2016
New Revision: 297707
URL: https://svnweb.freebsd.org/changeset/base/297707

Log:
  Speedup BGX link polling on ARM64
  
  The previous values caused the callout thread stall for 100ms each 2s
  if no link is present. Dtrace analysis showed that it has significant
  impact on overall interrupt performance.
  Decrease these values by a factor of 100.
  
  Obtained from:         Semihalf
  Sponsored by:          Cavium
  Reviewed by:           zbb
  Differential Revision: https://reviews.freebsd.org/D5854

Modified:
  head/sys/dev/vnic/thunder_bgx.c

Modified: head/sys/dev/vnic/thunder_bgx.c
==============================================================================
--- head/sys/dev/vnic/thunder_bgx.c	Fri Apr  8 11:15:26 2016	(r297706)
+++ head/sys/dev/vnic/thunder_bgx.c	Fri Apr  8 11:20:56 2016	(r297707)
@@ -240,7 +240,7 @@ static int
 bgx_poll_reg(struct bgx *bgx, uint8_t lmac, uint64_t reg, uint64_t mask,
     boolean_t zero)
 {
-	int timeout = 100;
+	int timeout = 10;
 	uint64_t reg_val;
 
 	while (timeout) {
@@ -250,7 +250,7 @@ bgx_poll_reg(struct bgx *bgx, uint8_t lm
 		if (!zero && (reg_val & mask))
 			return (0);
 
-		DELAY(1000);
+		DELAY(100);
 		timeout--;
 	}
 	return (ETIMEDOUT);



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