From: Paul Durrant Date: Fri, 4 Dec 2015 16:01:03 +0000 (+0000) Subject: Skip interface checks on non-active FDO X-Git-Tag: 8.2.0-rc1~39 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=78e2f7d7b13841f1544b15ede8f76f66cc9025e8;p=pvdrivers%2Fwin%2Fxenbus.git Skip interface checks on non-active FDO If the non-active FDO powers down before the active one then we end up with the BUG_ONs firing erroneously. Signed-off-by: Paul Durrant --- diff --git a/src/xenbus/fdo.c b/src/xenbus/fdo.c index e889871..00801c9 100644 --- a/src/xenbus/fdo.c +++ b/src/xenbus/fdo.c @@ -3206,6 +3206,9 @@ FdoS3ToS4( ASSERT3U(KeGetCurrentIrql(), ==, PASSIVE_LEVEL); ASSERT3U(__FdoGetSystemPowerState(Fdo), ==, PowerSystemSleeping3); + if (!__FdoIsActive(Fdo)) + goto not_active; + BUG_ON(SuspendGetReferences(Fdo->SuspendContext) != 0); BUG_ON(SharedInfoGetReferences(Fdo->SharedInfoContext) != 0); BUG_ON(EvtchnGetReferences(Fdo->EvtchnContext) != 0); @@ -3217,6 +3220,7 @@ FdoS3ToS4( BUG_ON(UnplugGetReferences(Fdo->UnplugContext) != 0); BUG_ON(BalloonGetReferences(Fdo->BalloonContext) != 0); +not_active: __FdoSetSystemPowerState(Fdo, PowerSystemHibernate); Trace("<====\n");