17afe309b97b0789c9c69c9f4362a1fba01e0ce2
[reactos.git] / reactos / drivers / wdm / audio / backpln / portcls / private.h
1 /*
2 PortCls FDO Extension
3
4 by Andrew Greenwood
5 */
6
7 #ifndef PORTCLS_PRIVATE_H
8 #define PORTCLS_PRIVATE_H
9
10 #include <ntddk.h>
11 #include <portcls.h>
12 #include <debug.h>
13
14 #include <portcls.h>
15 #include <dmusicks.h>
16
17 #include "interfaces.h"
18 #include <ks.h>
19
20 #define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) + ((D)<<24))
21 #define TAG_PORTCLASS TAG('P', 'C', 'L', 'S')
22
23 #ifdef _MSC_VER
24 #define STDCALL
25 #define DDKAPI
26 #endif
27
28 NTSTATUS
29 NTAPI
30 PortClsCreate(
31 IN PDEVICE_OBJECT DeviceObject,
32 IN PIRP Irp);
33
34 NTSTATUS
35 NTAPI
36 PortClsPnp(
37 IN PDEVICE_OBJECT DeviceObject,
38 IN PIRP Irp);
39
40 NTSTATUS
41 NTAPI
42 PortClsPower(
43 IN PDEVICE_OBJECT DeviceObject,
44 IN PIRP Irp);
45
46 NTSTATUS
47 NTAPI
48 PortClsSysControl(
49 IN PDEVICE_OBJECT DeviceObject,
50 IN PIRP Irp);
51
52 NTSTATUS NewMiniportDMusUART(
53 OUT PMINIPORT* OutMiniport,
54 IN REFCLSID ClassId);
55
56 NTSTATUS NewMiniportFmSynth(
57 OUT PMINIPORT* OutMiniport,
58 IN REFCLSID ClassId);
59
60 NTSTATUS NewPortMidi(
61 OUT PPORT* OutPort);
62
63 NTSTATUS NewPortDMus(
64 OUT PPORT* OutPort);
65
66 NTSTATUS NewPortTopology(
67 OUT PPORT* OutPort);
68
69 NTSTATUS NewPortWaveCyclic(
70 OUT PPORT* OutPort);
71
72 NTSTATUS NewPortWavePci(
73 OUT PPORT* OutPort);
74
75 NTSTATUS NewIDrmPort(
76 OUT PDRMPORT2 *OutPort);
77
78 NTSTATUS NewPortClsVersion(
79 OUT PPORTCLSVERSION * OutVersion);
80
81 NTSTATUS NewPortFilterWaveCyclic(
82 OUT IPortFilterWaveCyclic ** OutFilter);
83
84 typedef struct
85 {
86 LIST_ENTRY Entry;
87 KSOBJECT_HEADER ObjectHeader;
88 }SUBDEVICE_ENTRY;
89
90 typedef struct
91 {
92 LIST_ENTRY Entry;
93 ISubdevice * FromSubDevice;
94 LPWSTR FromUnicodeString;
95 ULONG FromPin;
96 ISubdevice * ToSubDevice;
97 LPWSTR ToUnicodeString;
98 ULONG ToPin;
99 }PHYSICAL_CONNECTION;
100
101
102 typedef struct
103 {
104 PDEVICE_OBJECT PhysicalDeviceObject;
105 PCPFNSTARTDEVICE StartDevice;
106 KSDEVICE_HEADER KsDeviceHeader;
107 IAdapterPowerManagement * AdapterPowerManagement;
108
109 IResourceList* resources;
110 LIST_ENTRY SubDeviceList;
111 LIST_ENTRY PhysicalConnectionList;
112
113 } PCExtension;
114
115
116 NTSTATUS
117 NTAPI
118 PcDmaMasterDescription(
119 IN PRESOURCELIST ResourceList OPTIONAL,
120 IN BOOLEAN ScatterGather,
121 IN BOOLEAN Dma32BitAddresses,
122 IN BOOLEAN IgnoreCount,
123 IN BOOLEAN Dma64BitAddresses,
124 IN DMA_WIDTH DmaWidth,
125 IN DMA_SPEED DmaSpeed,
126 IN ULONG MaximumLength,
127 IN ULONG DmaPort,
128 OUT PDEVICE_DESCRIPTION DeviceDescription);
129
130 NTSTATUS
131 NTAPI
132 PcDmaSlaveDescription(
133 IN PRESOURCELIST ResourceList OPTIONAL,
134 IN ULONG DmaIndex,
135 IN BOOL DemandMode,
136 IN ULONG AutoInitialize,
137 IN DMA_SPEED DmaSpeed,
138 IN ULONG MaximumLength,
139 IN ULONG DmaPort,
140 OUT PDEVICE_DESCRIPTION DeviceDescription);
141
142
143
144 #endif