ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
April 2010
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
22 participants
435 discussions
Start a n
N
ew thread
[janderwald] 46685: [KS] - Instantiated pins use as the control mutex the mutex from the filter - Fix KsAcquireControl & KsReleaseControl - Fix handling of IRP_MN_QUERY_INTERFACE - Filter centric ks filters expect an array of KSPROCESSPIN_INDEXENTRY. Allocate array when intializing filter / new pin factory is added - Store result of pin intersection handler when result is STATUS_BUFFER_OVERFLOW - Implement setting / retrieving of master clock - Implement setting / retrieving pin state - Partly i
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 2 18:38:48 2010 New Revision: 46685 URL:
http://svn.reactos.org/svn/reactos?rev=46685&view=rev
Log: [KS] - Instantiated pins use as the control mutex the mutex from the filter - Fix KsAcquireControl & KsReleaseControl - Fix handling of IRP_MN_QUERY_INTERFACE - Filter centric ks filters expect an array of KSPROCESSPIN_INDEXENTRY. Allocate array when intializing filter / new pin factory is added - Store result of pin intersection handler when result is STATUS_BUFFER_OVERFLOW - Implement setting / retrieving of master clock - Implement setting / retrieving pin state - Partly implement setting pin data format - Implement IKsReferenceClock interface - Implement KsPinGetReferenceClockInterface - Add sanity checks to KsGetPinFromIrp - Partly implement handling IOCTL_KS_READ_STREAM / IOCTL_KS_WRITE_STREAM - Supply filter property sets when an IOCTL_KS_PROPERTY request arrives - Release again filter mutex when closing the pin - Implement allocating a clock - Tuner pin fails with STATUS_IO_DEVICE_ERROR when set to KSSTATE_RUN, needs more investigation Modified: trunk/reactos/drivers/ksfilter/ks/api.c trunk/reactos/drivers/ksfilter/ks/device.c trunk/reactos/drivers/ksfilter/ks/driver.c trunk/reactos/drivers/ksfilter/ks/filter.c trunk/reactos/drivers/ksfilter/ks/filterfactory.c trunk/reactos/drivers/ksfilter/ks/kstypes.h trunk/reactos/drivers/ksfilter/ks/pin.c trunk/reactos/drivers/ksfilter/ks/priv.h trunk/reactos/drivers/ksfilter/ks/property.c Modified: trunk/reactos/drivers/ksfilter/ks/api.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/api.c?…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/api.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/api.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -1589,7 +1589,7 @@ /* sanity check */ ASSERT(BasicHeader->Type == KsObjectTypeFilter || BasicHeader->Type == KsObjectTypePin); - KeWaitForSingleObject(&BasicHeader->ControlMutex, Executive, KernelMode, FALSE, NULL); + KeWaitForSingleObject(BasicHeader->ControlMutex, Executive, KernelMode, FALSE, NULL); } @@ -1606,7 +1606,7 @@ /* sanity check */ ASSERT(BasicHeader->Type == KsObjectTypeFilter || BasicHeader->Type == KsObjectTypePin); - KeReleaseMutex(&BasicHeader->ControlMutex, FALSE); + KeReleaseMutex(BasicHeader->ControlMutex, FALSE); } Modified: trunk/reactos/drivers/ksfilter/ks/device.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/device…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/device.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/device.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -492,7 +492,7 @@ } case IRP_MN_QUERY_INTERFACE: { - Status = STATUS_SUCCESS; + Status = STATUS_UNSUCCESSFUL; /* check for pnp notification support */ if (Dispatch) { @@ -508,6 +508,7 @@ if (NT_SUCCESS(Status)) { /* driver supports a private interface */ + DPRINT1("IRP_MN_QUERY_INTERFACE Device supports interface\n"); Irp->IoStatus.Status = Status; IoCompleteRequest(Irp, IO_NO_INCREMENT); return Status; Modified: trunk/reactos/drivers/ksfilter/ks/driver.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/driver…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/driver.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/driver.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -39,10 +39,10 @@ { PKSBASIC_HEADER BasicHeader = (PKSBASIC_HEADER)((ULONG_PTR)Object - sizeof(KSBASIC_HEADER)); - DPRINT("KsGetDevice %p BasicHeader %p Type %x\n", Object, BasicHeader, BasicHeader->Type); - - ASSERT(BasicHeader->Type == KsObjectTypeFilterFactory || BasicHeader->Type == KsObjectTypeFilter || BasicHeader->Type == BasicHeader->Type); + ASSERT(BasicHeader->Type == KsObjectTypeFilterFactory || BasicHeader->Type == KsObjectTypeFilter || BasicHeader->Type == KsObjectTypePin); ASSERT(BasicHeader->KsDevice); + ASSERT(BasicHeader->KsDevice->Started); + ASSERT(BasicHeader->KsDevice->PhysicalDeviceObject); return BasicHeader->KsDevice; } Modified: trunk/reactos/drivers/ksfilter/ks/filter.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/filter…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/filter.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/filter.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -26,6 +26,7 @@ ULONG PinDescriptorCount; PKSFILTERFACTORY Factory; PFILE_OBJECT FileObject; + KMUTEX ControlMutex; KMUTEX ProcessingMutex; @@ -34,7 +35,7 @@ ULONG *PinInstanceCount; PKSPIN * FirstPin; - KSPROCESSPIN_INDEXENTRY ProcessPinIndex; + PKSPROCESSPIN_INDEXENTRY ProcessPinIndex; }IKsFilterImpl; @@ -294,18 +295,20 @@ /* first acquire processing mutex */ KeWaitForSingleObject(&This->ProcessingMutex, Executive, KernelMode, FALSE, NULL); - /* edit process pin descriptor */ - Status = _KsEdit(This->Filter.Bag, - (PVOID*)&This->ProcessPinIndex.Pins, - (This->ProcessPinIndex.Count + 1) * sizeof(PKSPROCESSPIN), - (This->ProcessPinIndex.Count) * sizeof(PKSPROCESSPIN), + /* sanity check */ + ASSERT(This->PinDescriptorCount > ProcessPin->Pin->Id); + + /* allocate new process pin array */ + Status = _KsEdit(This->Filter.Bag, (PVOID*)&This->ProcessPinIndex[ProcessPin->Pin->Id].Pins, + (This->PinDescriptorCount + 1) * sizeof(PKSPROCESSPIN), + This->PinDescriptorCount * sizeof(PKSPROCESSPIN), 0); if (NT_SUCCESS(Status)) { - /* add new process pin */ - This->ProcessPinIndex.Pins[This->ProcessPinIndex.Count] = ProcessPin; - This->ProcessPinIndex.Count++; + /* store process pin */ + This->ProcessPinIndex[ProcessPin->Pin->Id].Pins[This->ProcessPinIndex[ProcessPin->Pin->Id].Count] = ProcessPin; + This->ProcessPinIndex[ProcessPin->Pin->Id].Count++; } /* release process mutex */ @@ -321,25 +324,39 @@ IN PKSPROCESSPIN ProcessPin) { ULONG Index; + ULONG Count; + PKSPROCESSPIN * Pins; + IKsFilterImpl * This = (IKsFilterImpl*)CONTAINING_RECORD(iface, IKsFilterImpl, lpVtbl); /* first acquire processing mutex */ KeWaitForSingleObject(&This->ProcessingMutex, Executive, KernelMode, FALSE, NULL); - /* iterate through process pin index array and search for the process pin to be removed */ - for(Index = 0; Index < This->ProcessPinIndex.Count; Index++) - { - if (This->ProcessPinIndex.Pins[Index] == ProcessPin) - { - /* found process pin */ - if (Index + 1 < This->ProcessPinIndex.Count) - { - /* erase entry */ - RtlMoveMemory(&This->ProcessPinIndex.Pins[Index], &This->ProcessPinIndex.Pins[Index+1], This->ProcessPinIndex.Count - Index - 1); - } - /* decrement process pin count */ - This->ProcessPinIndex.Count--; - } + /* sanity check */ + ASSERT(ProcessPin->Pin); + ASSERT(ProcessPin->Pin->Id); + + Count = This->ProcessPinIndex[ProcessPin->Pin->Id].Count; + Pins = This->ProcessPinIndex[ProcessPin->Pin->Id].Pins; + + /* search for current process pin */ + for(Index = 0; Index < Count; Index++) + { + if (Pins[Index] == ProcessPin) + { + RtlMoveMemory(&Pins[Index], &Pins[Index + 1], (Count - (Index + 1)) * sizeof(PKSPROCESSPIN)); + break; + } + + } + + /* decrement pin count */ + This->ProcessPinIndex[ProcessPin->Pin->Id].Count--; + + if (!This->ProcessPinIndex[ProcessPin->Pin->Id].Count) + { + /* clear entry object bag will delete it */ + This->ProcessPinIndex[ProcessPin->Pin->Id].Pins = NULL; } /* release process mutex */ @@ -394,8 +411,9 @@ IKsFilter_fnGetProcessDispatch( IKsFilter * iface) { - UNIMPLEMENTED - return NULL; + IKsFilterImpl * This = (IKsFilterImpl*)CONTAINING_RECORD(iface, IKsFilterImpl, lpVtbl); + + return This->ProcessPinIndex; } static IKsFilterVtbl vt_IKsFilter = @@ -619,7 +637,7 @@ Data, &Length); - if (Status == STATUS_SUCCESS) + if (Status == STATUS_SUCCESS || Status == STATUS_BUFFER_OVERFLOW) { IoStatus->Information = Length; break; @@ -784,6 +802,7 @@ This->PinInstanceCount = NULL; This->PinDescriptors = NULL; This->PinDescriptorsEx = NULL; + This->ProcessPinIndex = NULL; This->PinDescriptorCount = 0; /* initialize topology descriptor */ @@ -842,8 +861,6 @@ return Status; } - - /* add new pin factory */ RtlMoveMemory(This->PinDescriptorsEx, FilterDescriptor->PinDescriptors, sizeof(KSPIN_DESCRIPTOR_EX) * FilterDescriptor->PinDescriptorsCount); @@ -852,8 +869,19 @@ RtlMoveMemory(&This->PinDescriptors[Index], &FilterDescriptor->PinDescriptors[Index].PinDescriptor, sizeof(KSPIN_DESCRIPTOR)); } + /* allocate process pin index */ + Status = _KsEdit(This->Filter.Bag, (PVOID*)&This->ProcessPinIndex, sizeof(KSPROCESSPIN_INDEXENTRY) * FilterDescriptor->PinDescriptorsCount, + sizeof(KSPROCESSPIN_INDEXENTRY) * FilterDescriptor->PinDescriptorsCount, 0); + + if (!NT_SUCCESS(Status)) + { + DPRINT("IKsFilter_CreateDescriptors _KsEdit failed %lx\n", Status); + return Status; + } + /* store new pin descriptor count */ This->PinDescriptorCount = FilterDescriptor->PinDescriptorsCount; + } if (FilterDescriptor->NodeDescriptorsCount) @@ -991,7 +1019,7 @@ ASSERT(This->Header.Type == KsObjectTypeFilter); /* acquire control mutex */ - KeWaitForSingleObject(&This->Header.ControlMutex, Executive, KernelMode, FALSE, NULL); + KeWaitForSingleObject(This->Header.ControlMutex, Executive, KernelMode, FALSE, NULL); /* now validate the connect request */ Status = KsValidateConnectRequest(Irp, This->PinDescriptorCount, This->PinDescriptors, &Connect); @@ -1029,7 +1057,7 @@ } /* release control mutex */ - KeReleaseMutex(&This->Header.ControlMutex, FALSE); + KeReleaseMutex(This->Header.ControlMutex, FALSE); if (Status != STATUS_PENDING) { @@ -1175,6 +1203,8 @@ DPRINT("KspCreateFilter OutOfMemory\n"); return STATUS_INSUFFICIENT_RESOURCES; } + + DPRINT("KspCreateFilter Flags %lx\n", Factory->FilterDescriptor->Flags); /* initialize pin create item */ CreateItem[0].Create = IKsFilter_DispatchCreatePin; @@ -1202,7 +1232,8 @@ This->Header.KsDevice = &DeviceExtension->DeviceHeader->KsDevice; This->Header.Parent.KsFilterFactory = iface->lpVtbl->GetStruct(iface); This->Header.Type = KsObjectTypeFilter; - KeInitializeMutex(&This->Header.ControlMutex, 0); + This->Header.ControlMutex = &This->ControlMutex; + KeInitializeMutex(This->Header.ControlMutex, 0); InitializeListHead(&This->Header.EventList); KeInitializeSpinLock(&This->Header.EventListLock); @@ -1224,8 +1255,9 @@ if (Factory->FilterDescriptor->Dispatch->Create) { /* now let driver initialize the filter instance */ - DPRINT("Before instantiating filter Filter %p This %p KSBASIC_HEADER %u\n", &This->Filter, This, sizeof(KSBASIC_HEADER)); + ASSERT(This->Header.KsDevice); + ASSERT(This->Header.KsDevice->Started); Status = Factory->FilterDescriptor->Dispatch->Create(&This->Filter, Irp); if (!NT_SUCCESS(Status) && Status != STATUS_PENDING) @@ -1432,6 +1464,17 @@ RtlMoveMemory(&This->PinDescriptorsEx[This->PinDescriptorCount], InPinDescriptor, sizeof(KSPIN_DESCRIPTOR_EX)); RtlMoveMemory(&This->PinDescriptors[This->PinDescriptorCount], &InPinDescriptor->PinDescriptor, sizeof(KSPIN_DESCRIPTOR)); + + /* allocate process pin index */ + Status = _KsEdit(This->Filter.Bag, (PVOID*)&This->ProcessPinIndex, sizeof(KSPROCESSPIN_INDEXENTRY) * Count, + sizeof(KSPROCESSPIN_INDEXENTRY) * This->PinDescriptorCount, 0); + + if (!NT_SUCCESS(Status)) + { + DPRINT("KsFilterCreatePinFactory _KsEdit failed %lx\n", Status); + return Status; + } + /* store new pin id */ *PinID = This->PinDescriptorCount; Modified: trunk/reactos/drivers/ksfilter/ks/filterfactory.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/filter…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/filterfactory.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/filterfactory.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -21,6 +21,8 @@ PFNKSFILTERFACTORYPOWER WakeCallback; LIST_ENTRY SymbolicLinkList; + KMUTEX ControlMutex; + }IKsFilterFactoryImpl; VOID @@ -225,16 +227,15 @@ This->Header.Parent.KsDevice = &DeviceExtension->DeviceHeader->KsDevice; This->DeviceHeader = DeviceExtension->DeviceHeader; + /* initialize filter factory control mutex */ + This->Header.ControlMutex = &This->ControlMutex; + KeInitializeMutex(This->Header.ControlMutex, 0); + /* unused fields */ - KeInitializeMutex(&This->Header.ControlMutex, 0); InitializeListHead(&This->Header.EventList); KeInitializeSpinLock(&This->Header.EventListLock); - InitializeListHead(&This->SymbolicLinkList); - - /* initialize filter factory control mutex */ - KeInitializeMutex(&This->Header.ControlMutex, 0); /* does the device use a reference string */ if (RefString || !Descriptor->ReferenceGuid) Modified: trunk/reactos/drivers/ksfilter/ks/kstypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/kstype…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/kstypes.h [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/kstypes.h [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -58,7 +58,7 @@ { KSOBJECTTYPE Type; PKSDEVICE KsDevice; - KMUTEX ControlMutex; + PRKMUTEX ControlMutex; LIST_ENTRY EventList; KSPIN_LOCK EventListLock; union Modified: trunk/reactos/drivers/ksfilter/ks/pin.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/pin.c?…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/pin.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/pin.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -29,8 +29,9 @@ LIST_ENTRY Entry; IKsPinVtbl *lpVtbl; - LONG ref; + + IKsFilter * Filter; KMUTEX ProcessingMutex; PFILE_OBJECT FileObject; @@ -50,7 +51,354 @@ PFNKSPINFRAMERETURN FrameReturn; PFNKSPINIRPCOMPLETION IrpCompletion; + KSCLOCK_FUNCTIONTABLE ClockTable; + PFILE_OBJECT ClockFileObject; + IKsReferenceClockVtbl * lpVtblReferenceClock; + PKSDEFAULTCLOCK DefaultClock; + }IKsPinImpl; + +NTSTATUS NTAPI IKsPin_PinStatePropertyHandler(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); +NTSTATUS NTAPI IKsPin_PinDataFormatPropertyHandler(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); +NTSTATUS NTAPI IKsPin_PinAllocatorFramingPropertyHandler(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); +NTSTATUS NTAPI IKsPin_PinStreamAllocator(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); +NTSTATUS NTAPI IKsPin_PinMasterClock(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); +NTSTATUS NTAPI IKsPin_PinPipeId(IN PIRP Irp, IN PKSIDENTIFIER Request, IN OUT PVOID Data); + + + +DEFINE_KSPROPERTY_CONNECTIONSET(PinConnectionSet, IKsPin_PinStatePropertyHandler, IKsPin_PinDataFormatPropertyHandler, IKsPin_PinAllocatorFramingPropertyHandler); +DEFINE_KSPROPERTY_STREAMSET(PinStreamSet, IKsPin_PinStreamAllocator, IKsPin_PinMasterClock, IKsPin_PinPipeId); + +//TODO +// KSPROPSETID_Connection +// KSPROPERTY_CONNECTION_ACQUIREORDERING +// KSPROPSETID_StreamInterface +// KSPROPERTY_STREAMINTERFACE_HEADERSIZE + +KSPROPERTY_SET PinPropertySet[] = +{ + { + &KSPROPSETID_Connection, + sizeof(PinConnectionSet) / sizeof(KSPROPERTY_ITEM), + (const KSPROPERTY_ITEM*)&PinConnectionSet, + 0, + NULL + }, + { + &KSPROPSETID_Stream, + sizeof(PinStreamSet) / sizeof(KSPROPERTY_ITEM), + (const KSPROPERTY_ITEM*)&PinStreamSet, + 0, + NULL + } +}; + +const GUID KSPROPSETID_Connection = {0x1D58C920L, 0xAC9B, 0x11CF, {0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00}}; +const GUID KSPROPSETID_Stream = {0x65aaba60L, 0x98ae, 0x11cf, {0xa1, 0x0d, 0x00, 0x20, 0xaf, 0xd1, 0x56, 0xe4}}; +const GUID KSPROPSETID_Clock = {0xDF12A4C0L, 0xAC17, 0x11CF, {0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00}}; + +NTSTATUS +NTAPI +IKsPin_PinStreamAllocator( + IN PIRP Irp, + IN PKSIDENTIFIER Request, + IN OUT PVOID Data) +{ + UNIMPLEMENTED + return STATUS_NOT_IMPLEMENTED; +} + +NTSTATUS +NTAPI +IKsPin_PinMasterClock( + IN PIRP Irp, + IN PKSIDENTIFIER Request, + IN OUT PVOID Data) +{ + PIO_STACK_LOCATION IoStack; + PKSIOBJECT_HEADER ObjectHeader; + IKsPinImpl * This; + NTSTATUS Status = STATUS_SUCCESS; + PHANDLE Handle; + PFILE_OBJECT FileObject; + KPROCESSOR_MODE Mode; + KSPROPERTY Property; + ULONG BytesReturned; + + /* get current irp stack */ + IoStack = IoGetCurrentIrpStackLocation(Irp); + + DPRINT("IKsPin_PinMasterClock\n"); + + /* sanity check */ + ASSERT(IoStack->FileObject); + ASSERT(IoStack->FileObject->FsContext2); + + /* get the object header */ + ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; + + /* locate ks pin implemention from KSPIN offset */ + This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); + + /* acquire control mutex */ + KeWaitForSingleObject(This->BasicHeader.ControlMutex, Executive, KernelMode, FALSE, NULL); + + Handle = (PHANDLE)Data; + + if (Request->Flags & KSPROPERTY_TYPE_GET) + { + if (This->Pin.Descriptor->PinDescriptor.Communication != KSPIN_COMMUNICATION_NONE && + This->Pin.Descriptor->Dispatch && + (This->Pin.Descriptor->Flags & KSPIN_FLAG_IMPLEMENT_CLOCK)) + { + *Handle = NULL; + Status = STATUS_SUCCESS; + } + else + { + /* no clock available */ + Status = STATUS_UNSUCCESSFUL; + } + } + else if (Request->Flags & KSPROPERTY_TYPE_SET) + { + if (This->Pin.ClientState != KSSTATE_STOP) + { + /* can only set in stopped state */ + Status = STATUS_INVALID_DEVICE_STATE; + } + else + { + if (*Handle) + { + Mode = ExGetPreviousMode(); + + Status = ObReferenceObjectByHandle(*Handle, SYNCHRONIZE | DIRECTORY_QUERY, IoFileObjectType, Mode, (PVOID*)&FileObject, NULL); + + DPRINT("IKsPin_PinMasterClock ObReferenceObjectByHandle %lx\n", Status); + if (NT_SUCCESS(Status)) + { + Property.Set = KSPROPSETID_Clock; + Property.Id = KSPROPERTY_CLOCK_FUNCTIONTABLE; + Property.Flags = KSPROPERTY_TYPE_GET; + + Status = KsSynchronousIoControlDevice(FileObject, KernelMode, IOCTL_KS_PROPERTY, &Property, sizeof(KSPROPERTY), &This->ClockTable, sizeof(KSCLOCK_FUNCTIONTABLE), &BytesReturned); + + DPRINT("IKsPin_PinMasterClock KSPROPERTY_CLOCK_FUNCTIONTABLE %lx\n", Status); + + if (NT_SUCCESS(Status)) + { + This->ClockFileObject = FileObject; + } + else + { + ObDereferenceObject(FileObject); + } + } + } + else + { + /* zeroing clock handle */ + RtlZeroMemory(&This->ClockTable, sizeof(KSCLOCK_FUNCTIONTABLE)); + Status = STATUS_SUCCESS; + if (This->ClockFileObject) + { + FileObject = This->ClockFileObject; + This->ClockFileObject = NULL; + + ObDereferenceObject(This->ClockFileObject); + } + } + } + } + + /* release processing mutex */ + KeReleaseMutex(This->BasicHeader.ControlMutex, FALSE); + + DPRINT("IKsPin_PinStatePropertyHandler Status %lx\n", Status); + return Status; +} + + + +NTSTATUS +NTAPI +IKsPin_PinPipeId( + IN PIRP Irp, + IN PKSIDENTIFIER Request, + IN OUT PVOID Data) +{ + UNIMPLEMENTED + return STATUS_NOT_IMPLEMENTED; +} + + +NTSTATUS +NTAPI +IKsPin_PinStatePropertyHandler( + IN PIRP Irp, + IN PKSIDENTIFIER Request, + IN OUT PVOID Data) +{ + PIO_STACK_LOCATION IoStack; + PKSIOBJECT_HEADER ObjectHeader; + IKsPinImpl * This; + NTSTATUS Status = STATUS_SUCCESS; + KSSTATE OldState; + PKSSTATE NewState; + + /* get current irp stack */ + IoStack = IoGetCurrentIrpStackLocation(Irp); + + DPRINT("IKsPin_PinStatePropertyHandler\n"); + + /* sanity check */ + ASSERT(IoStack->FileObject); + ASSERT(IoStack->FileObject->FsContext2); + + /* get the object header */ + ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; + + /* locate ks pin implemention from KSPIN offset */ + This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); + + /* acquire control mutex */ + KeWaitForSingleObject(This->BasicHeader.ControlMutex, Executive, KernelMode, FALSE, NULL); + + /* grab state */ + NewState = (PKSSTATE)Data; + + if (Request->Flags & KSPROPERTY_TYPE_GET) + { + *NewState = This->Pin.DeviceState; + Irp->IoStatus.Information = sizeof(KSSTATE); + } + else if (Request->Flags & KSPROPERTY_TYPE_SET) + { + if (This->Pin.Descriptor->Dispatch->SetDeviceState) + { + /* backup old state */ + OldState = This->Pin.ClientState; + + /* set new state */ + This->Pin.ClientState = *NewState; + + /* check if it supported */ + Status = This->Pin.Descriptor->Dispatch->SetDeviceState(&This->Pin, *NewState, OldState); + + DPRINT("IKsPin_PinStatePropertyHandler NewState %lu Result %lx\n", *NewState, Status); + + if (!NT_SUCCESS(Status)) + { + /* revert to old state */ + This->Pin.ClientState = OldState; + DbgBreakPoint(); + } + else + { + /* update device state */ + This->Pin.DeviceState = *NewState; + } + } + else + { + /* just set new state */ + This->Pin.DeviceState = *NewState; + This->Pin.ClientState = *NewState; + } + } + + /* release processing mutex */ + KeReleaseMutex(This->BasicHeader.ControlMutex, FALSE); + + DPRINT("IKsPin_PinStatePropertyHandler Status %lx\n", Status); + return Status; +} + +NTSTATUS +NTAPI +IKsPin_PinAllocatorFramingPropertyHandler( + IN PIRP Irp, + IN PKSIDENTIFIER Request, + IN OUT PVOID Data) +{ + UNIMPLEMENTED + return STATUS_NOT_IMPLEMENTED; +} + +NTSTATUS +NTAPI +IKsPin_PinDataFormatPropertyHandler( + IN PIRP Irp, + IN PKSPROPERTY Request, + IN OUT PVOID Data) +{ + PIO_STACK_LOCATION IoStack; + PKSIOBJECT_HEADER ObjectHeader; + IKsPinImpl * This; + NTSTATUS Status = STATUS_SUCCESS; + + /* get current irp stack */ + IoStack = IoGetCurrentIrpStackLocation(Irp); + + DPRINT("IKsPin_PinDataFormatPropertyHandler\n"); + + /* sanity check */ + ASSERT(IoStack->FileObject); + ASSERT(IoStack->FileObject->FsContext2); + + /* get the object header */ + ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; + + /* locate ks pin implemention from KSPIN offset */ + This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); + + /* acquire control mutex */ + KeWaitForSingleObject(This->BasicHeader.ControlMutex, Executive, KernelMode, FALSE, NULL); + + if (Request->Flags & KSPROPERTY_TYPE_GET) + { + if (IoStack->Parameters.DeviceIoControl.OutputBufferLength < This->Pin.ConnectionFormat->FormatSize) + { + /* buffer too small */ + Irp->IoStatus.Information = This->Pin.ConnectionFormat->FormatSize; + Status = STATUS_BUFFER_TOO_SMALL; + } + else + { + /* copy format */ + RtlMoveMemory(Data, This->Pin.ConnectionFormat, This->Pin.ConnectionFormat->FormatSize); + } + } + else if (Request->Flags & KSPROPERTY_TYPE_SET) + { + /* set format */ + if (This->Pin.Descriptor->Flags & KSPIN_FLAG_FIXED_FORMAT) + { + /* format cannot be changed */ + Status = STATUS_INVALID_DEVICE_REQUEST; + } + else + { + /* FIXME check if the format is supported */ + Status = _KsEdit(This->Pin.Bag, (PVOID*)&This->Pin.ConnectionFormat, IoStack->Parameters.DeviceIoControl.OutputBufferLength, This->Pin.ConnectionFormat->FormatSize, 0); + + if (NT_SUCCESS(Status)) + { + /* store new format */ + RtlMoveMemory(This->Pin.ConnectionFormat, Data, IoStack->Parameters.DeviceIoControl.OutputBufferLength); + } + } + } + + /* release processing mutex */ + KeReleaseMutex(This->BasicHeader.ControlMutex, FALSE); + + DPRINT("IKsPin_PinDataFormatPropertyHandler Status %lx\n", Status); + + return Status; +} NTSTATUS NTAPI @@ -67,6 +415,7 @@ _InterlockedIncrement(&This->ref); return STATUS_SUCCESS; } + DbgBreakPoint(); return STATUS_UNSUCCESSFUL; } @@ -270,6 +619,209 @@ //============================================================== +NTSTATUS +NTAPI +IKsReferenceClock_fnQueryInterface( + IKsReferenceClock * iface, + IN REFIID refiid, + OUT PVOID* Output) +{ + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + return IKsPin_fnQueryInterface((IKsPin*)&This->lpVtbl, refiid, Output); +} + +ULONG +NTAPI +IKsReferenceClock_fnAddRef( + IKsReferenceClock * iface) +{ + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + return IKsPin_fnAddRef((IKsPin*)&This->lpVtbl); +} + +ULONG +NTAPI +IKsReferenceClock_fnRelease( + IKsReferenceClock * iface) +{ + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + return IKsPin_fnRelease((IKsPin*)&This->lpVtbl); +} + +LONGLONG +NTAPI +IKsReferenceClock_fnGetTime( + IKsReferenceClock * iface) +{ + LONGLONG Result; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + if (!This->ClockFileObject || !This->ClockTable.GetTime) + { + Result = 0; + } + else + { + Result = This->ClockTable.GetTime(This->ClockFileObject); + } + + return Result; +} + +LONGLONG +NTAPI +IKsReferenceClock_fnGetPhysicalTime( + IKsReferenceClock * iface) +{ + LONGLONG Result; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + if (!This->ClockFileObject || !This->ClockTable.GetPhysicalTime) + { + Result = 0; + } + else + { + Result = This->ClockTable.GetPhysicalTime(This->ClockFileObject); + } + + return Result; +} + + +LONGLONG +NTAPI +IKsReferenceClock_fnGetCorrelatedTime( + IKsReferenceClock * iface, + OUT PLONGLONG SystemTime) +{ + LONGLONG Result; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + if (!This->ClockFileObject || !This->ClockTable.GetCorrelatedTime) + { + Result = 0; + } + else + { + Result = This->ClockTable.GetCorrelatedTime(This->ClockFileObject, SystemTime); + } + + return Result; +} + + +LONGLONG +NTAPI +IKsReferenceClock_fnGetCorrelatedPhysicalTime( + IKsReferenceClock * iface, + OUT PLONGLONG SystemTime) +{ + LONGLONG Result; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + if (!This->ClockFileObject || !This->ClockTable.GetCorrelatedPhysicalTime) + { + Result = 0; + } + else + { + Result = This->ClockTable.GetCorrelatedPhysicalTime(This->ClockFileObject, SystemTime); + } + + return Result; +} + +NTSTATUS +NTAPI +IKsReferenceClock_fnGetResolution( + IKsReferenceClock * iface, + OUT PKSRESOLUTION Resolution) +{ + KSPROPERTY Property; + ULONG BytesReturned; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + DPRINT1("IKsReferenceClock_fnGetResolution\n"); + + if (!This->ClockFileObject) + { + Resolution->Error = 0; + Resolution->Granularity = 1; + DPRINT1("IKsReferenceClock_fnGetResolution Using HACK\n"); + return STATUS_SUCCESS; + } + + + if (!This->ClockFileObject) + return STATUS_DEVICE_NOT_READY; + + + Property.Set = KSPROPSETID_Clock; + Property.Id = KSPROPERTY_CLOCK_RESOLUTION; + Property.Flags = KSPROPERTY_TYPE_GET; + + return KsSynchronousIoControlDevice(This->ClockFileObject, KernelMode, IOCTL_KS_PROPERTY, &Property, sizeof(KSPROPERTY), Resolution, sizeof(KSRESOLUTION), &BytesReturned); + +} + +NTSTATUS +NTAPI +IKsReferenceClock_fnGetState( + IKsReferenceClock * iface, + OUT PKSSTATE State) +{ + KSPROPERTY Property; + ULONG BytesReturned; + + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(iface, IKsPinImpl, lpVtblReferenceClock); + + DPRINT1("IKsReferenceClock_fnGetState\n"); + + if (!This->ClockFileObject) + { + *State = This->Pin.ClientState; + DPRINT1("IKsReferenceClock_fnGetState Using HACK\n"); + return STATUS_SUCCESS; + } + + + if (!This->ClockFileObject) + return STATUS_DEVICE_NOT_READY; + + + Property.Set = KSPROPSETID_Clock; + Property.Id = KSPROPERTY_CLOCK_RESOLUTION; + Property.Flags = KSPROPERTY_TYPE_GET; + + return KsSynchronousIoControlDevice(This->ClockFileObject, KernelMode, IOCTL_KS_PROPERTY, &Property, sizeof(KSPROPERTY), State, sizeof(KSSTATE), &BytesReturned); +} + +static IKsReferenceClockVtbl vt_ReferenceClock = +{ + IKsReferenceClock_fnQueryInterface, + IKsReferenceClock_fnAddRef, + IKsReferenceClock_fnRelease, + IKsReferenceClock_fnGetTime, + IKsReferenceClock_fnGetPhysicalTime, + IKsReferenceClock_fnGetCorrelatedTime, + IKsReferenceClock_fnGetCorrelatedPhysicalTime, + IKsReferenceClock_fnGetResolution, + IKsReferenceClock_fnGetState +}; + + +//============================================================== + + /* @implemented */ @@ -340,6 +892,7 @@ IN BOOLEAN Asynchronous) { DPRINT("KsPinAttemptProcessing\n"); +DbgBreakPoint(); UNIMPLEMENTED } @@ -448,7 +1001,7 @@ } /* - @unimplemented + @implemented */ NTSTATUS NTAPI @@ -456,9 +1009,22 @@ IN PKSPIN Pin, OUT PIKSREFERENCECLOCK* Interface) { - UNIMPLEMENTED - DPRINT("KsPinGetReferenceClockInterface Pin %p Interface %p\n", Pin, Interface); - return STATUS_UNSUCCESSFUL; + NTSTATUS Status = STATUS_DEVICE_NOT_READY; + IKsPinImpl * This = (IKsPinImpl*)CONTAINING_RECORD(Pin, IKsPinImpl, Pin); + + if (This->ClockFileObject) + { + /* clock is available */ + *Interface = (PIKSREFERENCECLOCK)&This->lpVtblReferenceClock; + Status = STATUS_SUCCESS; + } +//HACK + *Interface = (PIKSREFERENCECLOCK)&This->lpVtblReferenceClock; + Status = STATUS_SUCCESS; + + DPRINT("KsPinGetReferenceClockInterface Pin %p Interface %p Status %x\n", Pin, Interface, Status); + + return Status; } /* @@ -547,15 +1113,26 @@ IN PIRP Irp) { PKSIOBJECT_HEADER ObjectHeader; + PKSPIN Pin; + PKSBASIC_HEADER Header; PIO_STACK_LOCATION IoStack = IoGetCurrentIrpStackLocation(Irp); DPRINT("KsGetPinFromIrp\n"); /* get object header */ ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; + + if (!ObjectHeader) + return NULL; + + Pin = (PKSPIN)ObjectHeader->ObjectType; + Header = (PKSBASIC_HEADER)((ULONG_PTR)Pin - sizeof(KSBASIC_HEADER)); + + /* sanity check */ + ASSERT(Header->Type == KsObjectTypePin); + /* return object type */ - return (PKSPIN)ObjectHeader->ObjectType; - + return Pin; } @@ -629,6 +1206,7 @@ { UNIMPLEMENTED DPRINT("KsPinGetLeadingEdgeStreamPointer Pin %p State %x\n", Pin, State); +DbgBreakPoint(); return NULL; } @@ -685,6 +1263,7 @@ { UNIMPLEMENTED DPRINT("KsStreamPointerUnlock\n"); +DbgBreakPoint(); } /* @@ -700,7 +1279,7 @@ IN BOOLEAN Eject) { DPRINT("KsStreamPointerAdvanceOffsets\n"); - +DbgBreakPoint(); UNIMPLEMENTED } @@ -718,7 +1297,7 @@ PKSISTREAM_POINTER Pointer = (PKSISTREAM_POINTER)StreamPointer; DPRINT("KsStreamPointerDelete\n"); - +DbgBreakPoint(); This = (IKsPinImpl*)CONTAINING_RECORD(Pointer->StreamPointer.Pin, IKsPinImpl, Pin); /* point to first stream pointer */ @@ -766,6 +1345,7 @@ { UNIMPLEMENTED DPRINT("KsStreamPointerClone\n"); +DbgBreakPoint(); return STATUS_NOT_IMPLEMENTED; } @@ -878,7 +1458,7 @@ IKsPinImpl * This; DPRINT("KsPinGetFirstCloneStreamPointer %p\n", Pin); - +DbgBreakPoint(); This = (IKsPinImpl*)CONTAINING_RECORD(Pin, IKsPinImpl, Pin); /* return first cloned stream pointer */ return &This->ClonedStreamPointer->StreamPointer; @@ -896,7 +1476,7 @@ PKSISTREAM_POINTER Pointer = (PKSISTREAM_POINTER)StreamPointer; DPRINT("KsStreamPointerGetNextClone\n"); - +DbgBreakPoint(); /* is there a another cloned stream pointer */ if (!Pointer->Next) return NULL; @@ -904,6 +1484,64 @@ /* return next stream pointer */ return &Pointer->Next->StreamPointer; } +NTSTATUS +IKsPin_DispatchKsStream( + PDEVICE_OBJECT DeviceObject, + PIRP Irp, + IKsPinImpl * This) +{ + PKSPROCESSPIN_INDEXENTRY ProcessPinIndex; + PKSFILTER Filter; + NTSTATUS Status = STATUS_SUCCESS; + + DPRINT("IKsPin_DispatchKsStream\n"); + + /* FIXME handle reset states */ + ASSERT(This->Pin.ResetState == KSRESET_END); + + /* mark irp as pending */ + IoMarkIrpPending(Irp); + + /* add irp to cancelable queue */ + KsAddIrpToCancelableQueue(&This->IrpList, &This->IrpListLock, Irp, KsListEntryTail, NULL /* FIXME */); + + if (This->Pin.Descriptor->Dispatch->Process) + { + /* it is a pin centric avstream */ + ASSERT(0); + //Status = This->Pin.Descriptor->Dispatch->Process(&This->Pin); + /* TODO */ + } + else + { + /* filter-centric avstream */ + ASSERT(This->Filter); + + ProcessPinIndex = This->Filter->lpVtbl->GetProcessDispatch(This->Filter); + Filter = This->Filter->lpVtbl->GetStruct(This->Filter); + + ASSERT(ProcessPinIndex); + ASSERT(Filter); + ASSERT(Filter->Descriptor); + ASSERT(Filter->Descriptor->Dispatch); + + if (!Filter->Descriptor->Dispatch->Process) + { + /* invalid device request */ + DPRINT("Filter Centric Processing No Process Routine\n"); + Irp->IoStatus.Status = STATUS_UNSUCCESSFUL; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_UNSUCCESSFUL; + } + + Status = Filter->Descriptor->Dispatch->Process(Filter, ProcessPinIndex); + + DPRINT("IKsPin_DispatchKsStream FilterCentric: Status %lx \n", Status); + } + + return Status; +} + NTSTATUS IKsPin_DispatchKsProperty( @@ -940,8 +1578,6 @@ PropertySets, NULL, PropertyItemSize); - - DPRINT("IKsPin_DispatchKsProperty PropertySetCount %lu Status %lu\n", PropertySetsCount, Status); if (Status != STATUS_NOT_FOUND) { @@ -954,6 +1590,24 @@ return Status; } + /* try our properties */ + Status = KspPropertyHandler(Irp, + sizeof(PinPropertySet) / sizeof(KSPROPERTY_SET), + PinPropertySet, + NULL, + 0); + + if (Status != STATUS_NOT_FOUND) + { + /* property was handled by driver */ + if (Status != STATUS_PENDING) + { + Irp->IoStatus.Status = Status; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + } + return Status; + } + /* property was not handled */ Property = (PKSPROPERTY)IoStack->Parameters.DeviceIoControl.Type3InputBuffer; @@ -971,6 +1625,48 @@ NTSTATUS NTAPI IKsPin_DispatchDeviceIoControl( + IN PDEVICE_OBJECT DeviceObject, + IN PIRP Irp) +{ + PIO_STACK_LOCATION IoStack; + PKSIOBJECT_HEADER ObjectHeader; + IKsPinImpl * This; + + /* get current irp stack */ + IoStack = IoGetCurrentIrpStackLocation(Irp); + + /* sanity check */ + ASSERT(IoStack->FileObject); + ASSERT(IoStack->FileObject->FsContext2); + + /* get the object header */ + ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; + + /* locate ks pin implemention from KSPIN offset */ + This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); + + if (IoStack->Parameters.DeviceIoControl.IoControlCode == IOCTL_KS_PROPERTY) + { + /* handle ks properties */ + return IKsPin_DispatchKsProperty(DeviceObject, Irp, This); + } + + if (IoStack->Parameters.DeviceIoControl.IoControlCode == IOCTL_KS_WRITE_STREAM || + IoStack->Parameters.DeviceIoControl.IoControlCode == IOCTL_KS_READ_STREAM) + { + /* handle ks properties */ + return IKsPin_DispatchKsStream(DeviceObject, Irp, This); + } + + UNIMPLEMENTED; + Irp->IoStatus.Status = STATUS_NOT_IMPLEMENTED; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_NOT_IMPLEMENTED; +} + +NTSTATUS +NTAPI +IKsPin_Close( IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp) { @@ -989,75 +1685,11 @@ /* get the object header */ ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; - /* locate ks pin implemention from KSPIN offset */ - This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); - - if (IoStack->Parameters.DeviceIoControl.IoControlCode == IOCTL_KS_PROPERTY) - { - /* handle ks properties */ - return IKsPin_DispatchKsProperty(DeviceObject, Irp, This); - } - - - if (IoStack->Parameters.DeviceIoControl.IoControlCode != IOCTL_KS_WRITE_STREAM && IoStack->Parameters.DeviceIoControl.IoControlCode != IOCTL_KS_READ_STREAM) - { - UNIMPLEMENTED; - Irp->IoStatus.Status = STATUS_NOT_IMPLEMENTED; - Irp->IoStatus.Information = 0; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_NOT_IMPLEMENTED; - } - - /* mark irp as pending */ - IoMarkIrpPending(Irp); - - /* add irp to cancelable queue */ - KsAddIrpToCancelableQueue(&This->IrpList, &This->IrpListLock, Irp, KsListEntryTail, NULL /* FIXME */); - - if (This->Pin.Descriptor->Dispatch->Process) - { - /* it is a pin centric avstream */ - Status = This->Pin.Descriptor->Dispatch->Process(&This->Pin); - - /* TODO */ - } - else - { - /* TODO - * filter-centric avstream - */ - UNIMPLEMENTED - } - - return Status; -} - -NTSTATUS -NTAPI -IKsPin_Close( - IN PDEVICE_OBJECT DeviceObject, - IN PIRP Irp) -{ - PIO_STACK_LOCATION IoStack; - PKSIOBJECT_HEADER ObjectHeader; - IKsPinImpl * This; - NTSTATUS Status = STATUS_SUCCESS; - - /* get current irp stack */ - IoStack = IoGetCurrentIrpStackLocation(Irp); - - /* sanity check */ - ASSERT(IoStack->FileObject); - ASSERT(IoStack->FileObject->FsContext2); - - /* get the object header */ - ObjectHeader = (PKSIOBJECT_HEADER)IoStack->FileObject->FsContext2; - /* locate ks pin implemention fro KSPIN offset */ This = (IKsPinImpl*)CONTAINING_RECORD(ObjectHeader->ObjectType, IKsPinImpl, Pin); /* acquire filter control mutex */ - KsFilterAcquireControl(This->BasicHeader.Parent.KsFilter); + KsFilterAcquireControl(&This->Pin); if (This->Pin.Descriptor->Dispatch->Close) { @@ -1082,6 +1714,9 @@ } } + /* release filter control mutex */ + KsFilterReleaseControl(&This->Pin); + return Status; } @@ -1104,11 +1739,80 @@ IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp) { - UNIMPLEMENTED; - - Irp->IoStatus.Status = STATUS_NOT_IMPLEMENTED; + PKSPIN Pin; + NTSTATUS Status = STATUS_SUCCESS; + IKsPinImpl * This; + KSRESOLUTION Resolution; + PKSRESOLUTION pResolution = NULL; + PKSOBJECT_CREATE_ITEM CreateItem; + + DPRINT("IKsPin_DispatchCreateClock\n"); + + /* get the create item */ + CreateItem = KSCREATE_ITEM_IRP_STORAGE(Irp); + + /* sanity check */ + ASSERT(CreateItem); + + /* get the pin object */ + Pin = (PKSPIN)CreateItem->Context; + + /* sanity check */ + ASSERT(Pin); + + /* locate ks pin implemention fro KSPIN offset */ + This = (IKsPinImpl*)CONTAINING_RECORD(Pin, IKsPinImpl, Pin); + + /* sanity check */ + ASSERT(This->BasicHeader.Type == KsObjectTypePin); + ASSERT(This->BasicHeader.ControlMutex); + + /* acquire control mutex */ + KsAcquireControl(Pin); + + if ((This->Pin.Descriptor->PinDescriptor.Communication != KSPIN_COMMUNICATION_NONE && + This->Pin.Descriptor->Dispatch) || + (This->Pin.Descriptor->Flags & KSPIN_FLAG_IMPLEMENT_CLOCK)) + { + if (!This->DefaultClock) + { + if (This->Pin.Descriptor->Dispatch && This->Pin.Descriptor->Dispatch->Clock) + { + if (This->Pin.Descriptor->Dispatch->Clock->Resolution) + { + This->Pin.Descriptor->Dispatch->Clock->Resolution(&This->Pin, &Resolution); + pResolution = &Resolution; + } + + Status = KsAllocateDefaultClockEx(&This->DefaultClock, + (PVOID)&This->Pin, + (PFNKSSETTIMER)This->Pin.Descriptor->Dispatch->Clock->SetTimer, + (PFNKSCANCELTIMER)This->Pin.Descriptor->Dispatch->Clock->CancelTimer, + (PFNKSCORRELATEDTIME)This->Pin.Descriptor->Dispatch->Clock->CorrelatedTime, + pResolution, + 0); + } + else + { + Status = KsAllocateDefaultClockEx(&This->DefaultClock, (PVOID)&This->Pin, NULL, NULL, NULL, NULL, 0); + } + } + + if (NT_SUCCESS(Status)) + { + Status = KsCreateDefaultClock(Irp, This->DefaultClock); + } + } + + DPRINT("IKsPin_DispatchCreateClock %lx\n", Status); + + /* release control mutex */ + KsReleaseControl(Pin); + + /* done */ + Irp->IoStatus.Status = Status; IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_NOT_IMPLEMENTED; + return Status; } NTSTATUS @@ -1141,7 +1845,7 @@ NTSTATUS KspCreatePin( IN PDEVICE_OBJECT DeviceObject, - IN PIRP Irp, + IN PIRP Irp, IN PKSDEVICE KsDevice, IN IKsFilterFactory * FilterFactory, IN IKsFilter* Filter, @@ -1155,11 +1859,15 @@ PKSOBJECT_CREATE_ITEM CreateItem; NTSTATUS Status; PKSDATAFORMAT DataFormat; + PKSBASIC_HEADER BasicHeader; /* sanity checks */ ASSERT(Descriptor->Dispatch); - DPRINT("KspCreatePin\n"); + DPRINT("KspCreatePin PinId %lu Flags %x\n", Connect->PinId, Descriptor->Flags); + +//Output Pin: KSPIN_FLAG_PROCESS_IN_RUN_STATE_ONLY +//Input Pin: KSPIN_FLAG_FIXED_FORMAT|KSPIN_FLAG_DO_NOT_USE_STANDARD_TRANSPORT|KSPIN_FLAG_FRAMES_NOT_REQUIRED_FOR_PROCESSING /* get current irp stack */ IoStack = IoGetCurrentIrpStackLocation(Irp); @@ -1192,14 +1900,24 @@ This->BasicHeader.KsDevice = KsDevice; This->BasicHeader.Type = KsObjectTypePin; This->BasicHeader.Parent.KsFilter = Filter->lpVtbl->GetStruct(Filter); - KeInitializeMutex(&This->BasicHeader.ControlMutex, 0); + + ASSERT(This->BasicHeader.Parent.KsFilter); + + BasicHeader = (PKSBASIC_HEADER)((ULONG_PTR)This->BasicHeader.Parent.KsFilter - sizeof(KSBASIC_HEADER)); + + This->BasicHeader.ControlMutex = BasicHeader->ControlMutex; + ASSERT(This->BasicHeader.ControlMutex); + + InitializeListHead(&This->BasicHeader.EventList); KeInitializeSpinLock(&This->BasicHeader.EventListLock); /* initialize pin */ This->lpVtbl = &vt_IKsPin; + This->lpVtblReferenceClock = &vt_ReferenceClock; This->ref = 1; This->FileObject = IoStack->FileObject; + This->Filter = Filter; KeInitializeMutex(&This->ProcessingMutex, 0); InitializeListHead(&This->IrpList); KeInitializeSpinLock(&This->IrpListLock); @@ -1216,12 +1934,12 @@ } /* initialize object bag */ - Device->lpVtbl->InitializeObjectBag(Device, This->Pin.Bag, &This->BasicHeader.ControlMutex); /* is using control mutex right? */ + Device->lpVtbl->InitializeObjectBag(Device, This->Pin.Bag, NULL); /* get format */ DataFormat = (PKSDATAFORMAT)(Connect + 1); - /* initialize ks pin descriptor */ + /* initialize pin descriptor */ This->Pin.Descriptor = Descriptor; This->Pin.Context = NULL; This->Pin.Id = Connect->PinId; @@ -1253,19 +1971,19 @@ This->Pin.ClientState = KSSTATE_STOP; /* intialize allocator create item */ - CreateItem[0].Context = (PVOID)This; + CreateItem[0].Context = (PVOID)&This->Pin; CreateItem[0].Create = IKsPin_DispatchCreateAllocator; CreateItem[0].Flags = KSCREATE_ITEM_FREEONSTOP; RtlInitUnicodeString(&CreateItem[0].ObjectClass, KSSTRING_Allocator); /* intialize clock create item */ - CreateItem[1].Context = (PVOID)This; + CreateItem[1].Context = (PVOID)&This->Pin; CreateItem[1].Create = IKsPin_DispatchCreateClock; CreateItem[1].Flags = KSCREATE_ITEM_FREEONSTOP; RtlInitUnicodeString(&CreateItem[1].ObjectClass, KSSTRING_Clock); /* intialize topology node create item */ - CreateItem[2].Context = (PVOID)This; + CreateItem[2].Context = (PVOID)&This->Pin; CreateItem[2].Create = IKsPin_DispatchCreateNode; CreateItem[2].Flags = KSCREATE_ITEM_FREEONSTOP; RtlInitUnicodeString(&CreateItem[2].ObjectClass, KSSTRING_TopologyNode); @@ -1289,15 +2007,21 @@ This->ObjectHeader->Unknown = (PUNKNOWN)&This->lpVtbl; This->ObjectHeader->ObjectType = (PVOID)&This->Pin; - /* setup process pin */ - This->ProcessPin.Pin = &This->Pin; - This->ProcessPin.StreamPointer = (PKSSTREAM_POINTER)This->LeadingEdgeStreamPointer; - if (!Descriptor->Dispatch || !Descriptor->Dispatch->Process) { /* the pin is part of filter-centric processing filter * add process pin to filter */ + This->ProcessPin.BytesAvailable = 0; + This->ProcessPin.BytesUsed = 0; + This->ProcessPin.CopySource = NULL; + This->ProcessPin.Data = NULL; + This->ProcessPin.DelegateBranch = NULL; + This->ProcessPin.Flags = 0; + This->ProcessPin.InPlaceCounterpart = NULL; + This->ProcessPin.Pin = &This->Pin; + This->ProcessPin.StreamPointer = (PKSSTREAM_POINTER)This->LeadingEdgeStreamPointer; + This->ProcessPin.Terminate = FALSE; Status = Filter->lpVtbl->AddProcessPin(Filter, &This->ProcessPin); DPRINT("KspCreatePin AddProcessPin %lx\n", Status); @@ -1307,7 +2031,8 @@ /* failed to add process pin */ KsFreeObjectBag((KSOBJECT_BAG)This->Pin.Bag); KsFreeObjectHeader(&This->ObjectHeader); - + FreeItem(This); + FreeItem(CreateItem); /* return failure code */ return Status; } @@ -1315,6 +2040,15 @@ /* FIXME add pin instance to filter instance */ + + if (Descriptor->Dispatch && Descriptor->Dispatch->SetDataFormat) + { + Status = Descriptor->Dispatch->SetDataFormat(&This->Pin, NULL, NULL, This->Pin.ConnectionFormat, NULL); + DPRINT("KspCreatePin SetDataFormat %lx\n", Status); + DbgBreakPoint(); + } + + /* does the driver have a pin dispatch */ if (Descriptor->Dispatch && Descriptor->Dispatch->Create) { @@ -1322,6 +2056,8 @@ Status = Descriptor->Dispatch->Create(&This->Pin, Irp); DPRINT("KspCreatePin DispatchCreate %lx\n", Status); } + + DPRINT("KspCreatePin Status %lx\n", Status); Modified: trunk/reactos/drivers/ksfilter/ks/priv.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/priv.h…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/priv.h [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/priv.h [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -35,3 +35,24 @@ DEFINE_KSPROPERTY_ITEM_PIN_CONSTRAINEDDATARANGES(PropGeneral),\ DEFINE_KSPROPERTY_ITEM_PIN_PROPOSEDATAFORMAT(PropGeneral)\ } + +#define DEFINE_KSPROPERTY_CONNECTIONSET(PinSet,\ + PropStateHandler, PropDataFormatHandler, PropAllocatorFraming)\ +DEFINE_KSPROPERTY_TABLE(PinSet) {\ + DEFINE_KSPROPERTY_ITEM_CONNECTION_STATE(PropStateHandler, PropStateHandler),\ + DEFINE_KSPROPERTY_ITEM_CONNECTION_DATAFORMAT(PropDataFormatHandler, PropDataFormatHandler),\ + DEFINE_KSPROPERTY_ITEM_CONNECTION_ALLOCATORFRAMING(PropAllocatorFraming)\ +} + + +#define DEFINE_KSPROPERTY_STREAMSET(PinSet,\ + PropStreamAllocator, PropMasterClock, PropPipeId)\ +DEFINE_KSPROPERTY_TABLE(PinSet) {\ + DEFINE_KSPROPERTY_ITEM_STREAM_ALLOCATOR(PropStreamAllocator, PropStreamAllocator),\ + DEFINE_KSPROPERTY_ITEM_STREAM_MASTERCLOCK(PropMasterClock, PropMasterClock),\ + DEFINE_KSPROPERTY_ITEM_STREAM_PIPE_ID(PropPipeId, PropPipeId)\ +} + + + + Modified: trunk/reactos/drivers/ksfilter/ks/property.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/proper…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/property.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/property.c [iso-8859-1] Fri Apr 2 18:38:48 2010 @@ -137,7 +137,7 @@ /* get input property request */ Property = (PKSPROPERTY)IoStack->Parameters.DeviceIoControl.Type3InputBuffer; - DPRINT("KspPropertyHandler Irp %p PropertySetsCount %u PropertySet %p Allocator %p PropertyItemSize %u ExpectedPropertyItemSize %u\n", Irp, PropertySetsCount, PropertySet, Allocator, PropertyItemSize, sizeof(KSPROPERTY_ITEM)); +// DPRINT("KspPropertyHandler Irp %p PropertySetsCount %u PropertySet %p Allocator %p PropertyItemSize %u ExpectedPropertyItemSize %u\n", Irp, PropertySetsCount, PropertySet, Allocator, PropertyItemSize, sizeof(KSPROPERTY_ITEM)); /* sanity check */ ASSERT(PropertyItemSize == 0 || PropertyItemSize == sizeof(KSPROPERTY_ITEM));
14 years, 8 months
1
0
0
0
[janderwald] 46684: [KSPROXY, MSDVBNP] - Remove remaining DebugBreak - Add debug traces
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 2 18:25:18 2010 New Revision: 46684 URL:
http://svn.reactos.org/svn/reactos?rev=46684&view=rev
Log: [KSPROXY, MSDVBNP] - Remove remaining DebugBreak - Add debug traces Modified: trunk/reactos/dll/directx/ksproxy/enumpins.cpp trunk/reactos/dll/directx/ksproxy/input_pin.cpp trunk/reactos/dll/directx/ksproxy/mediasample.cpp trunk/reactos/dll/directx/ksproxy/output_pin.cpp trunk/reactos/dll/directx/ksproxy/precomp.h trunk/reactos/dll/directx/ksproxy/proxy.cpp trunk/reactos/dll/directx/msdvbnp/enumpins.cpp Modified: trunk/reactos/dll/directx/ksproxy/enumpins.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/enumpi…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/enumpins.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/enumpins.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -71,7 +71,6 @@ OutputDebugStringW(Buffer); CoTaskMemFree(lpstr); -DebugBreak(); return E_NOINTERFACE; } Modified: trunk/reactos/dll/directx/ksproxy/input_pin.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/input_…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/input_pin.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/input_pin.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -700,7 +700,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::Receive NotImplemented\n"); - DebugBreak(); #endif return E_NOTIMPL; @@ -712,7 +711,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::ReceiveMultiple NotImplemented\n"); - DebugBreak(); #endif return E_NOTIMPL; @@ -724,7 +722,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::ReceiveCanBlock NotImplemented\n"); - DebugBreak(); #endif return S_FALSE; @@ -923,7 +920,6 @@ OutputDebugStringW(L"CInputPin::KsQualityNotify NotImplemented\n"); #endif - DebugBreak(); return E_NOTIMPL; } @@ -1114,7 +1110,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::Connect NotImplemented\n"); - DebugBreak(); #endif return NOERROR; } @@ -1199,7 +1194,6 @@ #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::ConnectionMediaType NotImplemented\n"); - DebugBreak(); #endif return E_NOTIMPL; @@ -1496,7 +1490,6 @@ WCHAR Buffer[100]; swprintf(Buffer, L"CInputPin::CreatePin unexpected communication %u %s\n", m_Communication, m_PinName); OutputDebugStringW(Buffer); - DebugBreak(); #endif hr = E_FAIL; } @@ -1629,7 +1622,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::CreatePinHandle GetSupportedSets failed\n"); - DebugBreak(); #endif return hr; } @@ -1640,7 +1632,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CInputPin::CreatePinHandle LoadProxyPlugins failed\n"); - DebugBreak(); #endif return hr; } @@ -1783,7 +1774,6 @@ { // store plugin m_Plugins.push_back(pUnknown); -DebugBreak(); } // close key RegCloseKey(hSubKey); Modified: trunk/reactos/dll/directx/ksproxy/mediasample.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/medias…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/mediasample.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/mediasample.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -21,7 +21,6 @@ STDMETHODIMP_(ULONG) Release() { InterlockedDecrement(&m_Ref); - DebugBreak(); if (!m_Ref) { if (m_Allocator) @@ -280,7 +279,6 @@ CMediaSample::SetMediaType(AM_MEDIA_TYPE *pMediaType) { OutputDebugStringW(L"CMediaSample::SetMediaType NotImplemented\n"); - DebugBreak(); return E_NOTIMPL; } Modified: trunk/reactos/dll/directx/ksproxy/output_pin.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/output…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/output_pin.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/output_pin.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -1548,7 +1548,6 @@ OutputDebugStringW(L"COutputPin::Connect no IMemInputPin interface\n"); #endif - DebugBreak(); return hr; } @@ -1946,13 +1945,26 @@ // query for pin medium hr = KsQueryMediums(&MediumList); if (FAILED(hr)) - return hr; + { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"COutputPin::CreatePin KsQueryMediums failed %lx\n", hr); + OutputDebugStringW(Buffer); +#endif + return hr; + } // query for pin interface hr = KsQueryInterfaces(&InterfaceList); if (FAILED(hr)) { // failed +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"COutputPin::CreatePin KsQueryInterfaces failed %lx\n", hr); + OutputDebugStringW(Buffer); +#endif + CoTaskMemFree(MediumList); return hr; } @@ -2003,6 +2015,12 @@ CoTaskMemFree(MediumList); CoTaskMemFree(InterfaceList); +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"COutputPin::CreatePin failed to create interface handler %lx\n", hr); + OutputDebugStringW(Buffer); +#endif + return hr; } @@ -2010,7 +2028,12 @@ hr = InterfaceHandler->KsSetPin((IKsPin*)this); if (FAILED(hr)) { - // failed to load interface handler plugin + // failed to initialize interface handler plugin +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"COutputPin::CreatePin failed to initialize interface handler %lx\n", hr); + OutputDebugStringW(Buffer); +#endif InterfaceHandler->Release(); CoTaskMemFree(MediumList); CoTaskMemFree(InterfaceList); @@ -2027,7 +2050,6 @@ WCHAR Buffer[100]; swprintf(Buffer, L"COutputPin::CreatePin unexpected communication %u %s\n", m_Communication, m_PinName); OutputDebugStringW(Buffer); - DebugBreak(); #endif hr = E_FAIL; @@ -2036,6 +2058,12 @@ // free medium / interface / dataformat CoTaskMemFree(MediumList); CoTaskMemFree(InterfaceList); + +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"COutputPin::CreatePin Result %lx\n", hr); + OutputDebugStringW(Buffer); +#endif return hr; } @@ -2057,6 +2085,8 @@ //KSALLOCATOR_FRAMING Framing; //KSPROPERTY Property; //ULONG BytesReturned; + + OutputDebugStringW(L"COutputPin::CreatePinHandle\n"); if (m_hPin != INVALID_HANDLE_VALUE) { @@ -2173,7 +2203,6 @@ if (FAILED(InitializeIOThread())) { OutputDebugStringW(L"COutputPin::CreatePinHandle failed to initialize i/o thread\n"); - DebugBreak(); } LPGUID pGuid; @@ -2184,8 +2213,7 @@ if (FAILED(hr)) { #ifdef KSPROXY_TRACE - OutputDebugStringW(L"CInputPin::CreatePinHandle GetSupportedSets failed\n"); - DebugBreak(); + OutputDebugStringW(L"COutputPin::CreatePinHandle GetSupportedSets failed\n"); #endif return hr; } @@ -2195,8 +2223,7 @@ if (FAILED(hr)) { #ifdef KSPROXY_TRACE - OutputDebugStringW(L"CInputPin::CreatePinHandle LoadProxyPlugins failed\n"); - DebugBreak(); + OutputDebugStringW(L"COutputPin::CreatePinHandle LoadProxyPlugins failed\n"); #endif return hr; } @@ -2338,7 +2365,6 @@ { // store plugin m_Plugins.push_back(pUnknown); -DebugBreak(); } // close key RegCloseKey(hSubKey); Modified: trunk/reactos/dll/directx/ksproxy/precomp.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/precom…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/precomp.h [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/precomp.h [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -3,7 +3,7 @@ #define _FORCENAMELESSUNION #define BUILDING_KS #define _KSDDK_ -//#define KSPROXY_TRACE +#define KSPROXY_TRACE #include <dshow.h> //#include <streams.h> #include <ks.h> Modified: trunk/reactos/dll/directx/ksproxy/proxy.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ksproxy/proxy.…
============================================================================== --- trunk/reactos/dll/directx/ksproxy/proxy.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/ksproxy/proxy.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -1954,7 +1954,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CKsProxy::IsDirty Notimplemented\n"); - DebugBreak(); #endif return E_NOTIMPL; } @@ -2035,7 +2034,6 @@ }while(Length > 0); - DebugBreak(); return S_OK; } @@ -2059,7 +2057,6 @@ { #ifdef KSPROXY_TRACE OutputDebugStringW(L"CKsProxy::GetSizeMax Notimplemented\n"); - DebugBreak(); #endif return E_NOTIMPL; @@ -2480,23 +2477,50 @@ // query current instance count hr = GetPinInstanceCount(Index, &Instances); if (FAILED(hr)) + { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins GetPinInstanceCount failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif continue; + } + // query pin communication; hr = GetPinCommunication(Index, &Communication); if (FAILED(hr)) + { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins GetPinCommunication failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif continue; + } if (Instances.CurrentCount == Instances.PossibleCount) { // already maximum reached for this pin +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins Instances.CurrentCount == Instances.PossibleCount\n"); + OutputDebugStringW(Buffer); +#endif continue; } // get direction of pin hr = GetPinDataflow(Index, &DataFlow); if (FAILED(hr)) + { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins GetPinDataflow failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif continue; + } if (DataFlow == KSPIN_DATAFLOW_IN) hr = GetPinName(Index, DataFlow, InputPin, &PinName); @@ -2504,7 +2528,14 @@ hr = GetPinName(Index, DataFlow, OutputPin, &PinName); if (FAILED(hr)) + { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins GetPinName failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif continue; + } // construct the pins if (DataFlow == KSPIN_DATAFLOW_IN) @@ -2512,6 +2543,11 @@ hr = CInputPin_Constructor((IBaseFilter*)this, PinName, m_hDevice, Index, Communication, IID_IPin, (void**)&pPin); if (FAILED(hr)) { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins CInputPin_Constructor failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif CoTaskMemFree(PinName); continue; } @@ -2522,6 +2558,11 @@ hr = COutputPin_Constructor((IBaseFilter*)this, PinName, Index, Communication, IID_IPin, (void**)&pPin); if (FAILED(hr)) { +#ifdef KSPROXY_TRACE + WCHAR Buffer[100]; + swprintf(Buffer, L"CKsProxy::CreatePins COutputPin_Constructor failed with %lx\n", hr); + OutputDebugStringW(Buffer); +#endif CoTaskMemFree(PinName); continue; } @@ -2627,9 +2668,12 @@ hr = LoadProxyPlugins(pGuid, NumGuids); if (FAILED(hr)) { +#if 0 //HACK CloseHandle(m_hDevice); m_hDevice = NULL; return hr; +#endif + OutputDebugStringW(L"CKsProxy::LoadProxyPlugins failed!\n"); } // free sets @@ -2637,6 +2681,14 @@ // now create the input / output pins hr = CreatePins(); + +#ifdef KSPROXY_TRACE + swprintf(Buffer, L"CKsProxy::Load CreatePins %lx\n", hr); + OutputDebugStringW(Buffer); +#endif + + //HACK + hr = S_OK; return hr; } @@ -2986,10 +3038,6 @@ CKsProxy::EnumPins( IEnumPins **ppEnum) { -#ifdef KSPROXY_TRACE - OutputDebugStringW(L"CKsProxy::EnumPins\n"); -#endif - return CEnumPins_fnConstructor(m_Pins, IID_IEnumPins, (void**)ppEnum); } Modified: trunk/reactos/dll/directx/msdvbnp/enumpins.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/msdvbnp/enumpi…
============================================================================== --- trunk/reactos/dll/directx/msdvbnp/enumpins.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/directx/msdvbnp/enumpins.cpp [iso-8859-1] Fri Apr 2 18:25:18 2010 @@ -155,14 +155,6 @@ { CEnumPins * handler = new CEnumPins(NumPins, pins); -#ifdef MSDVBNP_TRACE - WCHAR Buffer[MAX_PATH]; - LPOLESTR lpstr; - StringFromCLSID(riid, &lpstr); - swprintf(Buffer, L"CEnumPins_fnConstructor riid %s pUnknown %p\n", lpstr, pUnknown); - OutputDebugStringW(Buffer); -#endif - if (!handler) return E_OUTOFMEMORY;
14 years, 8 months
1
0
0
0
[ekohl] 46683: [NTOSKRNL] - Check the SeTakeOwnership privilege only if WRITE_OWNER access is desired. - Move the check for token ownership from SepAccessCheck because this check grants access rights rather than checking them.
by ekohl@svn.reactos.org
Author: ekohl Date: Fri Apr 2 17:13:24 2010 New Revision: 46683 URL:
http://svn.reactos.org/svn/reactos?rev=46683&view=rev
Log: [NTOSKRNL] - Check the SeTakeOwnership privilege only if WRITE_OWNER access is desired. - Move the check for token ownership from SepAccessCheck because this check grants access rights rather than checking them. Modified: trunk/reactos/ntoskrnl/se/semgr.c Modified: trunk/reactos/ntoskrnl/se/semgr.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/se/semgr.c?rev=46…
============================================================================== --- trunk/reactos/ntoskrnl/se/semgr.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/se/semgr.c [iso-8859-1] Fri Apr 2 17:13:24 2010 @@ -314,6 +314,31 @@ return FALSE; } +static BOOLEAN +SepTokenIsOwner(PACCESS_TOKEN Token, + PSECURITY_DESCRIPTOR SecurityDescriptor) +{ + NTSTATUS Status; + PSID Sid = NULL; + BOOLEAN Defaulted; + + Status = RtlGetOwnerSecurityDescriptor(SecurityDescriptor, + &Sid, + &Defaulted); + if (!NT_SUCCESS(Status)) + { + DPRINT1("RtlGetOwnerSecurityDescriptor() failed (Status %lx)\n", Status); + return FALSE; + } + + if (Sid == NULL) + { + DPRINT1("Owner Sid is NULL\n"); + return FALSE; + } + + return SepSidInToken(Token, Sid); +} VOID NTAPI SeQuerySecurityAccessMask(IN SECURITY_INFORMATION SecurityInformation, @@ -438,22 +463,25 @@ CurrentAccess = PreviouslyGrantedAccess; /* RULE 2: Check token for 'take ownership' privilege */ - Privilege.Luid = SeTakeOwnershipPrivilege; - Privilege.Attributes = SE_PRIVILEGE_ENABLED; - - if (SepPrivilegeCheck(Token, - &Privilege, - 1, - PRIVILEGE_SET_ALL_NECESSARY, - AccessMode)) - { - CurrentAccess |= WRITE_OWNER; - if ((DesiredAccess & ~VALID_INHERIT_FLAGS) == - (CurrentAccess & ~VALID_INHERIT_FLAGS)) - { - *GrantedAccess = CurrentAccess; - *AccessStatus = STATUS_SUCCESS; - return TRUE; + if (DesiredAccess & WRITE_OWNER) + { + Privilege.Luid = SeTakeOwnershipPrivilege; + Privilege.Attributes = SE_PRIVILEGE_ENABLED; + + if (SepPrivilegeCheck(Token, + &Privilege, + 1, + PRIVILEGE_SET_ALL_NECESSARY, + AccessMode)) + { + CurrentAccess |= WRITE_OWNER; + if ((DesiredAccess & ~VALID_INHERIT_FLAGS) == + (CurrentAccess & ~VALID_INHERIT_FLAGS)) + { + *GrantedAccess = CurrentAccess; + *AccessStatus = STATUS_SUCCESS; + return TRUE; + } } } @@ -463,29 +491,6 @@ *GrantedAccess = 0; *AccessStatus = STATUS_ACCESS_DENIED; return FALSE; - } - - /* RULE 3: Check whether the token is the owner */ - Status = RtlGetOwnerSecurityDescriptor(SecurityDescriptor, - &Sid, - &Defaulted); - if (!NT_SUCCESS(Status)) - { - DPRINT1("RtlGetOwnerSecurityDescriptor() failed (Status %lx)\n", Status); - *AccessStatus = Status; - return FALSE; - } - - if (Sid && SepSidInToken(Token, Sid)) - { - CurrentAccess |= (READ_CONTROL | WRITE_DAC); - if ((DesiredAccess & ~VALID_INHERIT_FLAGS) == - (CurrentAccess & ~VALID_INHERIT_FLAGS)) - { - *GrantedAccess = CurrentAccess; - *AccessStatus = STATUS_SUCCESS; - return TRUE; - } } /* Fail if DACL is absent */ @@ -649,16 +654,43 @@ if (!SubjectContextLocked) SeLockSubjectContext(SubjectSecurityContext); - /* Call the internal function */ - ret = SepAccessCheck(SecurityDescriptor, - SubjectSecurityContext, - DesiredAccess, - PreviouslyGrantedAccess, - Privileges, - GenericMapping, - AccessMode, - GrantedAccess, - AccessStatus); + /* Check if the token is the owner and grant WRITE_DAC and READ_CONTROL rights */ + if (DesiredAccess & (WRITE_DAC | READ_CONTROL | MAXIMUM_ALLOWED)) + { + PACCESS_TOKEN Token = SubjectSecurityContext->ClientToken ? + SubjectSecurityContext->ClientToken : SubjectSecurityContext->PrimaryToken; + + if (SepTokenIsOwner(Token, + SecurityDescriptor)) + { + if (DesiredAccess & MAXIMUM_ALLOWED) + PreviouslyGrantedAccess |= (WRITE_DAC | READ_CONTROL); + else + PreviouslyGrantedAccess |= (DesiredAccess & (WRITE_DAC | READ_CONTROL)); + + DesiredAccess &= ~(WRITE_DAC | READ_CONTROL); + } + } + + if (DesiredAccess == 0) + { + *GrantedAccess = PreviouslyGrantedAccess; + *AccessStatus = STATUS_SUCCESS; + ret = TRUE; + } + else + { + /* Call the internal function */ + ret = SepAccessCheck(SecurityDescriptor, + SubjectSecurityContext, + DesiredAccess, + PreviouslyGrantedAccess, + Privileges, + GenericMapping, + AccessMode, + GrantedAccess, + AccessStatus); + } /* Release the lock if needed */ if (!SubjectContextLocked) @@ -686,6 +718,7 @@ PSECURITY_DESCRIPTOR CapturedSecurityDescriptor = NULL; SECURITY_SUBJECT_CONTEXT SubjectSecurityContext; KPROCESSOR_MODE PreviousMode = ExGetPreviousMode(); + ACCESS_MASK PreviouslyGrantedAccess = 0; PTOKEN Token; NTSTATUS Status; PAGED_CODE(); @@ -801,16 +834,38 @@ SubjectSecurityContext.ProcessAuditId = NULL; SeLockSubjectContext(&SubjectSecurityContext); - /* Now perform the access check */ - SepAccessCheck(SecurityDescriptor, // FIXME: use CapturedSecurityDescriptor - &SubjectSecurityContext, - DesiredAccess, - 0, - &PrivilegeSet, //FIXME - GenericMapping, - PreviousMode, - GrantedAccess, - AccessStatus); + /* Check if the token is the owner and grant WRITE_DAC and READ_CONTROL rights */ + if (DesiredAccess & (WRITE_DAC | READ_CONTROL | MAXIMUM_ALLOWED)) + { + if (SepTokenIsOwner(Token, SecurityDescriptor)) // FIXME: use CapturedSecurityDescriptor + { + if (DesiredAccess & MAXIMUM_ALLOWED) + PreviouslyGrantedAccess |= (WRITE_DAC | READ_CONTROL); + else + PreviouslyGrantedAccess |= (DesiredAccess & (WRITE_DAC | READ_CONTROL)); + + DesiredAccess &= ~(WRITE_DAC | READ_CONTROL); + } + } + + if (DesiredAccess == 0) + { + *GrantedAccess = PreviouslyGrantedAccess; + *AccessStatus = STATUS_SUCCESS; + } + else + { + /* Now perform the access check */ + SepAccessCheck(SecurityDescriptor, // FIXME: use CapturedSecurityDescriptor + &SubjectSecurityContext, + DesiredAccess, + PreviouslyGrantedAccess, + &PrivilegeSet, //FIXME + GenericMapping, + PreviousMode, + GrantedAccess, + AccessStatus); + } /* Unlock subject context */ SeUnlockSubjectContext(&SubjectSecurityContext);
14 years, 8 months
1
0
0
0
[janderwald] 46682: [NTOS] - Make sure SymbolicLink is null terminated
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 2 16:21:15 2010 New Revision: 46682 URL:
http://svn.reactos.org/svn/reactos?rev=46682&view=rev
Log: [NTOS] - Make sure SymbolicLink is null terminated Modified: trunk/reactos/ntoskrnl/io/iomgr/deviface.c Modified: trunk/reactos/ntoskrnl/io/iomgr/deviface.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/iomgr/deviface…
============================================================================== --- trunk/reactos/ntoskrnl/io/iomgr/deviface.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/io/iomgr/deviface.c [iso-8859-1] Fri Apr 2 16:21:15 2010 @@ -1061,6 +1061,7 @@ RtlAppendUnicodeStringToString(SymbolicLinkName, ReferenceString); } SymbolicLinkName->Buffer[SymbolicLinkName->Length/sizeof(WCHAR)] = L'\0'; + SymbolicLinkName->Length += sizeof(WCHAR); /* Write symbolic link name in registry */ SymbolicLinkName->Buffer[1] = '\\';
14 years, 8 months
1
0
0
0
[janderwald] 46681: [NTOS] - Add support for reference strings in IoOpenDeviceInterfaceRegistryKey
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 2 16:01:55 2010 New Revision: 46681 URL:
http://svn.reactos.org/svn/reactos?rev=46681&view=rev
Log: [NTOS] - Add support for reference strings in IoOpenDeviceInterfaceRegistryKey Modified: trunk/reactos/ntoskrnl/io/iomgr/deviface.c Modified: trunk/reactos/ntoskrnl/io/iomgr/deviface.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/iomgr/deviface…
============================================================================== --- trunk/reactos/ntoskrnl/io/iomgr/deviface.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/io/iomgr/deviface.c [iso-8859-1] Fri Apr 2 16:01:55 2010 @@ -51,31 +51,29 @@ OUT PHANDLE DeviceInterfaceKey) { WCHAR StrBuff[MAX_PATH], PathBuff[MAX_PATH]; - PWCHAR Guid; - UNICODE_STRING EnumU = RTL_CONSTANT_STRING(ENUM_ROOT L"\\"); + PWCHAR Guid, RefString; UNICODE_STRING DevParamU = RTL_CONSTANT_STRING(L"\\Device Parameters"); UNICODE_STRING PrefixU = RTL_CONSTANT_STRING(L"\\??\\"); UNICODE_STRING KeyPath, KeyName; UNICODE_STRING MatchableGuid; - HANDLE GuidKey, ChildKey; + UNICODE_STRING GuidString; + HANDLE GuidKey, hInterfaceKey; ULONG Index = 0; PKEY_BASIC_INFORMATION KeyInformation; ULONG KeyInformationLength; - PKEY_VALUE_PARTIAL_INFORMATION KeyValueInformation; - ULONG KeyValueInformationLength; OBJECT_ATTRIBUTES ObjectAttributes; NTSTATUS Status; ULONG RequiredLength; - MatchableGuid.Length = 0; - MatchableGuid.Length += swprintf(StrBuff, - L"##?#%ls", - &SymbolicLinkName->Buffer[PrefixU.Length / sizeof(WCHAR)]); - StrBuff[++MatchableGuid.Length] = UNICODE_NULL; - - MatchableGuid.Buffer = StrBuff; - MatchableGuid.MaximumLength = MAX_PATH * sizeof(WCHAR); - MatchableGuid.Length = (MatchableGuid.Length-1) * sizeof(WCHAR); + swprintf(StrBuff, L"##?#%s", &SymbolicLinkName->Buffer[PrefixU.Length / sizeof(WCHAR)]); + + RefString = wcsstr(StrBuff, L"\\"); + if (RefString) + { + RefString[0] = 0; + } + + RtlInitUnicodeString(&MatchableGuid, StrBuff); Guid = wcsstr(StrBuff, L"{"); if (!Guid) @@ -85,8 +83,11 @@ KeyPath.Length = 0; KeyPath.MaximumLength = MAX_PATH * sizeof(WCHAR); + GuidString.Buffer = Guid; + GuidString.Length = GuidString.MaximumLength = 38 * sizeof(WCHAR); + RtlAppendUnicodeToString(&KeyPath, BaseKeyString); - RtlAppendUnicodeToString(&KeyPath, Guid); + RtlAppendUnicodeStringToString(&KeyPath, &GuidString); InitializeObjectAttributes(&ObjectAttributes, &KeyPath, @@ -142,73 +143,62 @@ KeyName.Buffer = KeyInformation->Name; if (!RtlEqualUnicodeString(&KeyName, &MatchableGuid, TRUE)) + { + ExFreePool(KeyInformation); continue; - + } + + KeyPath.Length = 0; + RtlAppendUnicodeStringToString(&KeyPath, &KeyName); + RtlAppendUnicodeToString(&KeyPath, L"\\"); + + /* check for presence of a reference string */ + if (RefString) + { + /* append reference string */ + RefString[0] = L'#'; + RtlInitUnicodeString(&KeyName, RefString); + } + else + { + /* no reference string */ + RtlInitUnicodeString(&KeyName, L"#"); + } + RtlAppendUnicodeStringToString(&KeyPath, &KeyName); + + /* initialize reference string attributes */ InitializeObjectAttributes(&ObjectAttributes, - &KeyName, + &KeyPath, OBJ_CASE_INSENSITIVE, GuidKey, NULL); - Status = ZwOpenKey(&ChildKey, KEY_QUERY_VALUE, &ObjectAttributes); + + /* now open device interface key */ + Status = ZwOpenKey(&hInterfaceKey, KEY_CREATE_SUB_KEY, &ObjectAttributes); + + if (NT_SUCCESS(Status)) + { + /* check if it provides a DeviceParameters key */ + InitializeObjectAttributes(&ObjectAttributes, &DevParamU, OBJ_CASE_INSENSITIVE, hInterfaceKey, NULL); + + Status = ZwCreateKey(DeviceInterfaceKey, DesiredAccess, &ObjectAttributes, 0, NULL, REG_OPTION_NON_VOLATILE, NULL); + + if (NT_SUCCESS(Status)) + { + /* DeviceParameters key present */ + ZwClose(hInterfaceKey); + } + else + { + /* fall back to device interface */ + *DeviceInterfaceKey = hInterfaceKey; + Status = STATUS_SUCCESS; + } + } + + /* close class key */ ZwClose(GuidKey); - if (!NT_SUCCESS(Status)) - return Status; - - RtlInitUnicodeString(&KeyName, L"DeviceInstance"); - Status = ZwQueryValueKey(ChildKey, - &KeyName, - KeyValuePartialInformation, - NULL, - 0, - &RequiredLength); - if (Status == STATUS_BUFFER_TOO_SMALL) - { - KeyValueInformationLength = RequiredLength; - KeyValueInformation = ExAllocatePool(PagedPool, KeyValueInformationLength); - if (!KeyValueInformation) - { - ZwClose(ChildKey); - return Status; - } - - Status = ZwQueryValueKey(ChildKey, - &KeyName, - KeyValuePartialInformation, - KeyValueInformation, - KeyValueInformationLength, - &RequiredLength); - } - else - { - ZwClose(ChildKey); - return STATUS_OBJECT_PATH_NOT_FOUND; - } - ZwClose(ChildKey); - - if (!NT_SUCCESS(Status)) - return Status; - - KeyPath.Length = 0; - - KeyName.Length = KeyName.MaximumLength = KeyValueInformation->DataLength; - KeyName.Buffer = (PWCHAR)KeyValueInformation->Data; - - RtlAppendUnicodeStringToString(&KeyPath, &EnumU); - RtlAppendUnicodeStringToString(&KeyPath, &KeyName); - RtlAppendUnicodeStringToString(&KeyPath, &DevParamU); - - InitializeObjectAttributes(&ObjectAttributes, - &KeyPath, - OBJ_CASE_INSENSITIVE, - 0, - NULL); - Status = ZwCreateKey(DeviceInterfaceKey, - DesiredAccess, - &ObjectAttributes, - 0, - NULL, - REG_OPTION_NON_VOLATILE, - NULL); + ExFreePool(KeyInformation); return Status; }
14 years, 8 months
1
0
0
0
[janderwald] 46680: [MMIXER] - Copy device name when initializing WAVEINCAPS / WAVEOUTCAPS - Fixes display wave device name in cpl / waveInGetDevCaps / waveOutGetDevCaps
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 2 15:49:10 2010 New Revision: 46680 URL:
http://svn.reactos.org/svn/reactos?rev=46680&view=rev
Log: [MMIXER] - Copy device name when initializing WAVEINCAPS / WAVEOUTCAPS - Fixes display wave device name in cpl / waveInGetDevCaps / waveOutGetDevCaps Modified: trunk/reactos/lib/drivers/sound/mmixer/wave.c Modified: trunk/reactos/lib/drivers/sound/mmixer/wave.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/drivers/sound/mmixer/w…
============================================================================== --- trunk/reactos/lib/drivers/sound/mmixer/wave.c [iso-8859-1] (original) +++ trunk/reactos/lib/drivers/sound/mmixer/wave.c [iso-8859-1] Fri Apr 2 15:49:10 2010 @@ -360,6 +360,17 @@ WaveInfo->DeviceId = MixerData->DeviceId; WaveInfo->PinId = PinId; + + /* copy device name */ + if (bWaveIn) + { + wcscpy(WaveInfo->u.InCaps.szPname, DeviceName); + } + else + { + wcscpy(WaveInfo->u.OutCaps.szPname, DeviceName); + } + /* FIXME determine manufacturer / product id */ if (bWaveIn) { @@ -408,6 +419,8 @@ /* free dataranges buffer */ MixerContext->Free(MultipleItem); + + if (bWaveIn)
14 years, 8 months
1
0
0
0
[jimtabor] 46679: [Win32k] - Implement MakeInfoDC and support functions. Dedicated to Timo.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Fri Apr 2 13:53:14 2010 New Revision: 46679 URL:
http://svn.reactos.org/svn/reactos?rev=46679&view=rev
Log: [Win32k] - Implement MakeInfoDC and support functions. Dedicated to Timo. Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h trunk/reactos/subsystems/win32/win32k/include/pdevobj.h trunk/reactos/subsystems/win32/win32k/include/surface.h trunk/reactos/subsystems/win32/win32k/objects/dclife.c trunk/reactos/subsystems/win32/win32k/objects/dcutil.c trunk/reactos/subsystems/win32/win32k/objects/device.c Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -177,6 +177,8 @@ BOOL FASTCALL IntGdiCleanDC(HDC hDC); VOID FASTCALL IntvGetDeviceCaps(PPDEVOBJ, PDEVCAPS); INT FASTCALL IntGdiGetDeviceCaps(PDC,INT); +BOOL FASTCALL MakeInfoDC(PDC,BOOL); +BOOL FASTCALL IntSetDefaultRegion(PDC); extern PPDEVOBJ pPrimarySurface; @@ -228,6 +230,5 @@ pdc->dclevel.ppal = ppal; } -BOOL FASTCALL -IntPrepareDriverIfNeeded(VOID); +BOOL FASTCALL IntPrepareDriverIfNeeded(VOID); extern PDEVOBJ PrimarySurface; Modified: trunk/reactos/subsystems/win32/win32k/include/pdevobj.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/pdevobj.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/pdevobj.h [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -88,8 +88,8 @@ // PVOID TypeOneInfo; PVOID pvGammaRamp; /* Gamma ramp pointer. */ // PVOID RemoteTypeOne; -// ULONG ulHorzRes; -// ULONG ulVertRes; + ULONG ulHorzRes; + ULONG ulVertRes; // PFN_DrvSetPointerShape pfnDrvSetPointerShape; // PFN_DrvMovePointer pfnDrvMovePointer; PFN_DrvMovePointer pfnMovePointer; @@ -107,7 +107,7 @@ // HANDLE hSpooler; /* Handle to spooler, if spooler dev driver. */ // PVOID pDesktopId; PGRAPHICS_DEVICE pGraphicsDevice; -// POINTL ptlOrigion; + POINTL ptlOrigion; PVOID pdmwDev; /* Ptr->DEVMODEW.dmSize + dmDriverExtra == alloc size. */ // DWORD Unknown3; FLONG DxDd_Flags; /* DxDD active status flags. */ @@ -141,4 +141,6 @@ EDD_DIRECTDRAW_GLOBAL EDDgpl; } PDEVEDD, *PPDEVEDD; +PSIZEL FASTCALL PDEV_sizl(PPDEVOBJ, PSIZEL); + extern ULONG gdwDirectDrawContext; Modified: trunk/reactos/subsystems/win32/win32k/include/surface.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/surface.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/surface.h [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -2,6 +2,8 @@ #include "win32.h" #include "gdiobj.h" + +#define PDEV_SURFACE 0x80000000 /* GDI surface object */ typedef struct _SURFACE Modified: trunk/reactos/subsystems/win32/win32k/objects/dclife.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/dclife.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/dclife.c [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -586,8 +586,59 @@ NtGdiSetVirtualResolution(DCHandle, 0, 0, 0, 0); } +BOOL +FASTCALL +MakeInfoDC(PDC pdc, BOOL bSet) +{ + PSURFACE pSurface; + SIZEL sizl; + + /* Can not be a display DC. */ + if (pdc->fs & DC_FLAG_DISPLAY) return FALSE; + if (bSet) + { + if (pdc->fs & DC_FLAG_TEMPINFODC || pdc->dctype == DC_TYPE_DIRECT) + return FALSE; + + pSurface = pdc->dclevel.pSurface; + pdc->fs |= DC_FLAG_TEMPINFODC; + pdc->pSurfInfo = pSurface; + pdc->dctype = DC_TYPE_INFO; + pdc->dclevel.pSurface = NULL; + + if (PDEV_sizl(pdc->ppdev, &sizl)->cx == pdc->dclevel.sizl.cx && + PDEV_sizl(pdc->ppdev, &sizl)->cy == pdc->dclevel.sizl.cy) + return TRUE; + + pdc->dclevel.sizl.cx = PDEV_sizl(pdc->ppdev, &sizl)->cx; + pdc->dclevel.sizl.cy = sizl.cy; + IntSetDefaultRegion(pdc); + } + else + { + if (!(pdc->fs & DC_FLAG_TEMPINFODC) || pdc->dctype != DC_TYPE_INFO) + return FALSE; + + pSurface = pdc->pSurfInfo; + pdc->fs &= ~DC_FLAG_TEMPINFODC; + pdc->dclevel.pSurface = pSurface; + pdc->dctype = DC_TYPE_DIRECT; + pdc->pSurfInfo = NULL; + + if ( !pSurface || + (pSurface->SurfObj.sizlBitmap.cx == pdc->dclevel.sizl.cx && + pSurface->SurfObj.sizlBitmap.cy == pdc->dclevel.sizl.cy) ) + return TRUE; + + pdc->dclevel.sizl.cx = pSurface->SurfObj.sizlBitmap.cx; + pdc->dclevel.sizl.cy = pSurface->SurfObj.sizlBitmap.cy; + IntSetDefaultRegion(pdc); + } + return TRUE; +} + /* -* @unimplemented +* @implemented */ BOOL APIENTRY @@ -595,7 +646,14 @@ IN HDC hdc, IN BOOL bSet) { - UNIMPLEMENTED; + BOOL Ret; + PDC pdc = DC_LockDc(hdc); + if (pdc) + { + Ret = MakeInfoDC(pdc, bSet); + DC_UnlockDc(pdc); + return Ret; + } return FALSE; } Modified: trunk/reactos/subsystems/win32/win32k/objects/dcutil.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/dcutil.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/dcutil.c [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -124,6 +124,71 @@ return SurfObj->hsurf == PrimarySurface.pSurface; // <- FIXME: WTF? } #endif + +BOOL +FASTCALL +IntSetDefaultRegion(PDC pdc) +{ + PSURFACE pSurface; + PROSRGNDATA prgn; + RECTL rclWnd, rclClip; + + IntGdiReleaseRaoRgn(pdc); + + rclWnd.left = 0; + rclWnd.top = 0; + rclWnd.right = pdc->dclevel.sizl.cx; + rclWnd.bottom = pdc->dclevel.sizl.cy; + rclClip = rclWnd; + +// EngAcquireSemaphoreShared(pdc->ppdev->hsemDevLock); + if (pdc->ppdev->flFlags & PDEV_META_DEVICE) + { + pSurface = pdc->dclevel.pSurface; + if (pSurface && pSurface->flFlags & PDEV_SURFACE) + { + rclClip.left += pdc->ppdev->ptlOrigion.x; + rclClip.top += pdc->ppdev->ptlOrigion.y; + rclClip.right += pdc->ppdev->ptlOrigion.x; + rclClip.bottom += pdc->ppdev->ptlOrigion.y; + } + } +// EngReleaseSemaphore(pdc->ppdev->hsemDevLock); + + prgn = pdc->prgnVis; + + if (prgn && prgn != prgnDefault) + { + REGION_SetRectRgn( prgn, + rclClip.left, + rclClip.top, + rclClip.right , + rclClip.bottom ); + } + else + { + prgn = IntSysCreateRectpRgn( rclClip.left, + rclClip.top, + rclClip.right , + rclClip.bottom ); + pdc->prgnVis = prgn; + } + + if (prgn) + { + pdc->ptlDCOrig.x = 0; + pdc->ptlDCOrig.y = 0; + pdc->erclWindow = rclWnd; + pdc->erclClip = rclClip; + /* Might be an InitDC or DCE....*/ + pdc->ptlFillOrigin.x = pdc->dcattr.VisRectRegion.Rect.right; + pdc->ptlFillOrigin.y = pdc->dcattr.VisRectRegion.Rect.bottom; + return TRUE; + } + + pdc->prgnVis = prgnDefault; + return FALSE; +} BOOL APIENTRY Modified: trunk/reactos/subsystems/win32/win32k/objects/device.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/device.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/device.c [iso-8859-1] Fri Apr 2 13:53:14 2010 @@ -19,6 +19,22 @@ static KEVENT VideoDriverPrepared; PDC defaultDCstate = NULL; +PSIZEL +FASTCALL +PDEV_sizl(PPDEVOBJ ppdev, PSIZEL psizl) +{ + if (ppdev->flFlags & PDEV_META_DEVICE) + { + psizl->cx = ppdev->ulHorzRes; + psizl->cy = ppdev->ulVertRes; + } + else + { + psizl->cx = ppdev->gdiinfo.ulHorzRes; + psizl->cy = ppdev->gdiinfo.ulVertRes; + } + return psizl; +} NTSTATUS FASTCALL InitDcImpl(VOID)
14 years, 8 months
1
0
0
0
[akhaldi] 46678: Forgot this one.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Apr 2 13:44:39 2010 New Revision: 46678 URL:
http://svn.reactos.org/svn/reactos?rev=46678&view=rev
Log: Forgot this one. Modified: branches/header-work/include/psdk/nspapi.h Modified: branches/header-work/include/psdk/nspapi.h URL:
http://svn.reactos.org/svn/reactos/branches/header-work/include/psdk/nspapi…
============================================================================== --- branches/header-work/include/psdk/nspapi.h [iso-8859-1] (original) +++ branches/header-work/include/psdk/nspapi.h [iso-8859-1] Fri Apr 2 13:44:39 2010 @@ -37,8 +37,8 @@ #ifndef RC_INVOKED #if defined (_WINSOCKAPI_) || defined (_WINSOCK2API_) /* needed for LPSOCKADDR */ -#ifndef __CSADDR_T_DEFINED /* also in winsock2.h, but not in winsock.h */ -#define __CSADDR_T_DEFINED +#ifndef __CSADDR_DEFINED__ /* also in winsock2.h, but not in winsock.h */ +#define __CSADDR_DEFINED__ typedef struct _SOCKET_ADDRESS { LPSOCKADDR lpSockaddr; INT iSockaddrLength;
14 years, 8 months
1
0
0
0
[tkreuzer] 46677: Remove svn:mergeinfo property from several files
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Fri Apr 2 13:35:58 2010 New Revision: 46677 URL:
http://svn.reactos.org/svn/reactos?rev=46677&view=rev
Log: Remove svn:mergeinfo property from several files Modified: trunk/reactos/dll/directx/bdaplgin/classfactory.cpp (props changed) trunk/reactos/dll/directx/d3d8/d3d8.spec (props changed) trunk/reactos/dll/directx/dsound_new/classfactory.c (props changed) trunk/reactos/dll/directx/dsound_new/dsound.spec (props changed) trunk/reactos/dll/directx/dsound_new/dsound_convert.c (props changed) trunk/reactos/dll/directx/dsound_new/regsvr.c (props changed) trunk/reactos/dll/shellext/devcpux/devcpux.spec (props changed) trunk/reactos/dll/shellext/slayer/slayer.spec (props changed) trunk/reactos/include/ndk/amd64/ (props changed) trunk/reactos/include/ndk/amd64/asmmacro.S (props changed) trunk/reactos/lib/sdk/crt/time/ (props changed) trunk/reactos/ntoskrnl/kdbg/ (props changed) trunk/reactos/subsystems/win32/win32k/include/engobjects.h (props changed) trunk/reactos/tools/rsym/rsym.c (props changed) trunk/reactos/tools/rsym/rsym.h (props changed) trunk/reactos/tools/rsym/rsym.mak (props changed) trunk/reactos/tools/rsym/rsym_common.c (props changed) Propchange: trunk/reactos/dll/directx/bdaplgin/classfactory.cpp ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,3 +1,0 @@ -/branches/header-work/dll/directx/bdaplgin/classfactory.cpp:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/bdaplgin/classfactory.cpp:34741,34870,36969,40927,41070,41500,44339,44467-44468,44470-44471,44501,44503-44504,44506,44511-44512,44521,44523-44526,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 -/branches/ros-amd64-bringup/reactos/dll/directx/ksproxy/classfactory.cpp:34711-34712,34743,34780-34782,34812,34839,34842,34908-34909,34917,34965,35323-35324,35347-35348,35361,35436,35509,35515,35588,35683,35739,35746,35762,35771,35777,35789,35805,35823,35827,35902,35904-35906,35942,35947-35949,35952-35953,35966,36013,36172,36360,36388-36389,36445,36502-36503,36505,36570,36614,36899,36930,36936,36992,37323,37434,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38148-38151,38264-38265,38268,38355,39151,39333,39345,39639,40122-40123,40125,40128,40155,40247,40324,40753,40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41030,41044-41045,41047-41050,41052,41082-41086,41097-41098,41101,41449,41479,41484-41485,41499,41531,41536,41540,41546-41547,41549,43080,43426,43454,43506,43566,43574,43598,43600-43602,43604-43605,43677,43682,43757,43775,43838-43840,43857-43858,43860,43905-43907,43969,44002,44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338,44389,44391,44426,44460,44530,44540,44601 Propchange: trunk/reactos/dll/directx/d3d8/d3d8.spec ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/dll/directx/d3d8/d3d8.spec:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/d3d8/d3d8.spec:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36930,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38148-38151,38264-38265,38268,38355,39333,39335,39345,39639,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41029,41044-41045,41047-41050,41052,41070,41082-41086,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,41549,43080,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/dll/directx/dsound_new/classfactory.c ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,3 +1,0 @@ -/branches/header-work/dll/directx/dsound_new/classfactory.c:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound_new/classfactory.c:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36502-36503,36505,36898,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38355,39335,39639,40122-40123,40125,40155,40247,40324,40753,40927,40986-40987,40989,40993,40995-40996,41001,41029,41044-41045,41047-41049,41070,41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857,43860,43905,43907,43969,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 -/branches/ros-amd64-bringup/reactos/dll/win32/netshell/classfactory.c:34711-34712,34743,34812,34839,34842,34917,35323-35324,35347-35348,35361,35436,35509,35515,35588,35739,35746,35771,35789,35823,35902,35904-35906,35942,35947-35949,35952-35953,35966,36013,36360,36388-36389,36570,36614,36930,37323,37434,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38148,38151,38265,38268,39151,39333,39345,40991,41000,41027-41028,41030,41050,41052,41082-41086,41499,41549,43080,43426,43454,43677,43682 Propchange: trunk/reactos/dll/directx/dsound_new/dsound.spec ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,3 +1,0 @@ -/branches/header-work/dll/directx/dsound_new/dsound.spec:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound/dsound.spec:34711-34712,34743,34812,34839,34842,34917,35323-35324,35347-35348,35361,35436,35509,35515,35588,35739,35746,35771,35789,35823,35902,35904-35906,35942,35947-35949,35952-35953,35966,36013,36360,36388-36389,36570,36614,36930,37323,37434,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38148,38151,38265,38268,39151,39333,39345,40991,41000,41027-41028,41030,41050,41052,41082-41086,41499,41549,43080,43426,43454,43677,43682 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound_new/dsound.spec:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36502-36503,36505,36898,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38355,39335,39639,40122-40123,40125,40155,40247,40324,40753,40927,40986-40987,40989,40993,40995-40996,41001,41029,41044-41045,41047-41049,41070,41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857,43860,43905,43907,43969,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/dll/directx/dsound_new/dsound_convert.c ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,3 +1,0 @@ -/branches/header-work/dll/directx/dsound_new/dsound_convert.c:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound/dsound_convert.c:34711-34712,34743,34780-34782,34812,34839,34842,34908-34909,34917,34965,35323-35324,35347-35348,35361,35436,35509,35515,35588,35683,35739,35746,35762,35771,35777,35789,35805,35823,35827,35902,35904-35906,35942,35947-35949,35952-35953,35966,36013,36172,36360,36388-36389,36445,36502-36503,36505,36570,36614,36899,36930,36936,36992,37323,37434,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38148-38151,38264-38265,38268,38355,39151,39333,39345,39639,40122-40123,40125,40128,40155,40247,40324,40753,40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41030,41044-41045,41047-41050,41052,41082-41086,41097-41098,41101,41449,41479,41484-41485,41499,41531,41536,41540,41546-41547,41549,43080,43426,43454,43506,43566,43574,43598,43600-43602,43604-43605,43677,43682,43757,43775,43838-43840,43857-43858,43860,43905-43907,43969,44002,44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338,44389,44391,44426,44460,44530,44540,44601 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound_new/dsound_convert.c:34741,34870,36969,40927,41070,41500,44339,44467-44468,44470-44471,44501,44503-44504,44506,44511-44512,44521,44523-44526,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/dll/directx/dsound_new/regsvr.c ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,3 +1,0 @@ -/branches/header-work/dll/directx/dsound_new/regsvr.c:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound/regsvr.c:34711-34712,34743,34812,34839,34842,34917,35323-35324,35347-35348,35361,35436,35509,35515,35588,35739,35746,35771,35789,35823,35902,35904-35906,35942,35947-35949,35952-35953,35966,36013,36360,36388-36389,36570,36614,36930,37323,37434,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38148,38151,38265,38268,39151,39333,39345,40991,41000,41027-41028,41030,41050,41052,41082-41086,41499,41549,43080,43426,43454,43677,43682 -/branches/ros-amd64-bringup/reactos/dll/directx/dsound_new/regsvr.c:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36502-36503,36505,36898,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38355,39335,39639,40122-40123,40125,40155,40247,40324,40753,40927,40986-40987,40989,40993,40995-40996,41001,41029,41044-41045,41047-41049,41070,41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857,43860,43905,43907,43969,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/dll/shellext/devcpux/devcpux.spec ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/dll/shellext/devcpux/devcpux.spec:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/shellext/devcpux/devcpux.spec:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38268,38355,39333,39335,39345,39639,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41029,41044-41045,41047-41050,41052,41070,41082-41086,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,41549,43080,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/dll/shellext/slayer/slayer.spec ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/dll/shellext/slayer/slayer.spec:45691-46463 -/branches/ros-amd64-bringup/reactos/dll/shellext/slayer/slayer.spec:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38268,38355,39333,39335,39345,39639,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41029,41044-41045,41047-41050,41052,41070,41082-41086,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,41549,43080,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/include/ndk/amd64/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/include/ndk/amd64:45691-46463 -/branches/ros-amd64-bringup/reactos/include/ndk/amd64:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34925,34965,34967,34970,35323-35324,35347-35348,35361,35436,35509,35588,35655,35683,35739,35762,35777,35781,35805,35823,35827,35952,35966,36011-36012,36172,36360,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37323,37434,37472,37475,37536,37820-37821,37868-37869,37990,38013-38014,38092,38100,38149-38150,38264,38355,39335,39338,39347,39639,40088,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41029-41030,41044-41045,41047-41049,41070-41071,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43426,43447,43454,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43777,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44178,44205,44218,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44491,44499-44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44623,44631,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/include/ndk/amd64/asmmacro.S ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/include/ndk/amd64/asmmacro.S:45691-46463 -/branches/ros-amd64-bringup/reactos/include/ndk/amd64/asmmacro.S:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37475,37536,37820-37821,37868-37869,37990,38013-38014,38092,38100,38149-38150,38264,38355,39335,39338,39347,39639,40088,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41029-41030,41044-41045,41047-41049,41070-41071,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43426,43447,43454,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43777,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44178,44205,44218,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44491,44499-44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44623,44631,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/lib/sdk/crt/time/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,4 +1,0 @@ -/branches/header-work/lib/sdk/crt/time:45691-46463 -/branches/ros-amd64-bringup/reactos/lib/sdk/crt/time:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38268,38355,39335,39639,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 -/branches/ros-amd64-bringup/reactos/lib/sdk/crt/time_new:42414 -/trunk/reactos/lib/sdk/crt/time_new:39350-42241 Propchange: trunk/reactos/ntoskrnl/kdbg/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/ntoskrnl/kdbg:45691-46463 -/branches/ros-amd64-bringup/reactos/ntoskrnl/kdbg:34711-34712,34741,34743,34780-34782,34803,34812,34839,34842,34864,34870,34874,34877,34908-34909,34917,34965,34969,34986,35323-35324,35347-35348,35361,35436,35444,35509,35515,35588,35655,35683,35739,35746,35762,35771,35777,35781,35789,35805,35823,35827,35902,35904-35906,35942,35947-35949,35952-35953,35966,35968,35970-35971,36011-36013,36172,36332,36360,36380,36388-36389,36397,36445,36502-36503,36505,36570,36614,36898-36899,36930,36936,36949,36951,36958,36961,36964,36969,36972,36992,37323,37433-37435,37472,37475,37536,37820-37821,37868-37869,37873,37990-37991,38013-38014,38092,38099-38100,38148-38151,38264-38265,38268,38355,39151,39160,39333,39335,39345,39522,39639,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40991,40993,40995-40996,41000-41001,41027-41030,41044-41045,41047-41050,41052,41070,41082-41086,41097-41098,41101,41449,41479,41484-41485,41499-41500,41502,41531,41536,41540,41546-41547,41549,43080,43426,43454,43506,43566,43574,43598,43600-43602,43604-43605,43677,43682,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/subsystems/win32/win32k/include/engobjects.h ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/subsystems/win32/win32k/include/engobjects.h:45691-46463 -/branches/ros-amd64-bringup/reactos/subsystems/win32/win32k/include/engobjects.h:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,38092,38100,38149-38150,38264,38268,38355,39335,39639,40095,40122-40123,40125,40128,40155,40247,40324,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/tools/rsym/rsym.c ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/tools/rsym/rsym.c:45691-46463 -/branches/ros-amd64-bringup/reactos/tools/rsym/rsym.c:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37291,37302,37305,37320,37329,37462,37895,38092,38100,38129,38149-38150,38264,38268,38330-38331,38341,38355,38947,38973,39072,39114,39121,39335,39639,40122-40123,40125,40128,40155,40247,40324,40605,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/tools/rsym/rsym.h ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/tools/rsym/rsym.h:45691-46463 -/branches/ros-amd64-bringup/reactos/tools/rsym/rsym.h:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37291,37302,37305,37320,37329,37462,37895,38092,38100,38129,38149-38150,38264,38268,38330-38331,38341,38355,38947,38973,39072,39114,39121,39335,39639,40122-40123,40125,40128,40155,40247,40324,40605,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/tools/rsym/rsym.mak ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/tools/rsym/rsym.mak:45691-46463 -/branches/ros-amd64-bringup/reactos/tools/rsym/rsym.mak:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37291,37302,37305,37320,37329,37462,37895,38092,38100,38129,38149-38150,38264,38268,38330-38331,38341,38355,38947,38973,39072,39114,39121,39335,39639,40122-40123,40125,40128,40155,40247,40324,40605,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589 Propchange: trunk/reactos/tools/rsym/rsym_common.c ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo (removed) @@ -1,2 +1,0 @@ -/branches/header-work/tools/rsym/rsym_common.c:45691-46463 -/branches/ros-amd64-bringup/reactos/tools/rsym/rsym_common.c:34741,34780-34782,34803,34864,34870,34874,34877,34908-34909,34965,35655,35683,35762,35777,35781,35805,35827,36011-36012,36172,36380,36397,36445,36502-36503,36505,36898-36899,36936,36949,36951,36958,36961,36964,36969,36972,36992,37291,37302,37305,37320,37329,37462,37895,38092,38100,38129,38149-38150,38264,38268,38330-38331,38341,38355,38947,38973,39072,39114,39121,39335,39639,40122-40123,40125,40128,40155,40247,40324,40605,40753,40927-40928,40986-40987,40989,40993,40995-40996,41001,41028-41029,41044-41045,41047-41049,41070,41097-41098,41101,41449,41479,41484-41485,41500,41502,41531,41536,41540,41546-41547,43506,43566,43574,43598,43600-43602,43604-43605,43757,43775,43836,43838-43840,43857-43858,43860,43905-43907,43969,44002,44036-44037,44039-44040,44044-44045,44065,44095,44123,44144,44205,44238,44294,44338-44339,44389,44391,44426,44460,44467-44468,44470-44471,44499,44501,44503-44504,44506,44510-44512,44521,44523-44526,44530,44540,44601,44772,45124,45126-45127,46394,46478,46511,46524,46526,46534-46535,46537-46539,46589
14 years, 8 months
1
0
0
0
[akhaldi] 46676: [PSDK] - Fix a couple of macro names.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Apr 2 13:32:01 2010 New Revision: 46676 URL:
http://svn.reactos.org/svn/reactos?rev=46676&view=rev
Log: [PSDK] - Fix a couple of macro names. Modified: branches/header-work/include/psdk/nspapi.h branches/header-work/include/psdk/winsock2.h Modified: branches/header-work/include/psdk/nspapi.h URL:
http://svn.reactos.org/svn/reactos/branches/header-work/include/psdk/nspapi…
============================================================================== --- branches/header-work/include/psdk/nspapi.h [iso-8859-1] (original) +++ branches/header-work/include/psdk/nspapi.h [iso-8859-1] Fri Apr 2 13:32:01 2010 @@ -36,7 +36,7 @@ #ifndef RC_INVOKED -#if defined (_WINSOCK_H) || defined (_WINSOCK2_H) /* needed for LPSOCKADDR */ +#if defined (_WINSOCKAPI_) || defined (_WINSOCK2API_) /* needed for LPSOCKADDR */ #ifndef __CSADDR_T_DEFINED /* also in winsock2.h, but not in winsock.h */ #define __CSADDR_T_DEFINED typedef struct _SOCKET_ADDRESS { Modified: branches/header-work/include/psdk/winsock2.h URL:
http://svn.reactos.org/svn/reactos/branches/header-work/include/psdk/winsoc…
============================================================================== --- branches/header-work/include/psdk/winsock2.h [iso-8859-1] (original) +++ branches/header-work/include/psdk/winsock2.h [iso-8859-1] Fri Apr 2 13:32:01 2010 @@ -2726,4 +2726,4 @@ #endif #endif */ -#endif /* !(defined _WINSOCK2API_ || defined _WINSOCK_H) */ +#endif /* !(defined _WINSOCK2API_ || defined _WINSOCKAPI_) */
14 years, 8 months
1
0
0
0
← Newer
1
...
36
37
38
39
40
41
42
43
44
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
Results per page:
10
25
50
100
200