svn commit: r296922 - head/sys/dev/ixgbe

Steven Hartland smh at FreeBSD.org
Wed Mar 16 01:41:56 UTC 2016


Author: smh
Date: Wed Mar 16 01:41:55 2016
New Revision: 296922
URL: https://svnweb.freebsd.org/changeset/base/296922

Log:
  Prevent invalid ixgbe advertise setting warning
  
  Prevent ixgbe outputting "Invalid advertised speed" warning on boot with
  no customisations by moving test from sysctl handler to set handler.
  
  PR:		208022
  MFC after:	3 days
  Sponsored by:	Multiplay

Modified:
  head/sys/dev/ixgbe/if_ix.c

Modified: head/sys/dev/ixgbe/if_ix.c
==============================================================================
--- head/sys/dev/ixgbe/if_ix.c	Tue Mar 15 22:27:29 2016	(r296921)
+++ head/sys/dev/ixgbe/if_ix.c	Wed Mar 16 01:41:55 2016	(r296922)
@@ -4749,10 +4749,6 @@ ixgbe_sysctl_advertise(SYSCTL_HANDLER_AR
 	if ((error) || (req->newptr == NULL))
 		return (error);
 
-	/* Checks to validate new value */
-	if (adapter->advertise == advertise) /* no change */
-		return (0);
-
 	return ixgbe_set_advertise(adapter, advertise);
 }
 
@@ -4763,6 +4759,10 @@ ixgbe_set_advertise(struct adapter *adap
 	struct ixgbe_hw		*hw;
 	ixgbe_link_speed	speed;
 
+	/* Checks to validate new value */
+	if (adapter->advertise == advertise) /* no change */
+		return (0);
+
 	hw = &adapter->hw;
 	dev = adapter->dev;
 


More information about the svn-src-all mailing list