ReactOS  0.4.13-dev-544-gede3fdd
CPortPinWavePci Class Reference
Inheritance diagram for CPortPinWavePci:
Collaboration diagram for CPortPinWavePci:

Public Member Functions

STDMETHODIMP QueryInterface (REFIID InterfaceId, PVOID *Interface)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
 CPortPinWavePci (IUnknown *OuterUnknown)
 
virtual ~CPortPinWavePci ()
 

Public Attributes

 IMP_IPortPinWavePci
 
 IMP_IServiceSink
 
 IMP_IPortWavePciStream
 

Protected Member Functions

NTSTATUS NTAPI HandleKsProperty (IN PIRP Irp)
 
NTSTATUS NTAPI HandleKsStream (IN PIRP Irp)
 

Protected Attributes

IPortWavePci * m_Port
 
IPortFilterWavePci * m_Filter
 
KSPIN_DESCRIPTOR * m_KsPinDescriptor
 
PMINIPORTWAVEPCI m_Miniport
 
PSERVICEGROUP m_ServiceGroup
 
PDMACHANNEL m_DmaChannel
 
PMINIPORTWAVEPCISTREAM m_Stream
 
KSSTATE m_State
 
PKSDATAFORMAT m_Format
 
KSPIN_CONNECTm_ConnectDetails
 
BOOL m_Capture
 
PDEVICE_OBJECT m_DeviceObject
 
IIrpQueue * m_IrpQueue
 
ULONG m_TotalPackets
 
KSAUDIO_POSITION m_Position
 
ULONG m_StopCount
 
BOOL m_bUsePrefetch
 
ULONG m_PrefetchOffset
 
SUBDEVICE_DESCRIPTOR m_Descriptor
 
KSALLOCATOR_FRAMING m_AllocatorFraming
 
LONG m_Ref
 

Friends

NTSTATUS NTAPI PinWavePciState (IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data)
 
NTSTATUS NTAPI PinWavePciDataFormat (IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data)
 
NTSTATUS NTAPI PinWavePciAudioPosition (IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data)
 
NTSTATUS NTAPI PinWavePciAllocatorFraming (IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data)
 

Detailed Description

Definition at line 17 of file pin_wavepci.cpp.

Constructor & Destructor Documentation

◆ CPortPinWavePci()

CPortPinWavePci::CPortPinWavePci ( IUnknown OuterUnknown)
inline

Definition at line 43 of file pin_wavepci.cpp.

43 {}

◆ ~CPortPinWavePci()

virtual CPortPinWavePci::~CPortPinWavePci ( )
inlinevirtual

Definition at line 44 of file pin_wavepci.cpp.

44 {}

Member Function Documentation

◆ HandleKsProperty()

NTSTATUS NTAPI CPortPinWavePci::HandleKsProperty ( IN PIRP  Irp)
protected

Definition at line 502 of file pin_wavepci.cpp.

504 {
505  //PKSPROPERTY Property;
507  //UNICODE_STRING GuidString;
508  PIO_STACK_LOCATION IoStack;
509 
510  //DPRINT("IPortPinWave_HandleKsProperty entered\n");
511 
513 
514  if (IoStack->Parameters.DeviceIoControl.IoControlCode != IOCTL_KS_PROPERTY)
515  {
516  //DPRINT("Unhandled function %lx Length %x\n", IoStack->Parameters.DeviceIoControl.IoControlCode, IoStack->Parameters.DeviceIoControl.InputBufferLength);
517 
518  Irp->IoStatus.Status = STATUS_SUCCESS;
519 
521  return STATUS_SUCCESS;
522  }
523 
525 
526  if (Status == STATUS_NOT_FOUND)
527  {
528  //Property = (PKSPROPERTY)IoStack->Parameters.DeviceIoControl.Type3InputBuffer;
529 #if 0
531  //DPRINT("Unhandled property Set |%S| Id %u Flags %x\n", GuidString.Buffer, Property->Id, Property->Flags);
533 #endif
534  }
535 
536  if (Status != STATUS_PENDING)
537  {
538  Irp->IoStatus.Status = Status;
540  }
541 
542  return Status;
543 }
static PWSTR GuidString
Definition: apphelp.c:91
#define IOCTL_KS_PROPERTY
Definition: ks.h:150
NTSTATUS NTAPI PcHandlePropertyWithTable(IN PIRP Irp, IN ULONG PropertySetCount, IN PKSPROPERTY_SET PropertySet, IN PSUBDEVICE_DESCRIPTOR Descriptor)
Definition: undoc.cpp:81
_In_ PIRP Irp
Definition: csq.h:116
LONG NTSTATUS
Definition: precomp.h:26
#define IoCompleteRequest
Definition: irp.c:1240
#define STATUS_NOT_FOUND
Definition: shellext.h:67
#define STATUS_PENDING
Definition: ntstatus.h:82
NTSYSAPI VOID NTAPI RtlFreeUnicodeString(PUNICODE_STRING UnicodeString)
SUBDEVICE_DESCRIPTOR m_Descriptor
Definition: pin_wavepci.cpp:73
NTSYSAPI NTSTATUS WINAPI RtlStringFromGUID(REFGUID, PUNICODE_STRING)
Status
Definition: gdiplustypes.h:24
__drv_aliasesMem FORCEINLINE PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(_In_ PIRP Irp)
Definition: iofuncs.h:2745
#define IO_NO_INCREMENT
Definition: iotypes.h:565
PKSPROPERTY_SET FilterPropertySet
Definition: interfaces.hpp:210
struct _NAMED_PIPE_CREATE_PARAMETERS * Parameters
Definition: iotypes.h:2771
return STATUS_SUCCESS
Definition: btrfs.c:2777

◆ HandleKsStream()

NTSTATUS NTAPI CPortPinWavePci::HandleKsStream ( IN PIRP  Irp)
protected

Definition at line 547 of file pin_wavepci.cpp.

549 {
551  ULONG Data = 0;
552  BOOLEAN bFailed;
554 
555  DPRINT("IPortPinWaveCyclic_HandleKsStream entered Total %u State %x MinData %u\n", m_TotalPackets, m_State, m_IrpQueue->NumData());
556 
557  bFailed = m_IrpQueue->HasLastMappingFailed();
558 
559  Status = m_IrpQueue->AddMapping(Irp, &Data);
560 
561  if (NT_SUCCESS(Status))
562  {
563  if (m_Capture)
565  else
567 
568  if (bFailed)
569  {
570  // notify stream of new mapping
571  m_Stream->MappingAvailable();
572  }
573 
574  return STATUS_PENDING;
575  }
576 
577  return Status;
578 }
_In_ PIRP Irp
Definition: csq.h:116
LONG NTSTATUS
Definition: precomp.h:26
unsigned char BOOLEAN
_In_ LPGUID _In_ PVOID Data
Definition: classpnp.h:778
void DPRINT(...)
Definition: polytest.cpp:61
PMINIPORTWAVEPCISTREAM m_Stream
Definition: pin_wavepci.cpp:58
DWORDLONG PlayOffset
Definition: ksmedia.h:1150
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
#define STATUS_PENDING
Definition: ntstatus.h:82
IIrpQueue * m_IrpQueue
Definition: pin_wavepci.cpp:65
Status
Definition: gdiplustypes.h:24
#define InterlockedIncrement
Definition: armddk.h:53
DWORDLONG WriteOffset
Definition: ksmedia.h:1151
KSAUDIO_POSITION m_Position
Definition: pin_wavepci.cpp:68
unsigned int ULONG
Definition: retypes.h:1
signed int * PLONG
Definition: retypes.h:5

◆ QueryInterface()

NTSTATUS NTAPI CPortPinWavePci::QueryInterface ( REFIID  InterfaceId,
PVOID Interface 
)

Definition at line 398 of file pin_wavepci.cpp.

401 {
402  //DPRINT("CPortPinWavePci::QueryInterface entered\n");
403 
404  if (IsEqualGUIDAligned(refiid, IID_IIrpTarget) ||
406  {
407  *Output = PVOID(PUNKNOWN((IIrpTarget*)this));
408  PUNKNOWN(*Output)->AddRef();
409  return STATUS_SUCCESS;
410  }
411 
412  if (IsEqualGUIDAligned(refiid, IID_IServiceSink))
413  {
414  *Output = PVOID(PSERVICESINK(this));
415  PUNKNOWN(*Output)->AddRef();
416  return STATUS_SUCCESS;
417  }
418 
419 
420  if (IsEqualGUIDAligned(refiid, IID_IPortWavePciStream))
421  {
422  *Output = PVOID(PPORTWAVEPCISTREAM(this));
423  PUNKNOWN(*Output)->AddRef();
424  return STATUS_SUCCESS;
425  }
426 
427  return STATUS_UNSUCCESSFUL;
428 }
IUnknown * PUNKNOWN
Definition: com_apitest.h:45
IPortWavePciStream * PPORTWAVEPCISTREAM
Definition: portcls.h:1571
IServiceSink * PSERVICESINK
Definition: portcls.h:569
#define IsEqualGUIDAligned(guid1, guid2)
Definition: wdm.template.h:233
void * PVOID
Definition: retypes.h:9
const GUID IID_IUnknown
ULONG AddRef()
#define STATUS_UNSUCCESSFUL
Definition: udferr_usr.h:132
Definition: arc.h:85
return STATUS_SUCCESS
Definition: btrfs.c:2777

◆ STDMETHODIMP_() [1/2]

CPortPinWavePci::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 24 of file pin_wavepci.cpp.

25  {
27  return m_Ref;
28  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHODIMP_() [2/2]

CPortPinWavePci::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 29 of file pin_wavepci.cpp.

30  {
32 
33  if (!m_Ref)
34  {
35  delete this;
36  return 0;
37  }
38  return m_Ref;
39  }
#define InterlockedDecrement
Definition: armddk.h:52

Friends And Related Function Documentation

◆ PinWavePciAllocatorFraming

NTSTATUS NTAPI PinWavePciAllocatorFraming ( IN PIRP  Irp,
IN PKSIDENTIFIER  Request,
IN OUT PVOID  Data 
)
friend

Definition at line 119 of file pin_wavepci.cpp.

123 {
126 
127  // get sub device descriptor
128  Descriptor = (PSUBDEVICE_DESCRIPTOR)KSPROPERTY_ITEM_IRP_STORAGE(Irp);
129 
130  // sanity check
132  PC_ASSERT(Descriptor->PortPin);
134 
135  // cast to pin impl
136  Pin = (CPortPinWavePci*)Descriptor->PortPin;
137 
138 
139  if (Request->Flags & KSPROPERTY_TYPE_GET)
140  {
141  // copy pin framing
142  RtlMoveMemory(Data, &Pin->m_AllocatorFraming, sizeof(KSALLOCATOR_FRAMING));
143 
144  Irp->IoStatus.Information = sizeof(KSALLOCATOR_FRAMING);
145  return STATUS_SUCCESS;
146  }
147 
148  // not supported
149  return STATUS_NOT_SUPPORTED;
150 }
#define PC_ASSERT(exp)
Definition: usbehci.h:17
_In_ PIRP Irp
Definition: csq.h:116
#define KSPROPERTY_TYPE_GET
Definition: dmksctrl.h:42
#define RtlMoveMemory(Destination, Source, Length)
Definition: typedefs.h:263
_In_ NDIS_HANDLE _In_ PNDIS_REQUEST Request
Definition: ndis.h:5173
if(!(yy_init))
Definition: macro.lex.yy.c:714
IN PDCB IN VBO IN ULONG IN BOOLEAN Pin
Definition: fatprocs.h:415
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
#define STATUS_NOT_SUPPORTED
Definition: ntstatus.h:409
return STATUS_SUCCESS
Definition: btrfs.c:2777
struct SUBDEVICE_DESCRIPTOR * PSUBDEVICE_DESCRIPTOR
#define PC_ASSERT_IRQL(x)
Definition: private.hpp:30
_In_ PSTORAGE_PROPERTY_ID _Outptr_ PSTORAGE_DESCRIPTOR_HEADER * Descriptor
Definition: classpnp.h:966

◆ PinWavePciAudioPosition

NTSTATUS NTAPI PinWavePciAudioPosition ( IN PIRP  Irp,
IN PKSIDENTIFIER  Request,
IN OUT PVOID  Data 
)
friend

Definition at line 154 of file pin_wavepci.cpp.

158 {
161 
162  // get sub device descriptor
163  Descriptor = (PSUBDEVICE_DESCRIPTOR)KSPROPERTY_ITEM_IRP_STORAGE(Irp);
164 
165  // sanity check
167  PC_ASSERT(Descriptor->PortPin);
169 
170  // cast to pin impl
171  Pin = (CPortPinWavePci*)Descriptor->PortPin;
172 
173  //sanity check
174  PC_ASSERT(Pin->m_Stream);
175 
176  if (Request->Flags & KSPROPERTY_TYPE_GET)
177  {
178  // FIXME non multithreading-safe
179  // copy audio position
180  RtlMoveMemory(Data, &Pin->m_Position, sizeof(KSAUDIO_POSITION));
181 
182  DPRINT("Play %lu Record %lu\n", Pin->m_Position.PlayOffset, Pin->m_Position.WriteOffset);
183  Irp->IoStatus.Information = sizeof(KSAUDIO_POSITION);
184  return STATUS_SUCCESS;
185  }
186 
187  // not supported
188  return STATUS_NOT_SUPPORTED;
189 }
#define PC_ASSERT(exp)
Definition: usbehci.h:17
_In_ PIRP Irp
Definition: csq.h:116
#define KSPROPERTY_TYPE_GET
Definition: dmksctrl.h:42
#define RtlMoveMemory(Destination, Source, Length)
Definition: typedefs.h:263
_In_ NDIS_HANDLE _In_ PNDIS_REQUEST Request
Definition: ndis.h:5173
void DPRINT(...)
Definition: polytest.cpp:61
IN PDCB IN VBO IN ULONG IN BOOLEAN Pin
Definition: fatprocs.h:415
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
#define STATUS_NOT_SUPPORTED
Definition: ntstatus.h:409
return STATUS_SUCCESS
Definition: btrfs.c:2777
struct SUBDEVICE_DESCRIPTOR * PSUBDEVICE_DESCRIPTOR
#define PC_ASSERT_IRQL(x)
Definition: private.hpp:30
_In_ PSTORAGE_PROPERTY_ID _Outptr_ PSTORAGE_DESCRIPTOR_HEADER * Descriptor
Definition: classpnp.h:966

◆ PinWavePciDataFormat

NTSTATUS NTAPI PinWavePciDataFormat ( IN PIRP  Irp,
IN PKSIDENTIFIER  Request,
IN OUT PVOID  Data 
)
friend

Definition at line 280 of file pin_wavepci.cpp.

284 {
288  PIO_STACK_LOCATION IoStack;
289 
290  // get current irp stack location
292 
293  // get sub device descriptor
294  Descriptor = (PSUBDEVICE_DESCRIPTOR)KSPROPERTY_ITEM_IRP_STORAGE(Irp);
295 
296  // sanity check
298  PC_ASSERT(Descriptor->PortPin);
299 
300  // cast to pin impl
301  Pin = (CPortPinWavePci*)Descriptor->PortPin;
302 
303  //sanity check
304  PC_ASSERT(Pin->m_Stream);
305  PC_ASSERT(Pin->m_Format);
306 
307  if (Request->Flags & KSPROPERTY_TYPE_SET)
308  {
309  // try to change data format
310  PKSDATAFORMAT NewDataFormat, DataFormat = (PKSDATAFORMAT)Irp->UserBuffer;
311  ULONG Size = min(Pin->m_Format->FormatSize, DataFormat->FormatSize);
312 
313  if (RtlCompareMemory(DataFormat, Pin->m_Format, Size) == Size)
314  {
315  // format is identical
316  Irp->IoStatus.Information = DataFormat->FormatSize;
317  return STATUS_SUCCESS;
318  }
319 
320  // new change request
321  PC_ASSERT(Pin->m_State == KSSTATE_STOP);
322  // FIXME queue a work item when Irql != PASSIVE_LEVEL
324 
325  // allocate new data format
326  NewDataFormat = (PKSDATAFORMAT)AllocateItem(NonPagedPool, DataFormat->FormatSize, TAG_PORTCLASS);
327  if (!NewDataFormat)
328  {
329  // not enough memory
330  return STATUS_NO_MEMORY;
331  }
332 
333  // copy new data format
334  RtlMoveMemory(NewDataFormat, DataFormat, DataFormat->FormatSize);
335 
336  // set new format
337  Status = Pin->m_Stream->SetFormat(NewDataFormat);
338  if (NT_SUCCESS(Status))
339  {
340  // free old format
341  FreeItem(Pin->m_Format, TAG_PORTCLASS);
342 
343  // store new format
344  Pin->m_Format = NewDataFormat;
345  Irp->IoStatus.Information = NewDataFormat->FormatSize;
346 
347 #if 0
348  PC_ASSERT(NewDataFormat->FormatSize == sizeof(KSDATAFORMAT_WAVEFORMATEX));
352 
353 
354  DPRINT("NewDataFormat: Channels %u Bits %u Samples %u\n", ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.nChannels,
355  ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.wBitsPerSample,
356  ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.nSamplesPerSec);
357 #endif
358 
359  }
360  else
361  {
362  // failed to set format
363  FreeItem(NewDataFormat, TAG_PORTCLASS);
364  }
365 
366 
367  // done
368  return Status;
369  }
370  else if (Request->Flags & KSPROPERTY_TYPE_GET)
371  {
372  // get current data format
373  PC_ASSERT(Pin->m_Format);
374 
375  if (Pin->m_Format->FormatSize > IoStack->Parameters.DeviceIoControl.OutputBufferLength)
376  {
377  // buffer too small
378  Irp->IoStatus.Information = Pin->m_Format->FormatSize;
379  return STATUS_MORE_ENTRIES;
380  }
381  // copy data format
382  RtlMoveMemory(Data, Pin->m_Format, Pin->m_Format->FormatSize);
383  // store result size
384  Irp->IoStatus.Information = Pin->m_Format->FormatSize;
385 
386  // done
387  return STATUS_SUCCESS;
388  }
389 
390  // unsupported request
391  return STATUS_NOT_SUPPORTED;
392 }
#define KeGetCurrentIrql()
Definition: env_spec_w32.h:706
#define KSDATAFORMAT_SUBTYPE_PCM
Definition: ksmedia.h:921
#define PC_ASSERT(exp)
Definition: usbehci.h:17
_In_ PIRP Irp
Definition: csq.h:116
#define TAG_PORTCLASS
Definition: private.hpp:24
PVOID AllocateItem(IN POOL_TYPE PoolType, IN SIZE_T NumberOfBytes)
Definition: misc.c:30
LONG NTSTATUS
Definition: precomp.h:26
#define KSPROPERTY_TYPE_GET
Definition: dmksctrl.h:42
#define RtlMoveMemory(Destination, Source, Length)
Definition: typedefs.h:263
#define KSDATAFORMAT_SPECIFIER_WAVEFORMATEX
Definition: ksmedia.h:931
#define IsEqualGUIDAligned(guid1, guid2)
Definition: wdm.template.h:233
_In_ NDIS_HANDLE _In_ PNDIS_REQUEST Request
Definition: ndis.h:5173
VOID FreeItem(IN PVOID Item)
Definition: misc.c:43
void DPRINT(...)
Definition: polytest.cpp:61
IN PDCB IN VBO IN ULONG IN BOOLEAN Pin
Definition: fatprocs.h:415
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
#define STATUS_UNSUCCESSFUL
Definition: udferr_usr.h:132
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:359
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
#define KSDATAFORMAT_TYPE_AUDIO
Definition: ksmedia.h:883
#define STATUS_MORE_ENTRIES
Definition: udferr_usr.h:124
Status
Definition: gdiplustypes.h:24
__drv_aliasesMem FORCEINLINE PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(_In_ PIRP Irp)
Definition: iofuncs.h:2745
#define STATUS_NO_MEMORY
Definition: ntstatus.h:246
#define min(a, b)
Definition: monoChain.cc:55
#define STATUS_NOT_SUPPORTED
Definition: ntstatus.h:409
unsigned int ULONG
Definition: retypes.h:1
struct _NAMED_PIPE_CREATE_PARAMETERS * Parameters
Definition: iotypes.h:2771
return STATUS_SUCCESS
Definition: btrfs.c:2777
#define KSPROPERTY_TYPE_SET
Definition: dmksctrl.h:43
struct SUBDEVICE_DESCRIPTOR * PSUBDEVICE_DESCRIPTOR
#define RtlCompareMemory(s1, s2, l)
Definition: env_spec_w32.h:465
KSDATAFORMAT * PKSDATAFORMAT
_In_ PSTORAGE_PROPERTY_ID _Outptr_ PSTORAGE_DESCRIPTOR_HEADER * Descriptor
Definition: classpnp.h:966

◆ PinWavePciState

NTSTATUS NTAPI PinWavePciState ( IN PIRP  Irp,
IN PKSIDENTIFIER  Request,
IN OUT PVOID  Data 
)
friend

Definition at line 194 of file pin_wavepci.cpp.

198 {
202  PVOID FirstTag, LastTag;
203  ULONG MappingsRevoked;
205 
206  // get sub device descriptor
207  Descriptor = (PSUBDEVICE_DESCRIPTOR)KSPROPERTY_ITEM_IRP_STORAGE(Irp);
208 
209  // sanity check
211  PC_ASSERT(Descriptor->PortPin);
213 
214  // cast to pin impl
215  Pin = (CPortPinWavePci*)Descriptor->PortPin;
216 
217  //sanity check
218  PC_ASSERT(Pin->m_Stream);
219 
220  if (Request->Flags & KSPROPERTY_TYPE_SET)
221  {
222  // try set stream
223  Status = Pin->m_Stream->SetState(*State);
224 
225  DPRINT("Setting state %u %x\n", *State, Status);
226  if (NT_SUCCESS(Status))
227  {
228  // store new state
229  Pin->m_State = *State;
230  if (Pin->m_ConnectDetails->Interface.Id == KSINTERFACE_STANDARD_LOOPED_STREAMING && Pin->m_State == KSSTATE_STOP)
231  {
232  // FIXME
233  // complete with successful state
234  Pin->m_IrpQueue->CancelBuffers();
235  while(Pin->m_IrpQueue->GetAcquiredTagRange(&FirstTag, &LastTag))
236  {
237  Status = Pin->m_Stream->RevokeMappings(FirstTag, LastTag, &MappingsRevoked);
238  DPRINT("RevokeMappings Status %lx MappingsRevoked: %lu\n", Status, MappingsRevoked);
240  }
241  Pin->m_Position.PlayOffset = 0;
242  Pin->m_Position.WriteOffset = 0;
243  }
244  else if (Pin->m_State == KSSTATE_STOP)
245  {
246  Pin->m_IrpQueue->CancelBuffers();
247  while(Pin->m_IrpQueue->GetAcquiredTagRange(&FirstTag, &LastTag))
248  {
249  Status = Pin->m_Stream->RevokeMappings(FirstTag, LastTag, &MappingsRevoked);
250  DPRINT("RevokeMappings Status %lx MappingsRevoked: %lu\n", Status, MappingsRevoked);
252  }
253  Pin->m_Position.PlayOffset = 0;
254  Pin->m_Position.WriteOffset = 0;
255  }
256  // store result
257  Irp->IoStatus.Information = sizeof(KSSTATE);
258 
259  }
260  // store result
261  Irp->IoStatus.Information = sizeof(KSSTATE);
262  return Status;
263  }
264  else if (Request->Flags & KSPROPERTY_TYPE_GET)
265  {
266  // get current stream state
267  *State = Pin->m_State;
268  // store result
269  Irp->IoStatus.Information = sizeof(KSSTATE);
270 
271  return STATUS_SUCCESS;
272  }
273 
274  // unsupported request
275  return STATUS_NOT_SUPPORTED;
276 }
#define PC_ASSERT(exp)
Definition: usbehci.h:17
_In_ PIRP Irp
Definition: csq.h:116
LONG NTSTATUS
Definition: precomp.h:26
#define KSPROPERTY_TYPE_GET
Definition: dmksctrl.h:42
_In_ NDIS_HANDLE _In_ PNDIS_REQUEST Request
Definition: ndis.h:5173
enum KSSTATE * PKSSTATE
void DPRINT(...)
Definition: polytest.cpp:61
IN PDCB IN VBO IN ULONG IN BOOLEAN Pin
Definition: fatprocs.h:415
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
#define STATUS_UNSUCCESSFUL
Definition: udferr_usr.h:132
Status
Definition: gdiplustypes.h:24
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
enum State_ State
Definition: pofuncs.h:54
KSSTATE
Definition: ks.h:1244
#define STATUS_NOT_SUPPORTED
Definition: ntstatus.h:409
unsigned int ULONG
Definition: retypes.h:1
return STATUS_SUCCESS
Definition: btrfs.c:2777
#define KSPROPERTY_TYPE_SET
Definition: dmksctrl.h:43
struct SUBDEVICE_DESCRIPTOR * PSUBDEVICE_DESCRIPTOR
VOID NTAPI KeStallExecutionProcessor(IN ULONG MicroSeconds)
Definition: ntoskrnl.c:99
#define PC_ASSERT_IRQL(x)
Definition: private.hpp:30
_In_ PSTORAGE_PROPERTY_ID _Outptr_ PSTORAGE_DESCRIPTOR_HEADER * Descriptor
Definition: classpnp.h:966

Member Data Documentation

◆ IMP_IPortPinWavePci

CPortPinWavePci::IMP_IPortPinWavePci

Definition at line 40 of file pin_wavepci.cpp.

◆ IMP_IPortWavePciStream

CPortPinWavePci::IMP_IPortWavePciStream

Definition at line 42 of file pin_wavepci.cpp.

◆ IMP_IServiceSink

CPortPinWavePci::IMP_IServiceSink

Definition at line 41 of file pin_wavepci.cpp.

◆ m_AllocatorFraming

KSALLOCATOR_FRAMING CPortPinWavePci::m_AllocatorFraming
protected

Definition at line 75 of file pin_wavepci.cpp.

◆ m_bUsePrefetch

BOOL CPortPinWavePci::m_bUsePrefetch
protected

Definition at line 71 of file pin_wavepci.cpp.

◆ m_Capture

BOOL CPortPinWavePci::m_Capture
protected

Definition at line 63 of file pin_wavepci.cpp.

Referenced by HandleKsStream().

◆ m_ConnectDetails

KSPIN_CONNECT* CPortPinWavePci::m_ConnectDetails
protected

Definition at line 61 of file pin_wavepci.cpp.

◆ m_Descriptor

SUBDEVICE_DESCRIPTOR CPortPinWavePci::m_Descriptor
protected

Definition at line 73 of file pin_wavepci.cpp.

Referenced by HandleKsProperty().

◆ m_DeviceObject

PDEVICE_OBJECT CPortPinWavePci::m_DeviceObject
protected

Definition at line 64 of file pin_wavepci.cpp.

◆ m_DmaChannel

PDMACHANNEL CPortPinWavePci::m_DmaChannel
protected

Definition at line 57 of file pin_wavepci.cpp.

◆ m_Filter

IPortFilterWavePci* CPortPinWavePci::m_Filter
protected

Definition at line 53 of file pin_wavepci.cpp.

◆ m_Format

PKSDATAFORMAT CPortPinWavePci::m_Format
protected

Definition at line 60 of file pin_wavepci.cpp.

◆ m_IrpQueue

IIrpQueue* CPortPinWavePci::m_IrpQueue
protected

Definition at line 65 of file pin_wavepci.cpp.

Referenced by HandleKsStream().

◆ m_KsPinDescriptor

KSPIN_DESCRIPTOR* CPortPinWavePci::m_KsPinDescriptor
protected

Definition at line 54 of file pin_wavepci.cpp.

◆ m_Miniport

PMINIPORTWAVEPCI CPortPinWavePci::m_Miniport
protected

Definition at line 55 of file pin_wavepci.cpp.

◆ m_Port

IPortWavePci* CPortPinWavePci::m_Port
protected

Definition at line 52 of file pin_wavepci.cpp.

◆ m_Position

KSAUDIO_POSITION CPortPinWavePci::m_Position
protected

Definition at line 68 of file pin_wavepci.cpp.

Referenced by HandleKsStream().

◆ m_PrefetchOffset

ULONG CPortPinWavePci::m_PrefetchOffset
protected

Definition at line 72 of file pin_wavepci.cpp.

◆ m_Ref

LONG CPortPinWavePci::m_Ref
protected

Definition at line 77 of file pin_wavepci.cpp.

Referenced by STDMETHODIMP_().

◆ m_ServiceGroup

PSERVICEGROUP CPortPinWavePci::m_ServiceGroup
protected

Definition at line 56 of file pin_wavepci.cpp.

◆ m_State

KSSTATE CPortPinWavePci::m_State
protected

Definition at line 59 of file pin_wavepci.cpp.

Referenced by HandleKsStream().

◆ m_StopCount

ULONG CPortPinWavePci::m_StopCount
protected

Definition at line 69 of file pin_wavepci.cpp.

◆ m_Stream

PMINIPORTWAVEPCISTREAM CPortPinWavePci::m_Stream
protected

Definition at line 58 of file pin_wavepci.cpp.

Referenced by HandleKsStream().

◆ m_TotalPackets

ULONG CPortPinWavePci::m_TotalPackets
protected

Definition at line 67 of file pin_wavepci.cpp.

Referenced by HandleKsStream().


The documentation for this class was generated from the following file: