Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 5 Sep 2012 06:51:28 +0000 (UTC)
From:      Mike Silbersack <silby@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r240128 - head/sys/dev/bxe
Message-ID:  <201209050651.q856pSNB090888@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: silby
Date: Wed Sep  5 06:51:28 2012
New Revision: 240128
URL: http://svn.freebsd.org/changeset/base/240128

Log:
  Only stop the BXE controller if it was first started.  Stopping
  an uninitialized controller can cause IPMI bus errors on some
  systems.
  
  Reviewed by:	yongari
  Obtained from:	McAfee, Inc.
  MFC after:	2 weeks

Modified:
  head/sys/dev/bxe/if_bxe.c

Modified: head/sys/dev/bxe/if_bxe.c
==============================================================================
--- head/sys/dev/bxe/if_bxe.c	Wed Sep  5 06:15:15 2012	(r240127)
+++ head/sys/dev/bxe/if_bxe.c	Wed Sep  5 06:51:28 2012	(r240128)
@@ -3554,8 +3554,14 @@ bxe_shutdown(device_t dev)
 	sc = device_get_softc(dev);
 	DBENTER(BXE_INFO_LOAD | BXE_INFO_RESET | BXE_INFO_UNLOAD);
 
+	/* Stop the controller, but only if it was ever started.
+	 * Stopping an uninitialized controller can cause
+	 * IPMI bus errors on some systems.
+	 */
 	BXE_CORE_LOCK(sc);
-	bxe_stop_locked(sc, UNLOAD_NORMAL);
+	if (sc->state != BXE_STATE_CLOSED) {
+		bxe_stop_locked(sc, UNLOAD_NORMAL);
+	}
 	BXE_CORE_UNLOCK(sc);
 
 	DBEXIT(BXE_INFO_LOAD | BXE_INFO_RESET | BXE_INFO_UNLOAD);



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