Author: sginsberg
Date: Sat Jul 25 16:06:06 2009
New Revision: 42208
URL:
http://svn.reactos.org/svn/reactos?rev=42208&view=rev
Log:
- Make ks and portcls compile under msvc
Modified:
trunk/reactos/drivers/ksfilter/ks/irp.c
trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c
trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h
trunk/reactos/include/ddk/portcls.h
trunk/reactos/include/ddk/stdunk.h
trunk/reactos/include/psdk/ks.h
Modified: trunk/reactos/drivers/ksfilter/ks/irp.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/irp.c?…
==============================================================================
--- trunk/reactos/drivers/ksfilter/ks/irp.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/ksfilter/ks/irp.c [iso-8859-1] Sat Jul 25 16:06:06 2009
@@ -1206,8 +1206,8 @@
return STATUS_NOT_FOUND;
}
-NTAPI
-NTSTATUS
+NTSTATUS
+NTAPI
KspCreate(
IN PDEVICE_OBJECT DeviceObject,
IN PIRP Irp)
@@ -1390,8 +1390,8 @@
}
-NTAPI
-NTSTATUS
+NTSTATUS
+NTAPI
KspDeviceControl(
IN PDEVICE_OBJECT DeviceObject,
IN PIRP Irp)
@@ -1425,8 +1425,8 @@
return ObjectHeader->DispatchTable.DeviceIoControl(DeviceObject, Irp);
}
-NTAPI
-NTSTATUS
+NTSTATUS
+NTAPI
KspDispatchIrp(
IN PDEVICE_OBJECT DeviceObject,
IN PIRP Irp)
Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
==============================================================================
--- trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c [iso-8859-1] Sat Jul 25
16:06:06 2009
@@ -154,8 +154,8 @@
return STATUS_UNSUCCESSFUL;
}
-NTAPI
PKINTERRUPT
+NTAPI
IInterruptSync_fnGetKInterrupt(
IN IInterruptSync * iface)
{
Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
==============================================================================
--- trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h [iso-8859-1] Sat Jul 25
16:06:06 2009
@@ -25,11 +25,6 @@
#define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) +
((D)<<24))
#define TAG_PORTCLASS TAG('P', 'C', 'L', 'S')
-
-#ifdef _MSC_VER
- #define STDCALL
- #define DDKAPI
-#endif
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
Modified: trunk/reactos/include/ddk/portcls.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/portcls.h?rev=…
==============================================================================
--- trunk/reactos/include/ddk/portcls.h [iso-8859-1] (original)
+++ trunk/reactos/include/ddk/portcls.h [iso-8859-1] Sat Jul 25 16:06:06 2009
@@ -239,7 +239,7 @@
typedef struct _PCPROPERTY_REQUEST PCPROPERTY_REQUEST, *PPCPROPERTY_REQUEST;
-typedef NTSTATUS NTAPI(*PCPFNPROPERTY_HANDLER)(
+typedef NTSTATUS (NTAPI *PCPFNPROPERTY_HANDLER)(
IN PPCPROPERTY_REQUEST PropertyRequest);
typedef struct
@@ -281,7 +281,7 @@
struct _PCEVENT_REQUEST;
-typedef NTSTATUS NTAPI(*PCPFNEVENT_HANDLER)(
+typedef NTSTATUS (NTAPI *PCPFNEVENT_HANDLER)(
IN struct _PCEVENT_REQUEST* EventRequest);
typedef struct _PCEVENT_ITEM
@@ -307,7 +307,7 @@
struct _PCMETHOD_REQUEST;
-typedef NTSTATUS NTAPI(*PCPFNMETHOD_HANDLER)(
+typedef NTSTATUS (NTAPI *PCPFNMETHOD_HANDLER)(
IN struct _PCMETHOD_REQUEST* MethodRequest);
typedef struct _PCMETHOD_ITEM
@@ -834,7 +834,7 @@
struct IInterruptSync;
-typedef NTSTATUS NTAPI(*PINTERRUPTSYNCROUTINE)(
+typedef NTSTATUS (NTAPI *PINTERRUPTSYNCROUTINE)(
IN struct IInterruptSync* InterruptSync,
IN PVOID DynamicContext);
@@ -2048,7 +2048,7 @@
PortCls API Functions
*/
-typedef NTSTATUS NTAPI(*PCPFNSTARTDEVICE)(
+typedef NTSTATUS (NTAPI *PCPFNSTARTDEVICE)(
IN PDEVICE_OBJECT DeviceObject,
IN PIRP Irp,
IN PRESOURCELIST ResourceList);
Modified: trunk/reactos/include/ddk/stdunk.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/stdunk.h?rev=4…
==============================================================================
--- trunk/reactos/include/ddk/stdunk.h [iso-8859-1] (original)
+++ trunk/reactos/include/ddk/stdunk.h [iso-8859-1] Sat Jul 25 16:06:06 2009
@@ -94,20 +94,20 @@
#else /* Not C++ - this is probably very buggy... */
+NTSTATUS
STDMETHODCALLTYPE
-NTSTATUS
Unknown_QueryInterface(
IUnknown* this,
IN REFIID refiid,
OUT PVOID* output);
+ULONG
STDMETHODCALLTYPE
-ULONG
Unknown_AddRef(
IUnknown* unknown_this);
+ULONG
STDMETHODCALLTYPE
-ULONG
Unknown_Release(
IUnknown* unknown_this);
Modified: trunk/reactos/include/psdk/ks.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/ks.h?rev=4220…
==============================================================================
--- trunk/reactos/include/psdk/ks.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/ks.h [iso-8859-1] Sat Jul 25 16:06:06 2009
@@ -1104,7 +1104,7 @@
#if defined(_NTDDK_)
/* MOVE ME */
-typedef NTSTATUS NTAPI NTAPI (*PFNKSCONTEXT_DISPATCH)(
+typedef NTSTATUS (NTAPI *PFNKSCONTEXT_DISPATCH)(
IN PVOID Context,
IN PIRP Irp);
#endif
@@ -1260,21 +1260,19 @@
typedef
VOID
-NTAPI
-(*PFNREFERENCEDEVICEOBJECT)(
+(NTAPI *PFNREFERENCEDEVICEOBJECT)(
IN PVOID Context
);
typedef
VOID
-NTAPI
-(*PFNDEREFERENCEDEVICEOBJECT)(
+(NTAPI *PFNDEREFERENCEDEVICEOBJECT)(
IN PVOID Context
);
typedef
NTSTATUS
-(*PFNQUERYREFERENCESTRING)(
+(NTAPI *PFNQUERYREFERENCESTRING)(
IN PVOID Context,
IN OUT PWCHAR *String
);
@@ -1438,7 +1436,7 @@
} KSPROPERTY_VALUES, *PKSPROPERTY_VALUES;
#if defined(_NTDDK_)
-typedef NTSTATUS NTAPI(*PFNKSHANDLER)(
+typedef NTSTATUS (NTAPI *PFNKSHANDLER)(
IN PIRP Irp,
IN PKSIDENTIFIER Request,
IN OUT PVOID Data);
@@ -1467,8 +1465,7 @@
typedef
BOOLEAN
-NTAPI
-(*PFNKSFASTHANDLER)(
+(NTAPI *PFNKSFASTHANDLER)(
IN PFILE_OBJECT FileObject,
IN PKSIDENTIFIER Request,
IN ULONG RequestLength,
@@ -1870,15 +1867,14 @@
LONGLONG Interval;
} KSEVENT_TIME_INTERVAL, *PKSEVENT_TIME_INTERVAL;
-typedef NTSTATUS NTAPI (*PFNKSADDEVENT)(
+typedef NTSTATUS (NTAPI *PFNKSADDEVENT)(
IN PIRP Irp,
IN PKSEVENTDATA EventData,
IN struct _KSEVENT_ENTRY* EventEntry);
typedef
VOID
-NTAPI
-(*PFNKSREMOVEEVENT)(
+(NTAPI *PFNKSREMOVEEVENT)(
IN PFILE_OBJECT FileObject,
IN struct _KSEVENT_ENTRY* EventEntry
);
@@ -1941,8 +1937,7 @@
typedef
NTSTATUS
-NTAPI
-(*PFNKSPINHANDSHAKE)(
+(NTAPI *PFNKSPINHANDSHAKE)(
IN PKSPIN Pin,
IN PKSHANDSHAKE In,
IN PKSHANDSHAKE Out
@@ -1950,16 +1945,14 @@
typedef
void
-NTAPI
-(*PFNKSPINPOWER)(
+(NTAPI *PFNKSPINPOWER)(
IN PKSPIN Pin,
IN DEVICE_POWER_STATE State
);
typedef
void
-NTAPI
-(*PFNKSPINFRAMERETURN)(
+(NTAPI *PFNKSPINFRAMERETURN)(
IN PKSPIN Pin,
IN PVOID Data OPTIONAL,
IN ULONG Size OPTIONAL,
@@ -1970,38 +1963,33 @@
typedef
void
-NTAPI
-(*PFNKSPINIRPCOMPLETION)(
+(NTAPI *PFNKSPINIRPCOMPLETION)(
IN PKSPIN Pin,
IN PIRP Irp
);
typedef
NTSTATUS
-NTAPI
-(*PFNKSPINIRP)(
+(NTAPI *PFNKSPINIRP)(
IN PKSPIN Pin,
IN PIRP Irp
);
typedef
NTSTATUS
-NTAPI
-(*PFNKSPIN)(
+(NTAPI *PFNKSPIN)(
IN PKSPIN Pin
);
typedef
void
-NTAPI
-(*PFNKSPINVOID)(
+(NTAPI *PFNKSPINVOID)(
IN PKSPIN Pin
);
typedef
void
-NTAPI
-(*PFNKSSTREAMPOINTER)(
+(NTAPI *PFNKSSTREAMPOINTER)(
IN PKSSTREAM_POINTER StreamPointer
);
@@ -2012,8 +2000,7 @@
typedef
NTSTATUS
-NTAPI
-(*PFNKSPINSETDATAFORMAT)(
+(NTAPI *PFNKSPINSETDATAFORMAT)(
IN PKSPIN Pin,
IN PKSDATAFORMAT OldFormat OPTIONAL,
IN PKSMULTIPLE_ITEM OldAttributeList OPTIONAL,
@@ -2023,8 +2010,7 @@
typedef
NTSTATUS
-NTAPI
-(*PFNKSPINSETDEVICESTATE)(
+(NTAPI *PFNKSPINSETDEVICESTATE)(
IN PKSPIN Pin,
IN KSSTATE ToState,
IN KSSTATE FromState
@@ -2049,7 +2035,7 @@
typedef
BOOLEAN
-NTAPI (*PFNKSPINSETTIMER)(
+(NTAPI *PFNKSPINSETTIMER)(
IN PKSPIN Pin,
IN PKTIMER Timer,
IN LARGE_INTEGER DueTime,
@@ -2058,7 +2044,7 @@
typedef
BOOLEAN
-NTAPI (*PFNKSPINCANCELTIMER)(
+(NTAPI *PFNKSPINCANCELTIMER)(
IN PKSPIN Pin,
IN PKTIMER Timer
);
@@ -2072,7 +2058,7 @@
typedef
void
-NTAPI (*PFNKSPINRESOLUTION)(
+(NTAPI *PFNKSPINRESOLUTION)(
IN PKSPIN Pin,
OUT PKSRESOLUTION Resolution
);
@@ -2086,19 +2072,19 @@
typedef
NTSTATUS
-NTAPI (*PFNKSPININITIALIZEALLOCATOR)(
+(NTAPI *PFNKSPININITIALIZEALLOCATOR)(
IN PKSPIN Pin,
IN PKSALLOCATOR_FRAMING AllocatorFraming,
OUT PVOID* Context
);
-typedef PVOID NTAPI (*PFNKSDELETEALLOCATOR)(
+typedef PVOID (NTAPI *PFNKSDELETEALLOCATOR)(
IN PVOID Context);
-typedef PVOID NTAPI (*PFNKSDEFAULTALLOCATE)(
+typedef PVOID (NTAPI *PFNKSDEFAULTALLOCATE)(
IN PVOID Context);
-typedef PVOID NTAPI (*PFNKSDEFAULTFREE)(
+typedef PVOID (NTAPI *PFNKSDEFAULTFREE)(
IN PVOID Context,
IN PVOID Buffer);
@@ -2150,7 +2136,7 @@
typedef
NTSTATUS
-NTAPI (*PFNKSINTERSECTHANDLER)(
+(NTAPI *PFNKSINTERSECTHANDLER)(
IN PIRP Irp,
IN PKSP_PIN Pin,
IN PKSDATARANGE DataRange,
@@ -2159,7 +2145,7 @@
typedef
NTSTATUS
-NTAPI (*PFNKSINTERSECTHANDLEREX)(
+(NTAPI *PFNKSINTERSECTHANDLEREX)(
IN PVOID Context,
IN PIRP Irp,
IN PKSP_PIN Pin,
@@ -2380,7 +2366,7 @@
typedef
void
-NTAPI (*PFNKSFREE)(
+(NTAPI *PFNKSFREE)(
IN PVOID Data
);
@@ -2472,18 +2458,18 @@
/* TODO */
typedef void* UNKNOWN;
-typedef PVOID NTAPI(*PFNKSINITIALIZEALLOCATOR)(
+typedef PVOID (NTAPI *PFNKSINITIALIZEALLOCATOR)(
IN PVOID InitialContext,
IN PKSALLOCATOR_FRAMING AllocatorFraming,
OUT PVOID* Context);
#if defined(_NTDDK_)
-typedef NTSTATUS NTAPI (*PFNKSALLOCATOR)(
+typedef NTSTATUS (NTAPI *PFNKSALLOCATOR)(
IN PIRP Irp,
IN ULONG BufferSize,
IN BOOLEAN InputOperation);
-typedef NTSTATUS NTAPI (*PFNKINTERSECTHANDLEREX)(
+typedef NTSTATUS (NTAPI *PFNKINTERSECTHANDLEREX)(
IN PVOID Context,
IN PIRP Irp,
IN PKSP_PIN Pin,
@@ -2496,16 +2482,14 @@
typedef
NTSTATUS
-NTAPI
-NTAPI (*PFNALLOCATOR_ALLOCATEFRAME)(
+(NTAPI *PFNALLOCATOR_ALLOCATEFRAME)(
IN PFILE_OBJECT FileObject,
PVOID *Frame
);
typedef
VOID
-NTAPI
-NTAPI (*PFNALLOCATOR_FREEFRAME)(
+(NTAPI *PFNALLOCATOR_FREEFRAME)(
IN PFILE_OBJECT FileObject,
IN PVOID Frame
);
@@ -2632,32 +2616,32 @@
typedef struct _KSFILTER_DESCRIPTOR KSFILTER_DESCRIPTOR, *PKSFILTER_DESCRIPTOR;
typedef struct _KSDEVICE_DESCRIPTOR KSDEVICE_DESCRIPTOR, *PKSDEVICE_DESCRIPTOR;
-typedef NTSTATUS NTAPI (*PFNKSDEVICECREATE)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICECREATE)(
IN PKSDEVICE Device);
-typedef NTSTATUS NTAPI (*PFNKSDEVICEPNPSTART)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICEPNPSTART)(
IN PKSDEVICE Device,
IN PIRP Irp,
IN PCM_RESOURCE_LIST TranslatedResourceList OPTIONAL,
IN PCM_RESOURCE_LIST UntranslatedResourceList OPTIONAL);
-typedef NTSTATUS NTAPI (*PFNKSDEVICE)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICE)(
IN PKSDEVICE Device);
-typedef NTSTATUS NTAPI (*PFNKSDEVICEIRP)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICEIRP)(
IN PKSDEVICE Device,
IN PIRP Irp);
-typedef VOID NTAPI (*PFNKSDEVICEIRPVOID)(
+typedef VOID (NTAPI *PFNKSDEVICEIRPVOID)(
IN PKSDEVICE Device,
IN PIRP Irp);
-typedef NTSTATUS NTAPI (*PFNKSDEVICEQUERYCAPABILITIES)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICEQUERYCAPABILITIES)(
IN PKSDEVICE Device,
IN PIRP Irp,
IN OUT PDEVICE_CAPABILITIES Capabilities);
-typedef NTSTATUS NTAPI (*PFNKSDEVICEQUERYPOWER)(
+typedef NTSTATUS (NTAPI *PFNKSDEVICEQUERYPOWER)(
IN PKSDEVICE Device,
IN PIRP Irp,
IN DEVICE_POWER_STATE DeviceTo,
@@ -2666,7 +2650,7 @@
IN SYSTEM_POWER_STATE SystemFrom,
IN POWER_ACTION Action);
-typedef VOID NTAPI (*PFNKSDEVICESETPOWER)(
+typedef VOID (NTAPI *PFNKSDEVICESETPOWER)(
IN PKSDEVICE Device,
IN PIRP Irp,
IN DEVICE_POWER_STATE To,
@@ -2721,20 +2705,20 @@
typedef
void
-NTAPI (*PFNKSFILTERPOWER)(
+(NTAPI *PFNKSFILTERPOWER)(
IN PKSFILTER Filter,
IN DEVICE_POWER_STATE State
);
-typedef NTSTATUS NTAPI (*PFNKSFILTERIRP)(
+typedef NTSTATUS (NTAPI *PFNKSFILTERIRP)(
IN PKSFILTER Filter,
IN PIRP Irp);
-typedef NTSTATUS NTAPI (*PFNKSFILTERPROCESS)(
+typedef NTSTATUS (NTAPI *PFNKSFILTERPROCESS)(
IN PKSFILTER Filter,
IN PKSPROCESSPIN_INDEXENTRY ProcessPinsIndex);
-typedef NTSTATUS NTAPI (*PFNKSFILTERVOID)(
+typedef NTSTATUS (NTAPI *PFNKSFILTERVOID)(
IN PKSFILTER Filter);
struct _KSFILTER_DISPATCH
@@ -2792,12 +2776,12 @@
Minidriver Callbacks
*/
#if defined(_NTDDK_)
-typedef NTSTATUS NTAPI (*KStrMethodHandler)(
+typedef NTSTATUS (NTAPI *KStrMethodHandler)(
IN PIRP Irp,
IN PKSIDENTIFIER Request,
IN OUT PVOID Data);
-typedef NTSTATUS NTAPI (*KStrSupportHandler)(
+typedef NTSTATUS (NTAPI *KStrSupportHandler)(
IN PIRP Irp,
IN PKSIDENTIFIER Request,
IN OUT PVOID Data);
@@ -2842,13 +2826,13 @@
Clock Functions
*/
#if defined(_NTDDK_)
-typedef BOOLEAN NTAPI (*PFNKSSETTIMER)(
+typedef BOOLEAN (NTAPI *PFNKSSETTIMER)(
IN PVOID Context,
IN PKTIMER Timer,
IN LARGE_INTEGER DueTime,
IN PKDPC Dpc);
-typedef BOOLEAN NTAPI (*PFNKSCANCELTIMER)(
+typedef BOOLEAN (NTAPI *PFNKSCANCELTIMER)(
IN PVOID Context,
IN PKTIMER Timer);
@@ -3014,7 +2998,7 @@
typedef
BOOLEAN
-NTAPI (*PFNKSGENERATEEVENTCALLBACK)(
+(NTAPI *PFNKSGENERATEEVENTCALLBACK)(
IN PVOID Context,
IN PKSEVENT_ENTRY EventEntry
);
@@ -3165,7 +3149,7 @@
IRP Helper Functions
*/
-typedef NTSTATUS NTAPI (*PFNKSIRPLISTCALLBACK)(
+typedef NTSTATUS (NTAPI *PFNKSIRPLISTCALLBACK)(
IN PIRP Irp,
IN PVOID Context);
@@ -3598,7 +3582,7 @@
IN const KSDEVICE_DESCRIPTOR* Descriptor OPTIONAL);
-typedef void NTAPI (*PFNKSFILTERFACTORYPOWER)(
+typedef void (NTAPI *PFNKSFILTERFACTORYPOWER)(
IN PKSFILTERFACTORY FilterFactory,
IN DEVICE_POWER_STATE State);
@@ -3886,7 +3870,7 @@
KsFilterAddTopologyConnections(
IN PKSFILTER Filter,
IN ULONG NewConnectionsCount,
- IN const KSTOPOLOGY_CONNECTION* NewTopologyConnections);
+ IN const KSTOPOLOGY_CONNECTION *const NewTopologyConnections);
KSDDKAPI
VOID
@@ -3900,7 +3884,7 @@
NTAPI
KsFilterCreateNode(
IN PKSFILTER Filter,
- IN const KSNODE_DESCRIPTOR* NodeDescriptor,
+ IN const KSNODE_DESCRIPTOR *const NodeDescriptor,
OUT PULONG NodeID);
KSDDKAPI
@@ -3908,7 +3892,7 @@
NTAPI
KsFilterCreatePinFactory(
IN PKSFILTER Filter,
- IN const KSPIN_DESCRIPTOR_EX* PinDescriptor,
+ IN const KSPIN_DESCRIPTOR_EX *const PinDescriptor,
OUT PULONG PinID);
KSDDKAPI