31 if (
This->BasicHeader.ClientAggregate)
34 Status =
This->BasicHeader.ClientAggregate->lpVtbl->QueryInterface(
This->BasicHeader.ClientAggregate, refiid,
Output);
43 DPRINT(
"IKsDevice_fnQueryInterface no interface\n");
78 return &
This->KsDevice;
97 Bag->BagMutex =
Mutex;
110 IN IKsDevice * iface)
120 IN IKsDevice * iface)
130 IN IKsDevice * iface,
138 *MaxMappingsByteCount =
This->MaxMappingsByteCount;
139 *MappingTableStride =
This->MappingTableStride;
148 IN IKsDevice * iface,
149 IN struct KSPOWER_ENTRY *
Entry,
161 IN IKsDevice * iface,
162 IN struct KSPOWER_ENTRY *
Entry)
174 IN IKsDevice * iface,
190 IN IKsDevice * iface,
214 IN IKsDevice * iface,
271 DPRINT(
"IKsDevice_PnpPostStart: PostStart Routine returned %x\n",
Status);
293 DeviceHeader = DeviceExtension->DeviceHeader;
295 DPRINT(
"IKsDevice_PnpStartDevice DeviceHeader %p\n", DeviceHeader);
307 DPRINT1(
"NextDevice object failed to start with %x\n",
Status);
318 if (DeviceHeader->
KsDevice.Descriptor)
321 if (DeviceHeader->
KsDevice.Descriptor->Dispatch)
324 if (DeviceHeader->
KsDevice.Descriptor->Dispatch->Start)
328 TranslatedResourceList,
329 UntranslatedResourceList);
332 DPRINT(
"IKsDevice_PnpStartDevice Start %p, Context %p\n", DeviceHeader->
KsDevice.Descriptor->Dispatch->Start, DeviceHeader->
KsDevice.Context);
349 if (DeviceHeader->
KsDevice.Descriptor->Dispatch->PostStart)
403 DPRINT(
"IKsDevice_PnpStartDevice Status %x PostStartRoutine %p\n",
Status, Ctx);
425 DeviceHeader = DeviceExtension->DeviceHeader;
506 DPRINT1(
"IRP_MN_QUERY_INTERFACE Device supports interface\n");
527 DPRINT(
"IRP_MN_FILTER_RESOURCE_REQUIREMENTS Next Device: Status %x\n",
Status);
558 Irp->IoStatus.Information = 0;
577 DPRINT(
"IKsDevice_Create\n");
583 DeviceHeader = DeviceExtension->DeviceHeader;
626 KSCREATE_ITEM_IRP_STORAGE(
Irp) = CreateItemEntry->
CreateItem;
674 Header = DeviceExtension->DeviceHeader;
676 DPRINT1(
"DeviceHeader %p\n", DeviceExtension->DeviceHeader);
689 DPRINT(
"Descriptor QueryCapabilities %p\n",
Descriptor->Dispatch->QueryCapabilities);
690 DPRINT(
"Descriptor SurpriseRemoval %p\n",
Descriptor->Dispatch->SurpriseRemoval);
693 DPRINT(
"Descriptor QueryInterface %p\n",
Descriptor->Dispatch->QueryInterface);
699 DPRINT1(
"KsInitializeDevice Failed to allocate device header with %x\n",
Status);
709 if (!
Header->KsDevice.Bag)
745 DPRINT(
"KsInitializeDevice FilterDescriptorCount %lu\n",
Descriptor->FilterDescriptorsCount);
750 DPRINT(
"KsInitializeDevice Index %lu KspCreateFilterFactory Status %lx\n",
Index,
Status);
857 DPRINT(
"KsDereferenceSoftwareBusObject DeviceHeader %p\n",
Header);
static PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(PIRP Irp)
#define InterlockedIncrement
#define InterlockedDecrement
PDEVICE_OBJECT PhysicalDeviceObject
#define STATUS_NOT_SUPPORTED
#define STATUS_NOT_IMPLEMENTED
NTSTATUS KspSetFilterFactoriesState(IN PKSIDEVICE_HEADER DeviceHeader, IN BOOLEAN NewState)
#define NT_SUCCESS(StatCode)
BOOL WINAPI SHIM_OBJ_NAME() Notify(DWORD fdwReason, PVOID ptr)
struct _BEEP_DEVICE_EXTENSION * PDEVICE_EXTENSION
NTSTATUS NTAPI CompleteRequest(IN PIRP Irp, IN NTSTATUS Status, IN ULONG_PTR Information)
KSDDKAPI VOID NTAPI KsSetDevicePnpAndBaseObject(IN KSDEVICE_HEADER Header, IN PDEVICE_OBJECT PnpDeviceObject, IN PDEVICE_OBJECT BaseDevice)
KSDDKAPI NTSTATUS NTAPI KsAllocateDeviceHeader(OUT KSDEVICE_HEADER *OutHeader, IN ULONG ItemsCount, IN PKSOBJECT_CREATE_ITEM ItemsList OPTIONAL)
KSDDKAPI VOID NTAPI KsFreeDeviceHeader(IN KSDEVICE_HEADER DevHeader)
NTSTATUS NTAPI IKsDevice_Power(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
NTSTATUS NTAPI IKsDevice_fnPinStateChange(IN IKsDevice *iface, IN KSPIN Pin, IN PIRP Irp, IN KSSTATE OldState, IN KSSTATE NewState)
NTSTATUS NTAPI IKsDevice_fnAddPowerEntry(IN IKsDevice *iface, IN struct KSPOWER_ENTRY *Entry, IN IKsPowerNotify *Notify)
NTSTATUS NTAPI IKsDevice_fnReleaseDevice(IN IKsDevice *iface)
KSDDKAPI NTSTATUS NTAPI KsReferenceSoftwareBusObject(IN KSDEVICE_HEADER Header)
PKSDEVICE NTAPI IKsDevice_fnGetStruct(IN IKsDevice *iface)
ULONG NTAPI IKsDevice_fnAddRef(IN IKsDevice *iface)
KSDDKAPI NTSTATUS NTAPI KsInitializeDevice(IN PDEVICE_OBJECT FunctionalDeviceObject, IN PDEVICE_OBJECT PhysicalDeviceObject, IN PDEVICE_OBJECT NextDeviceObject, IN const KSDEVICE_DESCRIPTOR *Descriptor OPTIONAL)
ULONG NTAPI IKsDevice_fnRelease(IN IKsDevice *iface)
NTSTATUS NTAPI IKsDevice_fnQueryInterface(IN IKsDevice *iface, REFIID refiid, PVOID *Output)
NTSTATUS NTAPI IKsDevice_fnInitializeObjectBag(IN IKsDevice *iface, IN PKSIOBJECT_BAG Bag, IN PRKMUTEX Mutex)
NTSTATUS NTAPI IKsDevice_Create(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
KSDDKAPI VOID NTAPI KsDereferenceSoftwareBusObject(IN KSDEVICE_HEADER Header)
NTSTATUS NTAPI IKsDevice_fnCheckIoCapability(IN IKsDevice *iface, IN ULONG Unknown)
KSDDKAPI VOID NTAPI KsDereferenceBusObject(IN KSDEVICE_HEADER Header)
NTSTATUS NTAPI IKsDevice_fnAcquireDevice(IN IKsDevice *iface)
KSDDKAPI NTSTATUS NTAPI KsReferenceBusObject(IN KSDEVICE_HEADER Header)
static IKsDeviceVtbl vt_IKsDevice
NTSTATUS NTAPI IKsDevice_Pnp(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
NTSTATUS NTAPI IKsDevice_PnpStartDevice(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
NTSTATUS NTAPI IKsDevice_fnArbitrateAdapterChannel(IN IKsDevice *iface, IN ULONG NumberOfMapRegisters, IN PDRIVER_CONTROL ExecutionRoutine, IN PVOID Context)
NTSTATUS NTAPI IKsDevice_fnRemovePowerEntry(IN IKsDevice *iface, IN struct KSPOWER_ENTRY *Entry)
NTSTATUS NTAPI IKsDevice_fnGetAdapterObject(IN IKsDevice *iface, IN PADAPTER_OBJECT *Object, IN PULONG MaxMappingsByteCount, IN PULONG MappingTableStride)
VOID NTAPI IKsDevice_PnpPostStart(IN PDEVICE_OBJECT DeviceObject, IN PVOID Context)
NTSTATUS FindMatchingCreateItem(PLIST_ENTRY ListHead, PUNICODE_STRING String, OUT PCREATE_ITEM_ENTRY *OutCreateItem)
#define InsertTailList(ListHead, Entry)
#define KeWaitForSingleObject(pEvt, foo, a, b, c)
#define KeGetCurrentIrql()
#define InitializeListHead(ListHead)
IN PDCB IN VBO IN ULONG IN BOOLEAN Pin
NTSTATUS NTAPI KspCreateFilterFactory(IN PDEVICE_OBJECT DeviceObject, IN const KSFILTER_DESCRIPTOR *Descriptor, IN PWSTR RefString OPTIONAL, IN PSECURITY_DESCRIPTOR SecurityDescriptor OPTIONAL, IN ULONG CreateItemFlags, IN PFNKSFILTERFACTORYPOWER SleepCallback OPTIONAL, IN PFNKSFILTERFACTORYPOWER WakeCallback OPTIONAL, OUT PKSFILTERFACTORY *FilterFactory OPTIONAL)
long __cdecl _InterlockedIncrement(_Interlocked_operand_ long volatile *_Addend)
VOID NTAPI IoQueueWorkItem(IN PIO_WORKITEM IoWorkItem, IN PIO_WORKITEM_ROUTINE WorkerRoutine, IN WORK_QUEUE_TYPE QueueType, IN PVOID Context)
VOID NTAPI IoFreeWorkItem(IN PIO_WORKITEM IoWorkItem)
PIO_WORKITEM NTAPI IoAllocateWorkItem(IN PDEVICE_OBJECT DeviceObject)
@ KSTARGET_STATE_DISABLED
PVOID AllocateItem(IN POOL_TYPE PoolType, IN SIZE_T NumberOfBytes)
VOID FreeItem(IN PVOID Item)
struct KSIOBJECT_BAG * PKSIOBJECT_BAG
struct KSIOBJECT_HEADER * PKSIOBJECT_HEADER
struct PNP_POSTSTART_CONTEXT * PPNP_POSTSTART_CONTEXT
struct KSIDEVICE_HEADER * PKSIDEVICE_HEADER
_Inout_opt_ PDEVICE_OBJECT _Inout_opt_ PDEVICE_OBJECT * FunctionalDeviceObject
_Inout_opt_ PDEVICE_OBJECT _Inout_opt_ PDEVICE_OBJECT _Inout_opt_ PDEVICE_OBJECT * NextDeviceObject
#define IoSkipCurrentIrpStackLocation(Irp)
NTSTATUS NTAPI IoAllocateAdapterChannel(IN PADAPTER_OBJECT AdapterObject, IN PDEVICE_OBJECT DeviceObject, IN ULONG NumberOfMapRegisters, IN PDRIVER_CONTROL ExecutionRoutine, IN PVOID Context)
#define IoCompleteRequest
BOOLEAN NTAPI IoForwardIrpSynchronously(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
VOID NTAPI KeInitializeMutex(IN PKMUTEX Mutex, IN ULONG Level)
LONG NTAPI KeReleaseMutex(IN PKMUTEX Mutex, IN BOOLEAN Wait)
PULONG MinorVersion OPTIONAL
PKSOBJECT_CREATE_ITEM CreateItem
base of all file and directory entries
PKSIDEVICE_HEADER DeviceHeader
union _IO_STACK_LOCATION::@1581 Parameters
struct _IO_STACK_LOCATION::@3980::@4017 StartDevice
#define CONTAINING_RECORD(address, type, field)
#define STATUS_UNSUCCESSFUL
#define STATUS_INSUFFICIENT_RESOURCES
_Must_inspect_result_ _In_ WDFDEVICE Device
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
_In_ WDFCOLLECTION _In_ ULONG Index
_In_ PDEVICE_OBJECT DeviceObject
_Must_inspect_result_ _In_ WDFIORESLIST _In_ PIO_RESOURCE_DESCRIPTOR Descriptor
#define IsEqualGUIDAligned(guid1, guid2)
_In_ USHORT _In_ ULONG _In_ PSOCKADDR _In_ PSOCKADDR _Reserved_ ULONG _In_opt_ PVOID _In_opt_ const WSK_CLIENT_CONNECTION_DISPATCH * Dispatch
_Out_ PULONG NumberOfMapRegisters
_In_ PDEVICE_OBJECT _In_ ULONG _In_ PDRIVER_CONTROL ExecutionRoutine
#define IRP_MN_QUERY_INTERFACE
#define IRP_MN_START_DEVICE
#define IRP_MN_QUERY_RESOURCE_REQUIREMENTS
#define IRP_MN_REMOVE_DEVICE
#define IRP_MN_FILTER_RESOURCE_REQUIREMENTS
#define IRP_MN_QUERY_DEVICE_RELATIONS
DRIVER_CONTROL * PDRIVER_CONTROL
#define IRP_MN_QUERY_STOP_DEVICE