[wdmaudiodev] PortCls behavior on power state change

  • From: Eugene Muzychenko <eugene@xxxxxxxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Tue, 10 Mar 2015 11:44:23 +0600

Hello!

In "IPowerNotify" and "Implementing IPowerNotify" topics, MSDN Library
says that port driver PAUSES audio streams before calling
PowerChangeNotify. But really, when going to sleep/hibernate state,
port driver STOPS all miniport streams by calling SetState
(KSSTATE_ACQUIRE) and SetState (KSSTATE_STOP) after calling SetState
(KSSTATE_PAUSE). Doing that, port driver does not revoke mappings from
WavePci miniport.

It is VERY inconvenient to maintain state transitions in such
conditions:

- When going from ACQUIRE to STOP, must release all resources except
needed for mapping list.

- When going from STOP to ACQUIRE, must skip mapping list and amount
variables initialization.

- Each Assert call must check if a "plain" stop transition is
performed or a "simulated" one.

Additionally, MSDN Library says: "PortCls calls the
IPowerNotify::PowerChangeNotify method to individually notify each of
the miniport and stream objects that support the IPowerNotify
interface". But really, port driver never asks stream objects for
IID_IPowerNotify. Only IMiniportWavePci and IMiniportTopology objects
are asked for this interface.

Is there a way to force PortCls to behave as said in documentation? At
least, to just pause stream objects instead of fully stopping them.

Regards,
Eugene

******************

WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.com/

Other related posts:

  • » [wdmaudiodev] PortCls behavior on power state change - Eugene Muzychenko