svn commit: r300845 - head/sys/dev/sfxge/common

Andrew Rybchenko arybchik at FreeBSD.org
Fri May 27 11:47:57 UTC 2016


Author: arybchik
Date: Fri May 27 11:47:56 2016
New Revision: 300845
URL: https://svnweb.freebsd.org/changeset/base/300845

Log:
  sfxge(4): cope with lint for EFX_SET_OWORD_BIT() with const bit arg
  
  Found by lint on illumos.
  
  Submitted by:   Garrett D'Amore <garrett at damore.org>
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      1 week

Modified:
  head/sys/dev/sfxge/common/siena_mac.c

Modified: head/sys/dev/sfxge/common/siena_mac.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_mac.c	Fri May 27 11:47:11 2016	(r300844)
+++ head/sys/dev/sfxge/common/siena_mac.c	Fri May 27 11:47:56 2016	(r300845)
@@ -158,8 +158,17 @@ siena_mac_reconfigure(
 	 * so we always add bit 0xff to the mask (bit 0x7f in the
 	 * second octword).
 	 */
-	if (epp->ep_brdcst)
+	if (epp->ep_brdcst) {
+		/*
+		 * NOTE: due to constant folding, some of this evaluates
+		 * to null expressions, giving E_EXPR_NULL_EFFECT during
+		 * lint on Illumos.  No good way to fix this without
+		 * explicit coding the individual word/bit setting.
+		 * So just suppress lint for this one line.
+		 */
+		/* LINTED */
 		EFX_SET_OWORD_BIT(multicast_hash[1], 0x7f);
+	}
 
 	(void) memset(payload, 0, sizeof (payload));
 	req.emr_cmd = MC_CMD_SET_MCAST_HASH;


More information about the svn-src-head mailing list