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
2025
January
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
June 2005
----- 2025 -----
January 2025
----- 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
649 discussions
Start a n
N
ew thread
[navaraf] 16029: Fix position of the STDCALL keyword. Spotted by KJK::Hyperion.
by navaraf@svn.reactos.com
Fix position of the STDCALL keyword. Spotted by KJK::Hyperion. Modified: trunk/reactos/ntoskrnl/ex/util.c _____ Modified: trunk/reactos/ntoskrnl/ex/util.c --- trunk/reactos/ntoskrnl/ex/util.c 2005-06-18 12:39:24 UTC (rev 16028) +++ trunk/reactos/ntoskrnl/ex/util.c 2005-06-18 12:55:02 UTC (rev 16029) @@ -19,8 +19,8 @@ /* * @unimplemented */ +NTSTATUS STDCALL -NTSTATUS ExUuidCreate( OUT UUID *Uuid ) @@ -32,8 +32,8 @@ /* * @implemented */ +BOOLEAN STDCALL -BOOLEAN ExVerifySuite( SUITE_TYPE SuiteType )
19 years, 6 months
1
0
0
0
[navaraf] 16028: ntapi.h:
by navaraf@svn.reactos.com
ntapi.h: - Define LANGID and fix definition of PLANGID. - Define PVM_COUNTERS, SYSTEM_CACHE_INFORMATION and SYSTEM_INTERRUPT_INFORMATION. - Match the ROS version of LPC_MESSAGE (the structure itself should be named PORT_MESSAGE and belongs to ntifs.h). - Move KEY_SET_INFORMATION_CLASS definiton to winddk.h. - Make the first parameter of NtAllocateUuids PULARGE_INTEGER. - Declare NtSetUuidSeed. - Fix definition of ATOM_INFORMATION_CLASS and ATOM_BASIC_INFORMATION to match ReactOS versions. winddk.h: - Define NTHALAPI and use it to mark HAL exports instead of NTOSAPI. - Define PADAPTER_OBJECT, EVENT_QUERY_STATE, EVENT_MODIFY_STATE, EVENT_ALL_ACCESS, SEMAPHORE_QUERY_STATE, SEMAPHORE_MODIFY_STATE, SEMAPHORE_ALL_ACCESS, IRP_QUOTA_CHARGED, IRP_ALLOCATED_MUST_SUCCEED, IRP_ALLOCATED_FIXED_SIZE, IRP_LOOKASIDE_ALLOCATION, HalDispatchTableVersion, HalQuerySystemInformation, HalSetSystemInformation, HalQueryBusSlots, HalDeviceControl, HalIoAssignDriveLetters, HalIoReadPartitionTable, HalIoSetPartitionInformation, HalIoWritePartitionTable, HalReferenceHandlerForBus, HalReferenceBusHandler, HalDereferenceBusHandler, IO_TYPE_ADAPTER, IO_TYPE_CONTROLLER, IO_TYPE_DEVICE, IO_TYPE_DRIVER, IO_TYPE_FILE, IO_TYPE_IRP, IO_TYPE_MASTER_ADAPTER, IO_TYPE_OPEN_PACKET, IO_TYPE_TIMER, IO_TYPE_VPB, IO_TYPE_ERROR_LOG, IO_TYPE_ERROR_MESSAGE, IO_TYPE_DEVICE_OBJECT_EXTENSION, IO_FORCE_ACCESS_CHECK and IO_NO_PARAMETER_CHECKING. - Remove declaration of HalPrivateDispatchTable, it doesn't belong to public headers. - Fix declaration of WAIT_CONTEXT_BLOCK, HalDispatchTable, DRIVER_EXTENSION, GENERAL_LOOKASIDE, NPAGED_LOOKASIDE_LIST, PAGED_LOOKASIDE_LIST, KPCR_TIB, MmHighestUserAddress, MmSystemRangeStart, MmUserProbeAddress, KdDebuggerNotPresent and KdDebuggerEnabled. - Declare KEY_WRITE_TIME_INFORMATION, KEY_USER_FLAGS_INFORMATION, KEY_SET_INFORMATION_CLASS, KfAcquireSpinLock, KfReleaseSpinLock and ExfInterlockedCompareExchange64. winnt4.h: - Declare HalAcquireDisplayOwnership and HalAllocateAdapterChannel. ntifs.h: - Fix definition of NTKERNELAPI. - Fix declaration of FsRtlLegalAnsiCharacterArray, FsRtlNotifyInitializeSync, FsRtlNotifyUninitializeSync, IoCheckFunctionAccess and PsGetProcessExitTime. - Declare IoStatisticsLock, IoReadOperationCount, IoWriteOperationCount, IoOtherOperationCount, IoReadTransferCount, IoWriteTransferCount, IoOtherTransferCount, FSRTL_ADVANCED_FCB_HEADER, FSRTL_PER_STREAM_CONTEXT, PFILTER_REPORT_CHANGE, FS_FILTER_SECTION_SYNC_TYPE, FS_FILTER_PARAMETERS, FS_FILTER_CALLBACK_DATA, PFS_FILTER_CALLBACK, PFS_FILTER_COMPLETION_CALLBACK, FS_FILTER_CALLBACKS, READ_LIST, ExInitializeRundownProtection, ExReInitializeRundownProtection, ExAcquireRundownProtection, ExAcquireRundownProtectionEx, ExReleaseRundownProtection, ExReleaseRundownProtectionEx, ExRundownCompleted, ExWaitForRundownProtectionRelease, FsRtlMdlReadDev, FsRtlPrepareMdlWriteDev, PFSRTL_STACK_OVERFLOW_ROUTINE, FsRtlPostStackOverflow, FsRtlPostPagingFileStackOverflow, IoAttachDeviceToDeviceStackSafe, IoQueueThreadIrp, KeInitializeMutant, KeReadStateMutant, KeReleaseMutant and PsIsSystemThread. - Define FSRTL_FAT_LEGAL, FSRTL_HPFS_LEGAL, FSRTL_NTFS_LEGAL, FSRTL_WILD_CHARACTER, FSRTL_OLE_LEGAL, FSRTL_NTFS_STREAM_LEGAL, EX_RUNDOWN_ACTIVE, EX_RUNDOWN_COUNT_SHIFT, EX_RUNDOWN_COUNT_INC, FsRtlIsLeadDbcsCharacter and FsRtlIsAnsiCharacterWild. - Remove declaration of SYSTEM_CACHE_INFORMATION and SeCreateAccessState, they don't belong to public headers. Modified: trunk/reactos/w32api/include/ddk/ntapi.h Modified: trunk/reactos/w32api/include/ddk/ntifs.h Modified: trunk/reactos/w32api/include/ddk/winddk.h Modified: trunk/reactos/w32api/include/ddk/winnt4.h _____ Modified: trunk/reactos/w32api/include/ddk/ntapi.h --- trunk/reactos/w32api/include/ddk/ntapi.h 2005-06-18 12:12:41 UTC (rev 16027) +++ trunk/reactos/w32api/include/ddk/ntapi.h 2005-06-18 12:39:24 UTC (rev 16028) @@ -46,8 +46,9 @@ /* FIXME: Unknown definitions */ typedef PVOID POBJECT_TYPE_LIST; typedef PVOID PEXECUTION_STATE; -typedef PVOID PLANGID; +typedef unsigned short LANGID, *PLANGID; + #ifndef NtCurrentProcess #define NtCurrentProcess() ( (HANDLE) 0xFFFFFFFF ) #endif /* NtCurrentProcess */ @@ -261,7 +262,7 @@ ULONG QuotaNonPagedPoolUsage; ULONG PagefileUsage; ULONG PeakPagefileUsage; -} VM_COUNTERS; +} VM_COUNTERS, *PVM_COUNTERS; typedef enum _THREAD_STATE { Initialized, @@ -463,6 +464,15 @@ ULONG GenericInvalidOpcode; } SYSTEM_INSTRUCTION_EMULATION_INFORMATION, *PSYSTEM_INSTRUCTION_EMULATION_INFORMATION; +typedef struct _SYSTEM_CACHE_INFORMATION { + ULONG CurrentSize; + ULONG PeakSize; + ULONG PageFaultCount; + ULONG MinimumWorkingSet; + ULONG MaximumWorkingSet; + ULONG Unused[4]; +} SYSTEM_CACHE_INFORMATION, *PSYSTEM_CACHE_INFORMATION; + typedef struct _SYSTEM_POOL_TAG_INFORMATION { CHAR Tag[4]; ULONG PagedPoolAllocs; @@ -473,6 +483,15 @@ ULONG NonPagedPoolUsage; } SYSTEM_POOL_TAG_INFORMATION, *PSYSTEM_POOL_TAG_INFORMATION; +typedef struct _SYSTEM_INTERRUPT_INFORMATION { + ULONG ContextSwitches; + ULONG DpcCount; + ULONG DpcRate; + ULONG TimeIncrement; + ULONG DpcBypassCount; + ULONG ApcBypassCount; +} SYSTEM_INTERRUPT_INFORMATION, *PSYSTEM_INTERRUPT_INFORMATION; + typedef struct _SYSTEM_PROCESSOR_STATISTICS { ULONG ContextSwitches; ULONG DpcCount; @@ -1991,7 +2010,6 @@ CLIENT_ID ClientId; ULONG MessageId; ULONG SectionSize; - UCHAR Data[ANYSIZE_ARRAY]; } LPC_MESSAGE, *PLPC_MESSAGE; #define LPC_MESSAGE_BASE_SIZE 24 @@ -2332,10 +2350,6 @@ IN HANDLE KeyHandle, IN POBJECT_ATTRIBUTES OldFileObjectAttributes); -typedef enum _KEY_SET_INFORMATION_CLASS { - KeyLastWriteTimeInformation -} KEY_SET_INFORMATION_CLASS; - NTOSAPI NTSTATUS NTAPI @@ -2802,7 +2816,7 @@ NTSTATUS NTAPI NtAllocateUuids( - OUT PLARGE_INTEGER UuidLastTimeAllocated, + OUT PULARGE_INTEGER UuidLastTimeAllocated, OUT PULONG UuidDeltaTime, OUT PULONG UuidSequenceNumber, OUT PUCHAR UuidSeed); @@ -2810,6 +2824,12 @@ NTOSAPI NTSTATUS NTAPI +NtSetUuidSeed( + IN PUCHAR UuidSeed); + +NTOSAPI +NTSTATUS +NTAPI ZwSetUuidSeed( IN PUCHAR UuidSeed); @@ -2893,7 +2913,7 @@ typedef enum _ATOM_INFORMATION_CLASS { AtomBasicInformation, - AtomListInformation + AtomTableInformation } ATOM_INFORMATION_CLASS; NTOSAPI @@ -2907,8 +2927,8 @@ OUT PULONG ReturnLength OPTIONAL); typedef struct _ATOM_BASIC_INFORMATION { - USHORT ReferenceCount; - USHORT Pinned; + USHORT UsageCount; + USHORT Flags; USHORT NameLength; WCHAR Name[1]; } ATOM_BASIC_INFORMATION, *PATOM_BASIC_INFORMATION; _____ Modified: trunk/reactos/w32api/include/ddk/ntifs.h --- trunk/reactos/w32api/include/ddk/ntifs.h 2005-06-18 12:12:41 UTC (rev 16027) +++ trunk/reactos/w32api/include/ddk/ntifs.h 2005-06-18 12:39:24 UTC (rev 16028) @@ -44,16 +44,28 @@ #endif #ifndef NTKERNELAPI -#define NTKERNELAPI STDCALL +#define NTKERNELAPI DECLSPEC_IMPORT #endif typedef struct _SE_EXPORTS *PSE_EXPORTS; -extern PUCHAR *FsRtlLegalAnsiCharacterArray; +#ifdef _NTOSKRNL_ +extern PUCHAR FsRtlLegalAnsiCharacterArray; +#else +extern DECLSPEC_IMPORT PUCHAR FsRtlLegalAnsiCharacterArray; +#endif extern PSE_EXPORTS SeExports; extern PACL SePublicDefaultDacl; extern PACL SeSystemDefaultDacl; +extern KSPIN_LOCK IoStatisticsLock; +extern ULONG IoReadOperationCount; +extern ULONG IoWriteOperationCount; +extern ULONG IoOtherOperationCount; +extern LARGE_INTEGER IoReadTransferCount; +extern LARGE_INTEGER IoWriteTransferCount; +extern LARGE_INTEGER IoOtherTransferCount; + #define ANSI_DOS_STAR ('<') #define ANSI_DOS_QM ('>') #define ANSI_DOS_DOT ('"') @@ -241,6 +253,13 @@ #define FSRTL_WILD_CHARACTER 0x08 +#define FSRTL_FAT_LEGAL 0x01 +#define FSRTL_HPFS_LEGAL 0x02 +#define FSRTL_NTFS_LEGAL 0x04 +#define FSRTL_WILD_CHARACTER 0x08 +#define FSRTL_OLE_LEGAL 0x10 +#define FSRTL_NTFS_STREAM_LEGAL 0x14 + #ifdef _X86_ #define HARDWARE_PTE HARDWARE_PTE_X86 #define PHARDWARE_PTE PHARDWARE_PTE_X86 @@ -502,7 +521,6 @@ #define IOCTL_REDIR_QUERY_PATH CTL_CODE(FILE_DEVICE_NETWORK_FILE_SYSTEM, 99, METHOD_NEITHER, FILE_ANY_ACCESS) -typedef PVOID PEJOB; typedef PVOID OPLOCK, *POPLOCK; typedef struct _CACHE_MANAGER_CALLBACKS *PCACHE_MANAGER_CALLBACKS; @@ -718,6 +736,10 @@ } DUMMYUNIONNAME; } EX_PUSH_LOCK, *PEX_PUSH_LOCK; +#define EX_RUNDOWN_ACTIVE 0x1 +#define EX_RUNDOWN_COUNT_SHIFT 0x1 +#define EX_RUNDOWN_COUNT_INC (1 << EX_RUNDOWN_COUNT_SHIFT) + typedef struct _EX_RUNDOWN_REF { _ANONYMOUS_UNION union { ULONG Count; @@ -1197,6 +1219,33 @@ LARGE_INTEGER ValidDataLength; } FSRTL_COMMON_FCB_HEADER, *PFSRTL_COMMON_FCB_HEADER; +#if (VER_PRODUCTBUILD >= 2600) + +typedef struct _FSRTL_ADVANCED_FCB_HEADER { + CSHORT NodeTypeCode; + CSHORT NodeByteSize; + UCHAR Flags; + UCHAR IsFastIoPossible; + UCHAR Flags2; + UCHAR Reserved; + PERESOURCE Resource; + PERESOURCE PagingIoResource; + LARGE_INTEGER AllocationSize; + LARGE_INTEGER FileSize; + LARGE_INTEGER ValidDataLength; + PFAST_MUTEX FastMutex; + LIST_ENTRY FilterContexts; +} FSRTL_ADVANCED_FCB_HEADER, *PFSRTL_ADVANCED_FCB_HEADER; + +typedef struct _FSRTL_PER_STREAM_CONTEXT { + LIST_ENTRY Links; + PVOID OwnerId; + PVOID InstanceId; + PFREE_FUNCTION FreeCallback; +} FSRTL_PER_STREAM_CONTEXT, *PFSRTL_PER_STREAM_CONTEXT; + +#endif /* (VER_PRODUCTBUILD >= 2600) */ + typedef struct _GENERATE_NAME_CONTEXT { USHORT Checksum; BOOLEAN CheckSumInserted; @@ -1549,15 +1598,6 @@ LARGE_INTEGER StartingVcn; } STARTING_VCN_INPUT_BUFFER, *PSTARTING_VCN_INPUT_BUFFER; -typedef struct _SYSTEM_CACHE_INFORMATION { - ULONG CurrentSize; - ULONG PeakSize; - ULONG PageFaultCount; - ULONG MinimumWorkingSet; - ULONG MaximumWorkingSet; - ULONG Unused[4]; -} SYSTEM_CACHE_INFORMATION, *PSYSTEM_CACHE_INFORMATION; - typedef struct _SECURITY_CLIENT_CONTEXT { SECURITY_QUALITY_OF_SERVICE SecurityQos; PACCESS_TOKEN ClientToken; @@ -1598,6 +1638,90 @@ LIST_ENTRY Secured; } VAD_HEADER, *PVAD_HEADER; +#if (VER_PRODUCTBUILD >= 2600) + +typedef BOOLEAN +(NTAPI *PFILTER_REPORT_CHANGE) ( + IN PVOID NotifyContext, + IN PVOID FilterContext +); + +typedef enum _FS_FILTER_SECTION_SYNC_TYPE { + SyncTypeOther = 0, + SyncTypeCreateSection +} FS_FILTER_SECTION_SYNC_TYPE, *PFS_FILTER_SECTION_SYNC_TYPE; + +typedef union _FS_FILTER_PARAMETERS { + struct { + PLARGE_INTEGER EndingOffset; + } AcquireForModifiedPageWriter; + + struct { + PERESOURCE ResourceToRelease; + } ReleaseForModifiedPageWriter; + + struct { + FS_FILTER_SECTION_SYNC_TYPE SyncType; + ULONG PageProtection; + } AcquireForSectionSynchronization; + + struct { + PVOID Argument1; + PVOID Argument2; + PVOID Argument3; + PVOID Argument4; + PVOID Argument5; + } Others; +} FS_FILTER_PARAMETERS, *PFS_FILTER_PARAMETERS; + +typedef struct _FS_FILTER_CALLBACK_DATA { + ULONG SizeOfFsFilterCallbackData; + UCHAR Operation; + UCHAR Reserved; + struct _DEVICE_OBJECT *DeviceObject; + struct _FILE_OBJECT *FileObject; + FS_FILTER_PARAMETERS Parameters; +} FS_FILTER_CALLBACK_DATA, *PFS_FILTER_CALLBACK_DATA; + +typedef NTSTATUS +(NTAPI *PFS_FILTER_CALLBACK) ( + IN PFS_FILTER_CALLBACK_DATA Data, + OUT PVOID *CompletionContext +); + +typedef VOID +(NTAPI *PFS_FILTER_COMPLETION_CALLBACK) ( + IN PFS_FILTER_CALLBACK_DATA Data, + IN NTSTATUS OperationStatus, + IN PVOID CompletionContext +); + +typedef struct _FS_FILTER_CALLBACKS { + ULONG SizeOfFsFilterCallbacks; + ULONG Reserved; + PFS_FILTER_CALLBACK PreAcquireForSectionSynchronization; + PFS_FILTER_COMPLETION_CALLBACK PostAcquireForSectionSynchronization; + PFS_FILTER_CALLBACK PreReleaseForSectionSynchronization; + PFS_FILTER_COMPLETION_CALLBACK PostReleaseForSectionSynchronization; + PFS_FILTER_CALLBACK PreAcquireForCcFlush; + PFS_FILTER_COMPLETION_CALLBACK PostAcquireForCcFlush; + PFS_FILTER_CALLBACK PreReleaseForCcFlush; + PFS_FILTER_COMPLETION_CALLBACK PostReleaseForCcFlush; + PFS_FILTER_CALLBACK PreAcquireForModifiedPageWriter; + PFS_FILTER_COMPLETION_CALLBACK PostAcquireForModifiedPageWriter; + PFS_FILTER_CALLBACK PreReleaseForModifiedPageWriter; + PFS_FILTER_COMPLETION_CALLBACK PostReleaseForModifiedPageWriter; +} FS_FILTER_CALLBACKS, *PFS_FILTER_CALLBACKS; + +typedef struct _READ_LIST { + PFILE_OBJECT FileObject; + ULONG NumberOfEntries; + LOGICAL IsImage; + FILE_SEGMENT_ELEMENT List[ANYSIZE_ARRAY]; +} READ_LIST, *PREAD_LIST; + +#endif + NTKERNELAPI BOOLEAN NTAPI @@ -1734,6 +1858,7 @@ NTKERNELAPI LARGE_INTEGER +NTAPI CcGetLsnForFileObject ( IN PFILE_OBJECT FileObject, OUT PLARGE_INTEGER OldestLsn OPTIONAL @@ -2051,17 +2176,79 @@ VOID NTAPI ExDisableResourceBoostLite ( - IN PERESOURCE Resource + IN PERESOURCE Resource ); NTKERNELAPI ULONG NTAPI ExQueryPoolBlockSize ( - IN PVOID PoolBlock, - OUT PBOOLEAN QuotaCharged + IN PVOID PoolBlock, + OUT PBOOLEAN QuotaCharged ); +#if (VER_PRODUCTBUILD >= 2600) + +NTKERNELAPI +VOID +FASTCALL +ExInitializeRundownProtection ( + IN PEX_RUNDOWN_REF RunRef +); + +NTKERNELAPI +VOID +FASTCALL +ExReInitializeRundownProtection ( + IN PEX_RUNDOWN_REF RunRef +); + +NTKERNELAPI +BOOLEAN +FASTCALL +ExAcquireRundownProtection ( + IN PEX_RUNDOWN_REF RunRef +); + +NTKERNELAPI +BOOLEAN +FASTCALL +ExAcquireRundownProtectionEx ( + IN PEX_RUNDOWN_REF RunRef, + IN ULONG Count +); + +NTKERNELAPI +VOID +FASTCALL +ExReleaseRundownProtection ( + IN PEX_RUNDOWN_REF RunRef +); + +NTKERNELAPI +VOID +FASTCALL +ExReleaseRundownProtectionEx ( + IN PEX_RUNDOWN_REF RunRef, + IN ULONG Count +); + +NTKERNELAPI +VOID +FASTCALL +ExRundownCompleted ( + IN PEX_RUNDOWN_REF RunRef +); + +NTKERNELAPI +VOID +FASTCALL +ExWaitForRundownProtectionRelease ( + IN PEX_RUNDOWN_REF RunRef +); + +#endif /* (VER_PRODUCTBUILD >= 2600) */ + #define FlagOn(x, f) ((x) & (f)) NTKERNELAPI @@ -2442,15 +2629,38 @@ IN NTSTATUS Ntstatus ); +#define FsRtlIsLeadDbcsCharacter(DBCS_CHAR) ( \ + (BOOLEAN)((UCHAR)(DBCS_CHAR) < 0x80 ? FALSE : \ + (NLS_MB_CODE_PAGE_TAG && \ + (NLS_OEM_LEAD_BYTE_INFO[(UCHAR)(DBCS_CHAR)] != 0))) \ +) + +#define FsRtlIsAnsiCharacterWild(C) ( \ + FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], FSRTL_WILD_CHARACTER ) \ +) + #define FsRtlIsUnicodeCharacterWild(C) ( \ (((C) >= 0x40) ? \ FALSE : \ - FlagOn((*FsRtlLegalAnsiCharacterArray)[(C)], FSRTL_WILD_CHARACTER )) \ + FlagOn(FsRtlLegalAnsiCharacterArray[(C)], FSRTL_WILD_CHARACTER )) \ ) NTKERNELAPI BOOLEAN NTAPI +FsRtlMdlReadDev ( + IN PFILE_OBJECT FileObject, + IN PLARGE_INTEGER FileOffset, + IN ULONG Length, + IN ULONG LockKey, + OUT PMDL *MdlChain, + OUT PIO_STATUS_BLOCK IoStatus, + IN PDEVICE_OBJECT DeviceObject +); + +NTKERNELAPI +BOOLEAN +NTAPI FsRtlMdlReadComplete ( IN PFILE_OBJECT FileObject, IN PMDL MdlChain @@ -2468,6 +2678,19 @@ NTKERNELAPI BOOLEAN NTAPI +FsRtlPrepareMdlWriteDev ( + IN PFILE_OBJECT FileObject, + IN PLARGE_INTEGER FileOffset, + IN ULONG Length, + IN ULONG LockKey, + OUT PMDL *MdlChain, + OUT PIO_STATUS_BLOCK IoStatus, + IN PDEVICE_OBJECT DeviceObject +); + +NTKERNELAPI +BOOLEAN +NTAPI FsRtlMdlWriteComplete ( IN PFILE_OBJECT FileObject, IN PLARGE_INTEGER FileOffset, @@ -2555,7 +2778,7 @@ VOID NTAPI FsRtlNotifyInitializeSync ( - IN PNOTIFY_SYNC NotifySync + IN PNOTIFY_SYNC *NotifySync ); NTKERNELAPI @@ -2573,7 +2796,7 @@ VOID NTAPI FsRtlNotifyUninitializeSync ( - IN PNOTIFY_SYNC NotifySync + IN PNOTIFY_SYNC *NotifySync ); #if (VER_PRODUCTBUILD >= 2195) @@ -2670,9 +2893,33 @@ IN BOOLEAN MailslotsSupported ); +typedef VOID +(NTAPI *PFSRTL_STACK_OVERFLOW_ROUTINE) ( + IN PVOID Context, + IN PKEVENT Event +); + NTKERNELAPI VOID NTAPI +FsRtlPostStackOverflow ( + IN PVOID Context, + IN PKEVENT Event, + IN PFSRTL_STACK_OVERFLOW_ROUTINE StackOverflowRoutine +); + +NTKERNELAPI +VOID +NTAPI +FsRtlPostPagingFileStackOverflow ( + IN PVOID Context, + IN PKEVENT Event, + IN PFSRTL_STACK_OVERFLOW_ROUTINE StackOverflowRoutine +); + +NTKERNELAPI +VOID +NTAPI FsRtlUninitializeFileLock ( IN PFILE_LOCK FileLock ); @@ -2713,6 +2960,15 @@ } NTKERNELAPI +NTSTATUS +NTAPI +IoAttachDeviceToDeviceStackSafe( + IN PDEVICE_OBJECT SourceDevice, + IN PDEVICE_OBJECT TargetDevice, + OUT PDEVICE_OBJECT *AttachedToDeviceObject +); + +NTKERNELAPI VOID NTAPI IoAcquireVpbSpinLock ( @@ -2744,8 +3000,8 @@ IN UCHAR MajorFunction, IN UCHAR MinorFunction, IN ULONG IoControlCode, - IN PFILE_INFORMATION_CLASS FileInformationClass OPTIONAL, - IN PFS_INFORMATION_CLASS FsInformationClass OPTIONAL + IN PVOID Argument1 OPTIONAL, + IN PVOID Argument2 OPTIONAL ); #if (VER_PRODUCTBUILD >= 2195) @@ -2901,6 +3157,13 @@ NTKERNELAPI VOID NTAPI +IoQueueThreadIrp( + IN PIRP Irp +); + +NTKERNELAPI +VOID +NTAPI IoRegisterFileSystem ( IN OUT PDEVICE_OBJECT DeviceObject ); @@ -2982,7 +3245,7 @@ #if (VER_PRODUCTBUILD >= 1381) NTKERNELAPI -NTSTATUS +VOID NTAPI IoUnregisterFsRegistrationChange ( IN PDRIVER_OBJECT DriverObject, @@ -3070,6 +3333,31 @@ IN PRKQUEUE Queue ); +NTKERNELAPI +VOID +NTAPI +KeInitializeMutant ( + IN PRKMUTANT Mutant, + IN BOOLEAN InitialOwner +); + +NTKERNELAPI +LONG +NTAPI +KeReadStateMutant ( + IN PRKMUTANT Mutant +); + +NTKERNELAPI +LONG +NTAPI +KeReleaseMutant ( + IN PRKMUTANT Mutant, + IN KPRIORITY Increment, + IN BOOLEAN Abandoned, + IN BOOLEAN Wait +); + #if (VER_PRODUCTBUILD >= 2195) NTKERNELAPI @@ -3261,7 +3549,7 @@ #define PsDereferencePrimaryToken(T) (ObDereferenceObject((T))) NTKERNELAPI -ULONGLONG +LARGE_INTEGER NTAPI PsGetProcessExitTime ( VOID @@ -3270,6 +3558,13 @@ NTKERNELAPI BOOLEAN NTAPI +PsIsSystemThread( + IN PETHREAD Thread +); + +NTKERNELAPI +BOOLEAN +NTAPI PsIsThreadTerminating ( IN PETHREAD Thread ); @@ -3682,16 +3977,6 @@ NTKERNELAPI NTSTATUS NTAPI -SeCreateAccessState ( - OUT PACCESS_STATE AccessState, - IN PVOID AuxData, - IN ACCESS_MASK AccessMask, - IN PGENERIC_MAPPING Mapping -); - -NTKERNELAPI -NTSTATUS -NTAPI SeCreateClientSecurity ( IN PETHREAD Thread, IN PSECURITY_QUALITY_OF_SERVICE QualityOfService, @@ -3946,6 +4231,7 @@ NTKERNELAPI NTSTATUS +NTAPI SeUnregisterLogonSessionTerminatedRoutine ( IN PSE_LOGON_SESSION_TERMINATED_ROUTINE CallbackRoutine ); _____ Modified: trunk/reactos/w32api/include/ddk/winddk.h --- trunk/reactos/w32api/include/ddk/winddk.h 2005-06-18 12:12:41 UTC (rev 16027) +++ trunk/reactos/w32api/include/ddk/winddk.h 2005-06-18 12:39:24 UTC (rev 16028) @@ -52,6 +52,16 @@ #define DECLARE_INTERNAL_OBJECT2(x,y) struct _##x; typedef struct _##x *P##y; #endif +#if defined(_NTHAL_) +#ifndef NTHALAPI +#define NTHALAPI DECL_EXPORT +#endif +#else +#ifndef NTHALAPI +#define NTHALAPI DECL_IMPORT +#endif +#endif + /* Pseudo modifiers for parameters */ #define IN #define OUT @@ -170,6 +180,7 @@ typedef struct _HAL_PRIVATE_DISPATCH_TABLE *PHAL_PRIVATE_DISPATCH_TABLE; typedef struct _DEVICE_HANDLER_OBJECT *PDEVICE_HANDLER_OBJECT; typedef struct _BUS_HANDLER *PBUS_HANDLER; +typedef struct _ADAPTER_OBJECT *PADAPTER_OBJECT; typedef struct _DRIVE_LAYOUT_INFORMATION *PDRIVE_LAYOUT_INFORMATION; typedef struct _DRIVE_LAYOUT_INFORMATION_EX *PDRIVE_LAYOUT_INFORMATION_EX; typedef struct _NAMED_PIPE_CREATE_PARAMETERS *PNAMED_PIPE_CREATE_PARAMETERS; @@ -315,6 +326,14 @@ #define DIRECTORY_CREATE_SUBDIRECTORY (0x0008) #define DIRECTORY_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | 0xF) +#define EVENT_QUERY_STATE (0x0001) +#define EVENT_MODIFY_STATE (0x0002) +#define EVENT_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x3) + +#define SEMAPHORE_QUERY_STATE (0x0001) +#define SEMAPHORE_MODIFY_STATE (0x0002) +#define SEMAPHORE_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x3) + /* Exported object types */ extern NTOSAPI POBJECT_TYPE ExDesktopObjectType; extern NTOSAPI POBJECT_TYPE ExEventObjectType; @@ -331,7 +350,6 @@ extern NTOSAPI POBJECT_TYPE SeTokenObjectType; extern NTOSAPI CCHAR KeNumberProcessors; -extern NTOSAPI PHAL_PRIVATE_DISPATCH_TABLE HalPrivateDispatchTable; /* @@ -897,7 +915,7 @@ typedef struct _WAIT_CONTEXT_BLOCK { KDEVICE_QUEUE_ENTRY WaitQueueEntry; - struct _DRIVER_CONTROL *DeviceRoutine; + PDRIVER_CONTROL DeviceRoutine; PVOID DeviceContext; ULONG NumberOfMapRegisters; PVOID DeviceObject; @@ -1092,6 +1110,11 @@ IRP_RETRY_IO_COMPLETION = 0x4000 }; +#define IRP_QUOTA_CHARGED 0x01 +#define IRP_ALLOCATED_MUST_SUCCEED 0x02 +#define IRP_ALLOCATED_FIXED_SIZE 0x04 +#define IRP_LOOKASIDE_ALLOCATION 0x08 + typedef struct _BOOTDISK_INFORMATION { LONGLONG BootPartitionOffset; LONGLONG SystemPartitionOffset; @@ -2324,9 +2347,28 @@ pHalMirrorVerify HalMirrorVerify; } HAL_DISPATCH, *PHAL_DISPATCH; -extern HAL_DISPATCH HalDispatchTable; -#define HALDISPATCH HalDispatchTable +#if defined(_NTDRIVER_) || defined(_NTDDK_) || defined(_NTIFS_) || defined(_NTHAL_) +extern DECL_IMPORT PHAL_DISPATCH HalDispatchTable; +#define HALDISPATCH ((PHAL_DISPATCH)&HalDispatchTable) +#else +extern DECL_EXPORT HAL_DISPATCH HalDispatchTable; +#define HALDISPATCH (&HalDispatchTable) +#endif +#define HAL_DISPATCH_VERSION 3 +#define HalDispatchTableVersion HALDISPATCH->Version +#define HalQuerySystemInformation HALDISPATCH->HalQuerySystemInformation +#define HalSetSystemInformation HALDISPATCH->HalSetSystemInformation +#define HalQueryBusSlots HALDISPATCH->HalQueryBusSlots +#define HalDeviceControl HALDISPATCH->HalDeviceControl +#define HalIoAssignDriveLetters HALDISPATCH->HalIoAssignDriveLetters +#define HalIoReadPartitionTable HALDISPATCH->HalIoReadPartitionTable +#define HalIoSetPartitionInformation HALDISPATCH->HalIoSetPartitionInformation +#define HalIoWritePartitionTable HALDISPATCH->HalIoWritePartitionTable +#define HalReferenceHandlerForBus HALDISPATCH->HalReferenceHandlerForBus +#define HalReferenceBusHandler HALDISPATCH->HalReferenceBusHandler +#define HalDereferenceBusHandler HALDISPATCH->HalDereferenceBusHandler + typedef enum _FILE_INFORMATION_CLASS { FileDirectoryInformation = 1, FileFullDirectoryInformation, @@ -2492,10 +2534,9 @@ KSPIN_LOCK SpinLock; } ERESOURCE, *PERESOURCE; -/* NOTE: PVOID for methods to avoid 'assignment from incompatible pointer type' warning */ typedef struct _DRIVER_EXTENSION { struct _DRIVER_OBJECT *DriverObject; - PVOID AddDevice; + PDRIVER_ADD_DEVICE AddDevice; ULONG Count; UNICODE_STRING ServiceKeyName; } DRIVER_EXTENSION, *PDRIVER_EXTENSION; @@ -2894,6 +2935,20 @@ ULONG FullCreateOptions; } IO_SECURITY_CONTEXT, *PIO_SECURITY_CONTEXT; +#define IO_TYPE_ADAPTER 1 +#define IO_TYPE_CONTROLLER 2 +#define IO_TYPE_DEVICE 3 +#define IO_TYPE_DRIVER 4 +#define IO_TYPE_FILE 5 +#define IO_TYPE_IRP 6 +#define IO_TYPE_MASTER_ADAPTER 7 +#define IO_TYPE_OPEN_PACKET 8 +#define IO_TYPE_TIMER 9 +#define IO_TYPE_VPB 10 +#define IO_TYPE_ERROR_LOG 11 +#define IO_TYPE_ERROR_MESSAGE 12 +#define IO_TYPE_DEVICE_OBJECT_EXTENSION 13 + #define IO_TYPE_CSQ_IRP_CONTEXT 1 #define IO_TYPE_CSQ 2 @@ -3241,6 +3296,20 @@ KeyValuePartialInformationAlign64 } KEY_VALUE_INFORMATION_CLASS; +typedef struct _KEY_WRITE_TIME_INFORMATION { + LARGE_INTEGER LastWriteTime; +} KEY_WRITE_TIME_INFORMATION, *PKEY_WRITE_TIME_INFORMATION; + +typedef struct _KEY_USER_FLAGS_INFORMATION { + ULONG UserFlags; +} KEY_USER_FLAGS_INFORMATION, *PKEY_USER_FLAGS_INFORMATION; + +typedef enum _KEY_SET_INFORMATION_CLASS { + KeyWriteTimeInformation, + KeyUserFlagsInformation, + MaxKeySetInfoClass +} KEY_SET_INFORMATION_CLASS; + /* KEY_VALUE_Xxx.Type */ #define REG_NONE 0 @@ -3642,44 +3711,41 @@ (DDKAPI *PFREE_FUNCTION)( IN PVOID Buffer); -#define GENERAL_LOOKASIDE_S \ - SLIST_HEADER ListHead; \ - USHORT Depth; \ - USHORT MaximumDepth; \ - ULONG TotalAllocates; \ - _ANONYMOUS_UNION union { \ - ULONG AllocateMisses; \ - ULONG AllocateHits; \ - } DUMMYUNIONNAME; \ - ULONG TotalFrees; \ - _ANONYMOUS_UNION union { \ - ULONG FreeMisses; \ - ULONG FreeHits; \ - } DUMMYUNIONNAME2; \ - POOL_TYPE Type; \ - ULONG Tag; \ - ULONG Size; \ - PALLOCATE_FUNCTION Allocate; \ - PFREE_FUNCTION Free; \ - LIST_ENTRY ListEntry; \ - ULONG LastTotalAllocates; \ - _ANONYMOUS_UNION union { \ - ULONG LastAllocateMisses; \ - ULONG LastAllocateHits; \ - } DUMMYUNIONNAME3; \ +typedef struct _GENERAL_LOOKASIDE { + SLIST_HEADER ListHead; + USHORT Depth; + USHORT MaximumDepth; + ULONG TotalAllocates; + union { + ULONG AllocateMisses; + ULONG AllocateHits; + }; + ULONG TotalFrees; + union { + ULONG FreeMisses; + ULONG FreeHits; + }; + POOL_TYPE Type; + ULONG Tag; + ULONG Size; + PALLOCATE_FUNCTION Allocate; + PFREE_FUNCTION Free; + LIST_ENTRY ListEntry; + ULONG LastTotalAllocates; + union { + ULONG LastAllocateMisses; + ULONG LastAllocateHits; + }; ULONG Future[2]; - -typedef struct _GENERAL_LOOKASIDE { - GENERAL_LOOKASIDE_S } GENERAL_LOOKASIDE, *PGENERAL_LOOKASIDE; typedef struct _NPAGED_LOOKASIDE_LIST { - GENERAL_LOOKASIDE_S + GENERAL_LOOKASIDE L; KSPIN_LOCK Obsoleted; } NPAGED_LOOKASIDE_LIST, *PNPAGED_LOOKASIDE_LIST; typedef struct _PAGED_LOOKASIDE_LIST { - GENERAL_LOOKASIDE_S + GENERAL_LOOKASIDE L; FAST_MUTEX Obsoleted; } PAGED_LOOKASIDE_LIST, *PPAGED_LOOKASIDE_LIST; @@ -3895,6 +3961,9 @@ MaximumType } CONFIGURATION_TYPE, *PCONFIGURATION_TYPE; +#define IO_FORCE_ACCESS_CHECK 0x001 +#define IO_NO_PARAMETER_CHECKING 0x100 + typedef NTSTATUS (DDKAPI *PIO_QUERY_DEVICE_ROUTINE)( IN PVOID Context, @@ -4350,7 +4419,7 @@ DWORD Version; /* 10 */ } DUMMYUNIONNAME; PVOID ArbitraryUserPointer; /* 14 */ - struct _NT_TIB *Self; /* 18 */ + struct _KPCR_TIB *Self; /* 18 */ } KPCR_TIB, *PKPCR_TIB; /* 1C */ #define PCR_MINOR_VERSION 1 @@ -4390,13 +4459,13 @@ #define PAGE_SIZE 0x1000 #define PAGE_SHIFT 12L -extern NTOSAPI PVOID *MmHighestUserAddress; -extern NTOSAPI PVOID *MmSystemRangeStart; -extern NTOSAPI ULONG *MmUserProbeAddress; +extern NTOSAPI PVOID MmHighestUserAddress; +extern NTOSAPI PVOID MmSystemRangeStart; +extern NTOSAPI ULONG_PTR MmUserProbeAddress; -#define MM_HIGHEST_USER_ADDRESS *MmHighestUserAddress -#define MM_SYSTEM_RANGE_START *MmSystemRangeStart -#define MM_USER_PROBE_ADDRESS *MmUserProbeAddress +#define MM_HIGHEST_USER_ADDRESS MmHighestUserAddress +#define MM_SYSTEM_RANGE_START MmSystemRangeStart +#define MM_USER_PROBE_ADDRESS MmUserProbeAddress #define MM_LOWEST_USER_ADDRESS (PVOID)0x10000 #define MM_LOWEST_SYSTEM_ADDRESS (PVOID)0xC0C00000 @@ -4417,7 +4486,7 @@ ResultPositive = RESULT_POSITIVE } INTERLOCKED_RESULT; -NTOSAPI +NTHALAPI KIRQL DDKAPI KeGetCurrentIrql( @@ -4501,8 +4570,23 @@ KefReleaseSpinLockFromDpcLevel( IN PKSPIN_LOCK SpinLock); +NTHALAPI +KIRQL +DDKFASTAPI +KfAcquireSpinLock( + IN PKSPIN_LOCK SpinLock); + +NTHALAPI +VOID +DDKFASTAPI +KfReleaseSpinLock( + IN PKSPIN_LOCK SpinLock, + IN KIRQL NewIrql); + #define KeAcquireSpinLockAtDpcLevel(SpinLock) KefAcquireSpinLockAtDpcLevel(SpinLock) #define KeReleaseSpinLockFromDpcLevel(SpinLock) KefReleaseSpinLockFromDpcLevel(SpinLock) +#define KeAcquireSpinLock(a,b) *(b) = KfAcquireSpinLock(a) +#define KeReleaseSpinLock(a,b) KfReleaseSpinLock(a,b) #define RtlCopyMemoryNonTemporal RtlCopyMemory @@ -5655,7 +5739,11 @@ /** Executive support routines **/ +#if defined(_X86_) +NTHALAPI +#else NTOSAPI +#endif VOID DDKFASTAPI ExAcquireFastMutex( @@ -5699,14 +5787,14 @@ ExAllocateFromNPagedLookasideList( IN PNPAGED_LOOKASIDE_LIST Lookaside) { - PVOID Entry; + PVOID Entry; - Lookaside->TotalAllocates++; - Entry = InterlockedPopEntrySList(&Lookaside->ListHead); - if (Entry == NULL) { - Lookaside->_DDK_DUMMYUNION_MEMBER(AllocateMisses)++; - Entry = (Lookaside->Allocate)(Lookaside->Type, Lookaside->Size, Lookaside->Tag); - } + Lookaside->L.TotalAllocates++; + Entry = InterlockedPopEntrySList(&Lookaside->L.ListHead); + if (Entry == NULL) { + Lookaside->L.AllocateMisses++; + Entry = (Lookaside->L.Allocate)(Lookaside->L.Type, Lookaside->L.Size, Lookaside->L.Tag); + } return Entry; } @@ -5716,12 +5804,11 @@ { PVOID Entry; - Lookaside->TotalAllocates++; [truncated at 1000 lines; 504 more skipped]
19 years, 6 months
1
0
0
0
[navaraf] 16027: Define PAGE_WRITECOMBINE, IMAGE_OPTIONAL_HEADER32, IMAGE_OPTIONAL_HEADER64, IMAGE_NT_HEADERS32 and IMAGE_NT_HEADERS64.
by navaraf@svn.reactos.com
Define PAGE_WRITECOMBINE, IMAGE_OPTIONAL_HEADER32, IMAGE_OPTIONAL_HEADER64, IMAGE_NT_HEADERS32 and IMAGE_NT_HEADERS64. Modified: trunk/reactos/w32api/include/winnt.h _____ Modified: trunk/reactos/w32api/include/winnt.h --- trunk/reactos/w32api/include/winnt.h 2005-06-18 11:42:42 UTC (rev 16026) +++ trunk/reactos/w32api/include/winnt.h 2005-06-18 12:12:41 UTC (rev 16027) @@ -781,6 +781,7 @@ #define PAGE_EXECUTE_WRITECOPY 0x0080 #define PAGE_GUARD 0x0100 #define PAGE_NOCACHE 0x0200 +#define PAGE_WRITECOMBINE 0x0400 #define MEM_COMMIT 0x1000 #define MEM_RESERVE 0x2000 #define MEM_DECOMMIT 0x4000 @@ -843,6 +844,8 @@ #define IMAGE_FILE_MACHINE_R10000 360 #define IMAGE_FILE_MACHINE_ALPHA 388 #define IMAGE_FILE_MACHINE_POWERPC 496 +#define IMAGE_FILE_MACHINE_IA64 512 +#define IMAGE_FILE_MACHINE_AMD64 0x8664 #define IMAGE_DOS_SIGNATURE 0x5A4D #define IMAGE_OS2_SIGNATURE 0x454E #define IMAGE_OS2_SIGNATURE_LE 0x454C @@ -2418,7 +2421,7 @@ DWORD VirtualAddress; DWORD Size; } IMAGE_DATA_DIRECTORY,*PIMAGE_DATA_DIRECTORY; -typedef struct _IMAGE_OPTIONAL_HEADER { +typedef struct _IMAGE_OPTIONAL_HEADER32 { WORD Magic; BYTE MajorLinkerVersion; BYTE MinorLinkerVersion; @@ -2450,7 +2453,39 @@ DWORD LoaderFlags; DWORD NumberOfRvaAndSizes; IMAGE_DATA_DIRECTORY DataDirectory[IMAGE_NUMBEROF_DIRECTORY_ENTRIES]; -} IMAGE_OPTIONAL_HEADER,*PIMAGE_OPTIONAL_HEADER; +} IMAGE_OPTIONAL_HEADER32,*PIMAGE_OPTIONAL_HEADER32; +typedef struct _IMAGE_OPTIONAL_HEADER64 { + WORD Magic; + BYTE MajorLinkerVersion; + BYTE MinorLinkerVersion; + DWORD SizeOfCode; + DWORD SizeOfInitializedData; + DWORD SizeOfUninitializedData; + DWORD AddressOfEntryPoint; + DWORD BaseOfCode; + ULONGLONG ImageBase; + DWORD SectionAlignment; + DWORD FileAlignment; + WORD MajorOperatingSystemVersion; + WORD MinorOperatingSystemVersion; + WORD MajorImageVersion; + WORD MinorImageVersion; + WORD MajorSubsystemVersion; + WORD MinorSubsystemVersion; + DWORD Reserved1; + DWORD SizeOfImage; + DWORD SizeOfHeaders; + DWORD CheckSum; + WORD Subsystem; + WORD DllCharacteristics; + ULONGLONG SizeOfStackReserve; + ULONGLONG SizeOfStackCommit; + ULONGLONG SizeOfHeapReserve; + ULONGLONG SizeOfHeapCommit; + DWORD LoaderFlags; + DWORD NumberOfRvaAndSizes; + IMAGE_DATA_DIRECTORY DataDirectory[IMAGE_NUMBEROF_DIRECTORY_ENTRIES]; +} IMAGE_OPTIONAL_HEADER64,*PIMAGE_OPTIONAL_HEADER64; typedef struct _IMAGE_ROM_OPTIONAL_HEADER { WORD Magic; BYTE MajorLinkerVersion; @@ -2523,11 +2558,27 @@ } IMAGE_OS2_HEADER,*PIMAGE_OS2_HEADER; #pragma pack(pop) #pragma pack(push,4) -typedef struct _IMAGE_NT_HEADERS { +typedef struct _IMAGE_NT_HEADERS32 { DWORD Signature; IMAGE_FILE_HEADER FileHeader; - IMAGE_OPTIONAL_HEADER OptionalHeader; -} IMAGE_NT_HEADERS,*PIMAGE_NT_HEADERS; + IMAGE_OPTIONAL_HEADER32 OptionalHeader; +} IMAGE_NT_HEADERS32,*PIMAGE_NT_HEADERS32; +typedef struct _IMAGE_NT_HEADERS64 { + DWORD Signature; + IMAGE_FILE_HEADER FileHeader; + IMAGE_OPTIONAL_HEADER64 OptionalHeader; +} IMAGE_NT_HEADERS64,*PIMAGE_NT_HEADERS64; +#ifdef _WIN64 +typedef IMAGE_OPTIONAL_HEADER64 IMAGE_OPTIONAL_HEADER; +typedef PIMAGE_OPTIONAL_HEADER64 PIMAGE_OPTIONAL_HEADER; +typedef IMAGE_NT_HEADERS64 IMAGE_NT_HEADERS; +typedef PIMAGE_NT_HEADERS64 PIMAGE_NT_HEADERS; +#else +typedef IMAGE_OPTIONAL_HEADER32 IMAGE_OPTIONAL_HEADER; +typedef PIMAGE_OPTIONAL_HEADER32 PIMAGE_OPTIONAL_HEADER; +typedef IMAGE_NT_HEADERS32 IMAGE_NT_HEADERS; +typedef PIMAGE_NT_HEADERS32 PIMAGE_NT_HEADERS; +#endif typedef struct _IMAGE_ROM_HEADERS { IMAGE_FILE_HEADER FileHeader; IMAGE_ROM_OPTIONAL_HEADER OptionalHeader;
19 years, 6 months
1
0
0
0
[blight] 16026: Fix stupid bug...
by blight@svn.reactos.com
Fix stupid bug... Modified: trunk/reactos/ntoskrnl/kdbg/kdb_cli.c _____ Modified: trunk/reactos/ntoskrnl/kdbg/kdb_cli.c --- trunk/reactos/ntoskrnl/kdbg/kdb_cli.c 2005-06-18 11:30:49 UTC (rev 16025) +++ trunk/reactos/ntoskrnl/kdbg/kdb_cli.c 2005-06-18 11:42:42 UTC (rev 16026) @@ -374,19 +374,6 @@ if (Argv[0][0] == 'r') /* regs */ { - ULONG Esp; - USHORT Ss; - - if (!(Tf->Cs & 1)) - { - Esp = (ULONG)Tf->TempEsp; - Ss = (USHORT)((ULONG)Tf->TempSegSs & 0xFFFF); - } - else - { - Esp = Tf->Esp; - Ss = Tf->Ss; - } KdbpPrint("CS:EIP 0x%04x:0x%08x\n" "SS:ESP 0x%04x:0x%08x\n" " EAX 0x%08x EBX 0x%08x\n" @@ -394,7 +381,7 @@ " ESI 0x%08x EDI 0x%08x\n" " EBP 0x%08x\n", Tf->Cs & 0xFFFF, Tf->Eip, - Ss, Esp, + Tf->Ss, Tf->Esp, Tf->Eax, Tf->Ebx, Tf->Ecx, Tf->Edx, Tf->Esi, Tf->Edi, @@ -580,8 +567,10 @@ } KdbpPrint("Frames:\n"); - while (Frame != 0) + for (;;) { + if (Frame == 0) + break; if (!NT_SUCCESS(KdbpSafeReadMemory(&Address, (PVOID)(Frame + sizeof(ULONG_PTR)), sizeof (ULONG_PTR)))) { KdbpPrint("Couldn't access memory at 0x%x!\n", Frame + sizeof(ULONG_PTR)); @@ -591,6 +580,8 @@ KdbpPrint("<%08x>\n", Address); else KdbpPrint("\n"); + if (Address == 0) + break; if (!NT_SUCCESS(KdbpSafeReadMemory(&Frame, (PVOID)Frame, sizeof (ULONG_PTR)))) { KdbpPrint("Couldn't access memory at 0x%x!\n", Frame); @@ -953,7 +944,10 @@ if (Thread->Tcb.TrapFrame != NULL) { - Esp = (PULONG)Thread->Tcb.TrapFrame->Esp; + if (Thread->Tcb.TrapFrame->PreviousMode == KernelMode) + Esp = (PULONG)Thread->Tcb.TrapFrame->TempEsp; + else + Esp = (PULONG)Thread->Tcb.TrapFrame->Esp; Ebp = (PULONG)Thread->Tcb.TrapFrame->Ebp; Eip = Thread->Tcb.TrapFrame->Eip; }
19 years, 6 months
1
0
0
0
[ekohl] 16025: Implement basic string table functions
by ekohl@svn.reactos.com
Implement basic string table functions Modified: trunk/reactos/include/wine/setupapi.h Modified: trunk/reactos/lib/setupapi/Makefile.in Modified: trunk/reactos/lib/setupapi/setupapi.spec Modified: trunk/reactos/lib/setupapi/setupapi.xml Added: trunk/reactos/lib/setupapi/stringtable.c Modified: trunk/reactos/w32api/include/setupapi.h _____ Modified: trunk/reactos/include/wine/setupapi.h --- trunk/reactos/include/wine/setupapi.h 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/include/wine/setupapi.h 2005-06-18 11:30:49 UTC (rev 16025) @@ -39,6 +39,8 @@ typedef PVOID HDSKSPC; +typedef PVOID HSTRING_TABLE; + /* inf structure. */ typedef struct _INFCONTEXT { @@ -665,7 +667,11 @@ #define SPDRP_MAXIMUM_PROPERTY 0x00000023 -LONG WINAPI AddTagToGroupOrderList(PCWSTR lpGroupName, DWORD dwUnknown2, DWORD dwUnknown3); +/* Flags for StringTableAddString and StringTableLookUpString */ +#define ST_CASE_SENSITIVE_COMPARE 0x00000001 + + +LONG WINAPI AddTagToGroupOrderList(PCWSTR, DWORD, DWORD); VOID WINAPI AssertFail(LPSTR, UINT, LPSTR); DWORD WINAPI CaptureAndConvertAnsiArg(PCSTR lpSrc, PWSTR *lpDst); DWORD WINAPI CaptureStringArg(PCWSTR lpSrc, PWSTR *lpDst); @@ -827,6 +833,15 @@ BOOL WINAPI SetupSetFileQueueFlags( HSPFILEQ, DWORD, DWORD ); void WINAPI SetupTermDefaultQueueCallback( PVOID ); DWORD WINAPI StampFileSecurity(PCWSTR, PSECURITY_DESCRIPTOR); + +DWORD WINAPI StringTableAddString(HSTRING_TABLE, LPWSTR, DWORD); +VOID WINAPI StringTableDestroy(HSTRING_TABLE); +HSTRING_TABLE WINAPI StringTableInitialize(VOID); +DWORD WINAPI StringTableLookUpString(HSTRING_TABLE, LPWSTR, DWORD); +LPWSTR WINAPI StringTableStringFromId(HSTRING_TABLE, DWORD); +BOOL WINAPI StringTableStringFromIdEx(HSTRING_TABLE, DWORD, LPWSTR, LPDWORD); +VOID WINAPI StringTableTrim(HSTRING_TABLE); + DWORD WINAPI TakeOwnershipOfFile(PCWSTR); PSTR WINAPI UnicodeToMultiByte(PCWSTR lpUnicodeStr, UINT uCodePage); BOOL WINAPI UnmapAndCloseFile(HANDLE, HANDLE, PVOID); _____ Modified: trunk/reactos/lib/setupapi/Makefile.in --- trunk/reactos/lib/setupapi/Makefile.in 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/lib/setupapi/Makefile.in 2005-06-18 11:30:49 UTC (rev 16025) @@ -20,6 +20,7 @@ parser.c \ queue.c \ setupcab.c \ + stringtable.c \ stubs.c \ rpc.c _____ Modified: trunk/reactos/lib/setupapi/setupapi.spec --- trunk/reactos/lib/setupapi/setupapi.spec 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/lib/setupapi/setupapi.spec 2005-06-18 11:30:49 UTC (rev 16025) @@ -513,20 +513,20 @@ @ stdcall SetupTerminateFileLog(long) @ stub ShouldDeviceBeExcluded @ stdcall StampFileSecurity(wstr ptr) -@ stub StringTableAddString +@ stdcall StringTableAddString(ptr wstr long) @ stub StringTableAddStringEx -@ stub StringTableDestroy +@ stdcall StringTableDestroy(ptr) @ stub StringTableDuplicate @ stub StringTableEnum @ stub StringTableGetExtraData -@ stub StringTableInitialize +@ stdcall StringTableInitialize() @ stub StringTableInitializeEx -@ stub StringTableLookUpString +@ stdcall StringTableLookUpString(ptr wstr long) @ stub StringTableLookUpStringEx @ stub StringTableSetExtraData -@ stub StringTableStringFromId -@ stub StringTableStringFromIdEx -@ stub StringTableTrim +@ stdcall StringTableStringFromId(ptr long) +@ stdcall StringTableStringFromIdEx(ptr long ptr ptr) +@ stdcall StringTableTrim(ptr) @ stdcall TakeOwnershipOfFile(wstr) @ stdcall UnicodeToMultiByte(wstr long) @ stdcall UnmapAndCloseFile(long long ptr) _____ Modified: trunk/reactos/lib/setupapi/setupapi.xml --- trunk/reactos/lib/setupapi/setupapi.xml 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/lib/setupapi/setupapi.xml 2005-06-18 11:30:49 UTC (rev 16025) @@ -29,6 +29,7 @@ <file>parser.c</file> <file>queue.c</file> <file>setupcab.c</file> + <file>stringtable.c</file> <file>stubs.c</file> <file>rpc.c</file> <file>setupapi.rc</file> _____ Added: trunk/reactos/lib/setupapi/stringtable.c --- trunk/reactos/lib/setupapi/stringtable.c 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/lib/setupapi/stringtable.c 2005-06-18 11:30:49 UTC (rev 16025) @@ -0,0 +1,389 @@ +/* + * Setupapi string table functions + * + * Copyright 2005 Eric Kohl + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#include <stdarg.h> + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winuser.h" +#include "winreg.h" +#include "setupapi.h" + +#include "wine/debug.h" + + +#define TABLE_DEFAULT_SIZE 256 + +WINE_DEFAULT_DEBUG_CHANNEL(setupapi); + +typedef struct _STRING_TABLE +{ + LPWSTR *pSlots; /* 0x00 */ + DWORD dwUsedSlots; /* 0x04 */ + DWORD dwMaxSlots; /* 0x08 */ +} STRING_TABLE, *PSTRING_TABLE; + + +/********************************************************************** **** + * StringTableInitialize [SETUPAPI.@] + * + * Creates a new string table and initializes it. + * + * PARAMS + * None + * + * RETURNS + * Success: Handle to the string table + * Failure: NULL + */ +HSTRING_TABLE WINAPI +StringTableInitialize(VOID) +{ + PSTRING_TABLE pStringTable; + + TRACE("\n"); + + pStringTable = MyMalloc(sizeof(STRING_TABLE)); + if (pStringTable == NULL) + { + ERR("Invalid hStringTable!\n"); + return NULL; + } + + memset(pStringTable, 0, sizeof(STRING_TABLE)); + + pStringTable->pSlots = MyMalloc(sizeof(LPWSTR) * TABLE_DEFAULT_SIZE); + if (pStringTable->pSlots == NULL) + { + MyFree(pStringTable->pSlots); + return NULL; + } + + memset(pStringTable->pSlots, 0, sizeof(LPWSTR) * TABLE_DEFAULT_SIZE); + + pStringTable->dwUsedSlots = 0; + pStringTable->dwMaxSlots = TABLE_DEFAULT_SIZE; + + TRACE("Done\n"); + + return (HSTRING_TABLE)pStringTable; +} + + +/********************************************************************** **** + * StringTableDestroy [SETUPAPI.@] + * + * Destroys a string table. + * + * PARAMS + * hStringTable [I] Handle to the string table to be destroyed + * + * RETURNS + * None + */ +VOID WINAPI +StringTableDestroy(HSTRING_TABLE hStringTable) +{ + PSTRING_TABLE pStringTable; + DWORD i; + + TRACE("%p\n", (PVOID)hStringTable); + + pStringTable = (PSTRING_TABLE)hStringTable; + if (pStringTable == NULL) + return; + + if (pStringTable->pSlots != NULL) + { + for (i = 0; i < pStringTable->dwMaxSlots; i++) + { + if (pStringTable->pSlots[i] != NULL) + { + MyFree(pStringTable->pSlots[i]); + pStringTable->pSlots[i] = NULL; + } + } + + MyFree(pStringTable->pSlots); + } + + MyFree(pStringTable); +} + + +/********************************************************************** **** + * StringTableAddString [SETUPAPI.@] + * + * Adds a new string to the string table. + * + * PARAMS + * hStringTable [I] Handle to the string table + * lpString [I] String to be added to the string table + * dwFlags [I] Flags + * 1: case sensitive compare + * + * RETURNS + * Success: String ID + * Failure: -1 + * + * NOTES + * If the given string already exists in the string table it will not + * be added again. The ID of the existing string will be returned in + * this case. + */ +DWORD WINAPI +StringTableAddString(HSTRING_TABLE hStringTable, + LPWSTR lpString, + DWORD dwFlags) +{ + PSTRING_TABLE pStringTable; + DWORD i; + + TRACE("%p %s %lx\n", (PVOID)hStringTable, debugstr_w(lpString), dwFlags); + + pStringTable = (PSTRING_TABLE)hStringTable; + if (pStringTable == NULL) + { + ERR("Invalid hStringTable!\n"); + return (DWORD)-1; + } + + /* Search for existing string in the string table */ + for (i = 0; i < pStringTable->dwMaxSlots; i++) + { + if (pStringTable->pSlots[i] != NULL) + { + if (dwFlags & 1) + { + if (!lstrcmpW(pStringTable->pSlots[i], lpString)) + { + return i; + } + } + else + { + if (!lstrcmpiW(pStringTable->pSlots[i], lpString)) + { + return i; + } + } + } + } + + /* Check for filled slot table */ + if (pStringTable->dwUsedSlots == pStringTable->dwMaxSlots) + { + FIXME("Resize the string table!\n"); + return (DWORD)-1; + } + + /* Search for an empty slot */ + for (i = 0; i < pStringTable->dwMaxSlots; i++) + { + if (pStringTable->pSlots[i] == NULL) + { + pStringTable->pSlots[i] = MyMalloc(lstrlenW(lpString) + sizeof(WCHAR)); + if (pStringTable->pSlots[i] == NULL) + { + TRACE("Couldn't allocate memory for a new string!\n"); + return (DWORD)-1; + } + + lstrcpyW(pStringTable->pSlots[i], lpString); + + pStringTable->dwUsedSlots++; + + return i; + } + } + + TRACE("Couldn't find an empty slot!\n"); + + return (DWORD)-1; +} + + +/********************************************************************** **** + * StringTableLookUpString [SETUPAPI.@] + * + * Searches a string table for a given string. + * + * PARAMS + * hStringTable [I] Handle to the string table + * lpString [I] String to be searched for + * dwFlags [I] Flags + * 1: case sensitive compare + * + * RETURNS + * Success: String ID + * Failure: -1 + */ +DWORD WINAPI +StringTableLookUpString(HSTRING_TABLE hStringTable, + LPWSTR lpString, + DWORD dwFlags) +{ + PSTRING_TABLE pStringTable; + DWORD i; + + TRACE("%p %s %lx\n", (PVOID)hStringTable, debugstr_w(lpString), dwFlags); + + pStringTable = (PSTRING_TABLE)hStringTable; + if (pStringTable == NULL) + { + ERR("Invalid hStringTable!\n"); + return (DWORD)-1; + } + + /* Search for existing string in the string table */ + for (i = 0; i < pStringTable->dwMaxSlots; i++) + { + if (pStringTable->pSlots[i] != NULL) + { + if (dwFlags & 1) + { + if (!lstrcmpW(pStringTable->pSlots[i], lpString)) + { + return i; + } + } + else + { + if (!lstrcmpiW(pStringTable->pSlots[i], lpString)) + { + return i; + } + } + } + } + + return (DWORD)-1; +} + + +/********************************************************************** **** + * StringTableStringFromId [SETUPAPI.@] + * + * Returns a pointer to a string for the given string ID. + * + * PARAMS + * hStringTable [I] Handle to the string table. + * dwId [I] String ID + * + * RETURNS + * Success: Pointer to the string + * Failure: NULL + */ +LPWSTR WINAPI +StringTableStringFromId(HSTRING_TABLE hStringTable, + DWORD dwId) +{ + PSTRING_TABLE pStringTable; + + TRACE("%p %lx\n", (PVOID)hStringTable, dwId); + + pStringTable = (PSTRING_TABLE)hStringTable; + if (pStringTable == NULL) + { + ERR("Invalid hStringTable!\n"); + return NULL; + } + + if (dwId >= pStringTable->dwMaxSlots) + return NULL; + + return pStringTable->pSlots[dwId]; +} + + +/********************************************************************** **** + * StringTableStringFromIdEx [SETUPAPI.@] + * + * Returns a string for the given string ID. + * + * PARAMS + * hStringTable [I] Handle to the string table + * dwId [I] String ID + * lpBuffer [I] Pointer to string buffer + * lpBufferSize [I/O] Pointer to the size of the string buffer + * + * RETURNS + * Success: TRUE + * Failure: FALSE + */ +BOOL WINAPI +StringTableStringFromIdEx(HSTRING_TABLE hStringTable, + DWORD dwId, + LPWSTR lpBuffer, + LPDWORD lpBufferLength) +{ + PSTRING_TABLE pStringTable; + DWORD dwLength; + BOOL bResult = FALSE; + + TRACE("%p %lx %p %p\n", + (PVOID)hStringTable, dwId, lpBuffer, lpBufferLength); + + pStringTable = (PSTRING_TABLE)hStringTable; + if (pStringTable == NULL) + { + ERR("Invalid hStringTable!\n"); + *lpBufferLength = 0; + return FALSE; + } + + if (dwId >= pStringTable->dwMaxSlots || + pStringTable->pSlots[dwId] == NULL) + { + WARN("Invalid string ID!\n"); + *lpBufferLength = 0; + return FALSE; + } + + dwLength = lstrlenW(pStringTable->pSlots[dwId]) + sizeof(WCHAR); + if (dwLength <= *lpBufferLength) + { + lstrcpyW(lpBuffer, pStringTable->pSlots[dwId]); + bResult = TRUE; + } + + *lpBufferLength = dwLength; + + return bResult; +} + + +/********************************************************************** **** + * StringTableTrim [SETUPAPI.@] + * + * ... + * + * PARAMS + * hStringTable [I] Handle to the string table + * + * RETURNS + * None + */ +VOID WINAPI +StringTableTrim(HSTRING_TABLE hStringTable) +{ + FIXME("%p\n", (PVOID)hStringTable); +} _____ Modified: trunk/reactos/w32api/include/setupapi.h --- trunk/reactos/w32api/include/setupapi.h 2005-06-18 08:04:30 UTC (rev 16024) +++ trunk/reactos/w32api/include/setupapi.h 2005-06-18 11:30:49 UTC (rev 16025) @@ -577,6 +577,9 @@ #define SRCLIST_APPEND 0x00000200 #define SRCLIST_NOSTRIPPLATFORM 0x00000400 +/* Flags for StringTableAddString and StringTableLookUpString */ +#define ST_CASE_SENSITIVE_COMPARE 0x00000001 + #ifndef RC_INVOKED typedef PVOID HINF; typedef PVOID HDSKSPC; @@ -585,6 +588,8 @@ typedef PVOID HSPFILELOG; typedef UINT DI_FUNCTION; +typedef PVOID HSTRING_TABLE; + typedef enum { SetupFileLogSourceFilename, SetupFileLogChecksum, @@ -1326,6 +1331,15 @@ WINSETUPAPI VOID WINAPI SetupTermDefaultQueueCallback(PVOID); WINSETUPAPI BOOL WINAPI SetupTerminateFileLog(HSPFILELOG); +WINSETUPAPI DWORD WINAPI StringTableAddString(HSTRING_TABLE, LPWSTR, DWORD); +WINSETUPAPI VOID WINAPI StringTableDestroy(HSTRING_TABLE); +WINSETUPAPI HSTRING_TABLE WINAPI StringTableInitialize(VOID); +WINSETUPAPI DWORD WINAPI StringTableLookUpString(HSTRING_TABLE, LPWSTR, DWORD); +WINSETUPAPI LPWSTR WINAPI StringTableStringFromId(HSTRING_TABLE, DWORD); +WINSETUPAPI BOOL WINAPI StringTableStringFromIdEx(HSTRING_TABLE, DWORD, LPWSTR, LPDWORD); +WINSETUPAPI VOID WINAPI StringTableTrim(HSTRING_TABLE); + + /* for backward compatability */ #define SetupDiCreateInterfaceDeviceW SetupDiCreateDeviceInterfaceW #define SetupDiCreateInterfaceDeviceRegKeyW SetupDiCreateDeviceInterfaceRegKeyW
19 years, 6 months
1
0
0
0
[chorns] 16024: DIB_24BPP_ColorFill performance test
by chorns@svn.reactos.com
DIB_24BPP_ColorFill performance test Added: trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c Modified: trunk/reactos/subsys/win32k/tests/win32k.xml _____ Added: trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c --- trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c 2005-06-18 07:43:49 UTC (rev 16023) +++ trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c 2005-06-18 08:04:30 UTC (rev 16024) @@ -0,0 +1,44 @@ +#include <w32k.h> + +#include "regtests.h" + +static void SetupSurface(SURFOBJ* surface, RECTL* rect) +{ + UINT sizex; + UINT sizey; + UINT size; + UINT depth; + + ZeroMemory(surface, sizeof(SURFOBJ)); + depth = BitsPerFormat(BMF_24BPP); + sizex = rect->right - rect->left; + sizey = rect->bottom - rect->top; + size = sizey * sizex * depth; + surface->pvScan0 = malloc(size); + surface->lDelta = DIB_GetDIBWidthBytes(sizex, depth); +} + +static void CleanupSurface(SURFOBJ* surface) +{ + free(surface->pvScan0); +} + +static void RunTest() +{ + static RECTL rect = { 0, 0, 100, 100 }; + SURFOBJ surface; + UINT color; + UINT i; + + SetupSurface(&surface, &rect); + for (i = 0; i < 1000; i++) + { + BOOLEAN success = DIB_24BPP_ColorFill(&surface, &rect, color); + _AssertTrue(success); + if (!success) + break; + } + CleanupSurface(&surface); +} + +_Dispatcher(Dib_24bpp_colorfill_performanceTest, "DIB_24BPP_ColorFill performance") Property changes on: trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c ___________________________________________________________________ Name: svn:eol-style + native _____ Modified: trunk/reactos/subsys/win32k/tests/win32k.xml --- trunk/reactos/subsys/win32k/tests/win32k.xml 2005-06-18 07:43:49 UTC (rev 16023) +++ trunk/reactos/subsys/win32k/tests/win32k.xml 2005-06-18 08:04:30 UTC (rev 16024) @@ -19,6 +19,7 @@ <linkerflag>-nostartfiles</linkerflag> <linkerflag>-nostdlib</linkerflag> <directory name="tests"> + <file>DIB_24BPP_ColorFill-performance.c</file> </directory> <file>setup.c</file> <xi:include href="stubs.xml" />
19 years, 6 months
1
0
0
0
[mf] 16023: remove superfluous include
by mf@svn.reactos.com
remove superfluous include Modified: trunk/reactos/subsys/system/explorer/explorer.rc _____ Modified: trunk/reactos/subsys/system/explorer/explorer.rc --- trunk/reactos/subsys/system/explorer/explorer.rc 2005-06-18 06:17:10 UTC (rev 16022) +++ trunk/reactos/subsys/system/explorer/explorer.rc 2005-06-18 07:43:49 UTC (rev 16023) @@ -1,12 +1,10 @@ /* $Id$ */ -#include <windows.h> - #include "explorer_intres.rc" -#define REACTOS_STR_FILE_DESCRIPTION "ReactOS Explorer\0" -#define REACTOS_STR_INTERNAL_NAME "explorer\0" -#define REACTOS_STR_ORIGINAL_FILENAME "explorer.exe\0" +#define REACTOS_STR_FILE_DESCRIPTION "ReactOS Explorer\0" +#define REACTOS_STR_INTERNAL_NAME "explorer\0" +#define REACTOS_STR_ORIGINAL_FILENAME "explorer.exe\0" #include <reactos/version.rc> LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US @@ -21,4 +19,3 @@ IDS_VERSION_STR REACTOS_STR_PRODUCT_VERSION IDS_EXPLORER_VERSION_STR "ReactOS %s Explorer" END -
19 years, 6 months
1
0
0
0
[chorns] 16022: Prepare win32k for tests
by chorns@svn.reactos.com
Prepare win32k for tests Modified: trunk/reactos/lib/kernel32/tests/kernel32.xml Deleted: trunk/reactos/lib/kernel32/tests/stubs.tst Modified: trunk/reactos/lib/kernel32/tests/stubs.xml Modified: trunk/reactos/lib/kernel32/tests/tests/CreateFile.c Modified: trunk/reactos/regtests/regtests/regtests.c Modified: trunk/reactos/regtests/regtests/regtests.def Modified: trunk/reactos/regtests/shared/regtests.c Modified: trunk/reactos/regtests/shared/regtests.h Deleted: trunk/reactos/subsys/win32k/tests/stubs.tst Added: trunk/reactos/subsys/win32k/tests/stubs.xml Added: trunk/reactos/subsys/win32k/tests/win32k.xml Modified: trunk/reactos/subsys/win32k/win32k.xml Modified: trunk/reactos/tools/rbuild/rbuild.h Modified: trunk/reactos/tools/rbuild/testsupportcode.cpp _____ Modified: trunk/reactos/lib/kernel32/tests/kernel32.xml --- trunk/reactos/lib/kernel32/tests/kernel32.xml 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/lib/kernel32/tests/kernel32.xml 2005-06-18 06:17:10 UTC (rev 16022) @@ -1,8 +1,10 @@ <module name="kernel32_test" type="test"> <include base="rtshared">.</include> - <define name="__USE_W32API" /> <define name="_DISABLE_TIDENTS" /> <define name="_SEH_NO_NATIVE_NLG" /> + <define name="__USE_W32API" /> + <define name="_WIN32_WINNT">0x0502</define> + <define name="__NO_CTYPE_INLINES" /> <define name="WINVER">0x0500</define> <library>rtshared</library> <library>regtests</library> _____ Deleted: trunk/reactos/lib/kernel32/tests/stubs.tst --- trunk/reactos/lib/kernel32/tests/stubs.tst 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/lib/kernel32/tests/stubs.tst 2005-06-18 06:17:10 UTC (rev 16022) @@ -1,133 +0,0 @@ -ntdll.dll CsrCaptureParameterBuffer@16 -ntdll.dll CsrClientCallServer@16 -ntdll.dll CsrClientConnectToServer@0 -ntdll.dll CsrReleaseParameterBuffer@4 -ntdll.dll DbgUiContinue@8 -ntdll.dll HeapAlloc@12=RtlAllocateHeap -ntdll.dll HeapFree@12=RtlFreeHeap -ntdll.dll LdrAccessResource@16 -ntdll.dll LdrDisableThreadCalloutsForDll@4 -ntdll.dll LdrFindResource_U@16 -ntdll.dll LdrLoadDll@16 -ntdll.dll LdrShutdownProcess@0 -ntdll.dll LdrShutdownThread@0 -ntdll.dll LdrUnloadDll@4 -ntdll.dll NtAllocateVirtualMemory@24 -ntdll.dll NtClose@4 -ntdll.dll NtCreateDirectoryObject@12 -ntdll.dll NtCreateEvent@20 -ntdll.dll NtCreateFile@44 -ntdll.dll NtCreateKey@28 -ntdll.dll NtCreateProcess@32 -ntdll.dll NtCreateSection@28 -ntdll.dll NtDelayExecution@8 -ntdll.dll NtDeviceIoControlFile@40 -ntdll.dll _imp__NtDuplicateObject@28 -ntdll.dll NtFlushBuffersFile@8 -ntdll.dll NtFlushInstructionCache@12 -ntdll.dll NtFlushVirtualMemory@16 -ntdll.dll NtFreeVirtualMemory@16 -ntdll.dll NtFsControlFile@40 -ntdll.dll NtGetContextThread@8 -ntdll.dll NtLockVirtualMemory@16 -ntdll.dll NtOpenDirectoryObject@12 -ntdll.dll NtOpenEvent@12 -ntdll.dll NtOpenFile@24 -ntdll.dll NtOpenKey@12 -ntdll.dll NtOpenProcess@16 -ntdll.dll NtOpenSection@12 -ntdll.dll NtOpenThread@16 -ntdll.dll NtProtectVirtualMemory@20 -ntdll.dll NtPulseEvent@8 -ntdll.dll NtQueryDefaultLocale@8 -ntdll.dll NtQueryDefaultUILanguage@4 -ntdll.dll NtQueryDirectoryFile@44 -ntdll.dll NtQueryInformationFile@20 -ntdll.dll _imp__NtQueryInformationProcess@20 -ntdll.dll NtQueryInformationThread@20 -ntdll.dll NtQueryObject@20 -ntdll.dll NtQuerySystemInformation@16 -ntdll.dll NtQuerySystemTime@4 -ntdll.dll NtQueryValueKey@24 -ntdll.dll NtQueryVirtualMemory@24 -ntdll.dll NtQueryVolumeInformationFile@20 -ntdll.dll NtReadFile@36 -ntdll.dll NtReadVirtualMemory@20 -ntdll.dll NtResetEvent@8 -ntdll.dll NtResumeThread@8 -ntdll.dll NtSetContextThread@8 -ntdll.dll NtSetEvent@8 -ntdll.dll NtSetInformationFile@20 -ntdll.dll NtSetInformationObject@16 -ntdll.dll _imp__NtSetInformationProcess@16 -ntdll.dll NtSetInformationThread@16 -ntdll.dll NtSetSystemInformation@12 -ntdll.dll NtSetSystemTime@8 -ntdll.dll NtSignalAndWaitForSingleObject@16 -ntdll.dll NtSuspendThread@8 -ntdll.dll NtTerminateThread@8 -ntdll.dll NtUnlockVirtualMemory@16 -ntdll.dll NtUnmapViewOfSection@8 -ntdll.dll NtWaitForMultipleObjects@20 -ntdll.dll NtWaitForSingleObject@12 -ntdll.dll NtWriteFile@36 -ntdll.dll NtWriteVirtualMemory@20 -ntdll.dll NtYieldExecution@0 -ntdll.dll RtlAcquirePebLock@0 -ntdll.dll RtlAnsiStringToUnicodeSize@4 -ntdll.dll _imp__RtlBaseProcessStartRoutine -ntdll.dll RtlCompactHeap@8 -ntdll.dll RtlCopyUnicodeString@8 -ntdll.dll RtlCreateHeap@24 -ntdll.dll RtlCreateProcessParameters@40 -ntdll.dll RtlCreateUnicodeString@8 -ntdll.dll RtlCreateUnicodeStringFromAsciiz@8 -ntdll.dll RtlDeleteCriticalSection@4 -ntdll.dll RtlDestroyHeap@4 -ntdll.dll RtlDestroyProcessParameters@4 -ntdll.dll RtlDoesFileExists_U@4 -ntdll.dll RtlDosPathNameToNtPathName_U@16 -ntdll.dll RtlDosSearchPath_U@24 -ntdll.dll RtlEnterCriticalSection@4 -ntdll.dll RtlExpandEnvironmentStrings_U@16 -ntdll.dll RtlFreeHeap@12 -ntdll.dll RtlGetCurrentDirectory_U@8 -ntdll.dll RtlGetFullPathName_U@16 -ntdll.dll RtlGetProcessHeaps@8 -ntdll.dll RtlImageNtHeader@4 -ntdll.dll RtlInitCodePageTable@8 -ntdll.dll RtlInitializeCriticalSection@4 -ntdll.dll RtlInitUnicodeString@8 -ntdll.dll RtlIntegerToChar@16 -ntdll.dll RtlIntegerToUnicodeString@12 -ntdll.dll RtlIsNameLegalDOS8Dot3@12 -ntdll.dll RtlLeaveCriticalSection@4 -ntdll.dll RtlLockHeap@4 -ntdll.dll RtlNtStatusToDosError@4 -ntdll.dll RtlOemStringToUnicodeSize@4 -ntdll.dll RtlOemStringToUnicodeString@12 -ntdll.dll RtlOpenCurrentUser@8 -ntdll.dll RtlQueryEnvironmentVariable_U@12 -ntdll.dll RtlRaiseException@4 -ntdll.dll RtlReAllocateHeap@16 -ntdll.dll RtlReleasePebLock@0 -ntdll.dll RtlRosCreateUserThreadVa -ntdll.dll RtlRosExitUserThread@4 -ntdll.dll RtlSetCurrentDirectory_U@4 -ntdll.dll RtlSetEnvironmentVariable@12 -ntdll.dll RtlSetTimeZoneInformation@4 -ntdll.dll RtlTimeFieldsToTime@8 -ntdll.dll RtlTimeToTimeFields@8 -ntdll.dll RtlUnicodeStringToAnsiSize@4 -ntdll.dll RtlUnicodeStringToAnsiString@12 -ntdll.dll RtlUnicodeStringToInteger@12 -ntdll.dll RtlUnicodeStringToOemString@12 -ntdll.dll RtlUnicodeToOemN@20 -ntdll.dll RtlUnlockHeap@4 -ntdll.dll RtlValidateHeap@12 -ntdll.dll ZwMapViewOfSection@40 -ntdll.dll ZwOpenSection@12 -ntdll.dll ZwQuerySection@20 -ntdll.dll ZwQuerySystemInformation@16 -ntdll.dll ZwReadFile@36 -ntdll.dll ZwTerminateProcess@8 _____ Modified: trunk/reactos/lib/kernel32/tests/stubs.xml --- trunk/reactos/lib/kernel32/tests/stubs.xml 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/lib/kernel32/tests/stubs.xml 2005-06-18 06:17:10 UTC (rev 16022) @@ -23,7 +23,7 @@ <symbol>NtCreateSection@28</symbol> <symbol>NtDelayExecution@8</symbol> <symbol>NtDeviceIoControlFile@40</symbol> - <symbol>_imp__NtDuplicateObject@28</symbol> + <symbol>NtDuplicateObject@28</symbol> <symbol>NtFlushBuffersFile@8</symbol> <symbol>NtFlushInstructionCache@12</symbol> <symbol>NtFlushVirtualMemory@16</symbol> @@ -44,7 +44,7 @@ <symbol>NtQueryDefaultUILanguage@4</symbol> <symbol>NtQueryDirectoryFile@44</symbol> <symbol>NtQueryInformationFile@20</symbol> - <symbol>_imp__NtQueryInformationProcess@20</symbol> + <symbol>NtQueryInformationProcess@20</symbol> <symbol>NtQueryInformationThread@20</symbol> <symbol>NtQueryObject@20</symbol> <symbol>NtQuerySystemInformation@16</symbol> @@ -60,7 +60,7 @@ <symbol>NtSetEvent@8</symbol> <symbol>NtSetInformationFile@20</symbol> <symbol>NtSetInformationObject@16</symbol> - <symbol>_imp__NtSetInformationProcess@16</symbol> + <symbol>NtSetInformationProcess@16</symbol> <symbol>NtSetInformationThread@16</symbol> <symbol>NtSetSystemInformation@12</symbol> <symbol>NtSetSystemTime@8</symbol> @@ -76,7 +76,7 @@ <symbol>NtYieldExecution@0</symbol> <symbol>RtlAcquirePebLock@0</symbol> <symbol>RtlAnsiStringToUnicodeSize@4</symbol> - <symbol>_imp__RtlBaseProcessStartRoutine</symbol> + <symbol>RtlBaseProcessStartRoutine</symbol> <symbol>RtlCompactHeap@8</symbol> <symbol>RtlCopyUnicodeString@8</symbol> <symbol>RtlCreateHeap@24</symbol> _____ Modified: trunk/reactos/lib/kernel32/tests/tests/CreateFile.c --- trunk/reactos/lib/kernel32/tests/tests/CreateFile.c 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/lib/kernel32/tests/tests/CreateFile.c 2005-06-18 06:17:10 UTC (rev 16022) @@ -90,7 +90,7 @@ return STATUS_SUCCESS; } -static HOOK NtCreateFileHooks[] = +static _HOOK NtCreateFileHooks[] = { {"NtCreateFile", MockNtCreateFile}, {NULL, NULL} _____ Modified: trunk/reactos/regtests/regtests/regtests.c --- trunk/reactos/regtests/regtests/regtests.c 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/regtests/regtests/regtests.c 2005-06-18 06:17:10 UTC (rev 16022) @@ -86,3 +86,15 @@ { return SetThreadPriority(hThread, nPriority); } + +HANDLE STDCALL +_GetCurrentProcess() +{ + return GetCurrentProcess(); +} + +HANDLE STDCALL +_GetCurrentThread() +{ + return GetCurrentThread(); +} _____ Modified: trunk/reactos/regtests/regtests/regtests.def --- trunk/reactos/regtests/regtests/regtests.def 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/regtests/regtests/regtests.def 2005-06-18 06:17:10 UTC (rev 16022) @@ -12,3 +12,5 @@ _GetThreadTimes@20 _SetPriorityClass@8 _SetThreadPriority@8 +_GetCurrentProcess@0 +_GetCurrentThread@0 _____ Modified: trunk/reactos/regtests/shared/regtests.c --- trunk/reactos/regtests/shared/regtests.c 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/regtests/shared/regtests.c 2005-06-18 06:17:10 UTC (rev 16022) @@ -22,7 +22,7 @@ typedef struct _PERFORM_TEST_ARGS { TestOutputRoutine OutputRoutine; - PROS_TEST Test; + _PTEST Test; LPSTR TestName; } PERFORM_TEST_ARGS; @@ -53,7 +53,7 @@ { PERFORM_TEST_ARGS *Args = (PERFORM_TEST_ARGS *)_arg; TestOutputRoutine OutputRoutine = Args->OutputRoutine; - PROS_TEST Test = Args->Test; + _PTEST Test = Args->Test; LPSTR TestName = Args->TestName; HANDLE hThread; FILETIME time; @@ -62,7 +62,7 @@ char Buffer[5000]; char Format[100]; - hThread = GetCurrentThread(); + hThread = _GetCurrentThread(); _SetThreadPriority(hThread, THREAD_PRIORITY_IDLE); memset(Buffer, 0, sizeof(Buffer)); @@ -84,8 +84,8 @@ &time, &ExecutionTime)) { - ExecutionTime.dwLowDateTime = 10; - ExecutionTime.dwHighDateTime = 10; + ExecutionTime.dwLowDateTime = 0; + ExecutionTime.dwHighDateTime = 0; } sprintf(OutputBuffer, "[%s] Success [%s]\n", @@ -108,7 +108,7 @@ { PLIST_ENTRY CurrentEntry; PLIST_ENTRY NextEntry; - PROS_TEST Current; + _PTEST Current; PERFORM_TEST_ARGS Args; HANDLE hThread; char OutputBuffer[1024]; @@ -122,7 +122,7 @@ for (; CurrentEntry != &AllTests; CurrentEntry = NextEntry) { NextEntry = CurrentEntry->Flink; - Current = CONTAINING_RECORD(CurrentEntry, ROS_TEST, ListEntry); + Current = CONTAINING_RECORD(CurrentEntry, _TEST, ListEntry); Args.Test = Current; /* Get name of test */ @@ -181,9 +181,9 @@ VOID AddTest(TestRoutine Routine) { - PROS_TEST Test; + _PTEST Test; - Test = (PROS_TEST) malloc(sizeof(ROS_TEST)); + Test = (_PTEST) malloc(sizeof(_TEST)); if (Test == NULL) { DbgPrint("Out of memory"); _____ Modified: trunk/reactos/regtests/shared/regtests.h --- trunk/reactos/regtests/shared/regtests.h 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/regtests/shared/regtests.h 2005-06-18 06:17:10 UTC (rev 16022) @@ -141,27 +141,27 @@ */ typedef void STDCALL (*TestDriverMain)(TestOutputRoutine OutputRoutine, char *TestName); -typedef struct _ROS_TEST +typedef struct __TEST { LIST_ENTRY ListEntry; TestRoutine Routine; -} ROS_TEST, *PROS_TEST; +} _TEST, *_PTEST; extern VOID InitializeTests(); extern VOID RegisterTests(); extern VOID PerformTests(TestOutputRoutine OutputRoutine, LPSTR TestName); -typedef struct _API_DESCRIPTION +typedef struct __API_DESCRIPTION { PCHAR FileName; PCHAR FunctionName; PCHAR ForwardedFunctionName; PVOID FunctionAddress; PVOID MockFunctionAddress; -} API_DESCRIPTION, *PAPI_DESCRIPTION; +} _API_DESCRIPTION, *_PAPI_DESCRIPTION; -extern API_DESCRIPTION ExternalDependencies[]; +extern _API_DESCRIPTION ExternalDependencies[]; extern ULONG MaxExternalDependency; HANDLE STDCALL @@ -205,9 +205,15 @@ BOOL STDCALL _SetThreadPriority(HANDLE hThread, int nPriority); +HANDLE STDCALL +_GetCurrentProcess(); +HANDLE STDCALL +_GetCurrentThread(); + + static inline PCHAR -FrameworkGetExportedFunctionNameInternal(PAPI_DESCRIPTION ApiDescription) +FrameworkGetExportedFunctionNameInternal(_PAPI_DESCRIPTION ApiDescription) { if (ApiDescription->ForwardedFunctionName != NULL) { @@ -220,7 +226,7 @@ } static inline PVOID -FrameworkGetFunction(PAPI_DESCRIPTION ApiDescription) +FrameworkGetFunction(_PAPI_DESCRIPTION ApiDescription) { HANDLE hModule; PVOID function = NULL; @@ -284,7 +290,7 @@ _SetHook(PCHAR name, PVOID address) { - PAPI_DESCRIPTION api; + _PAPI_DESCRIPTION api; ULONG index; for (index = 0; index <= MaxExternalDependency; index++) @@ -298,16 +304,16 @@ } } -typedef struct _HOOK +typedef struct __HOOK { PCHAR FunctionName; PVOID FunctionAddress; -} HOOK, *PHOOK; +} _HOOK, *_PHOOK; static inline VOID -_SetHooks(PHOOK hookTable) +_SetHooks(_PHOOK hookTable) { - PHOOK hook; + _PHOOK hook; hook = &hookTable[0]; while (hook->FunctionName != NULL) @@ -319,9 +325,9 @@ } static inline VOID -_UnsetHooks(PHOOK hookTable) +_UnsetHooks(_PHOOK hookTable) { - PHOOK hook; + _PHOOK hook; hook = &hookTable[0]; while (hook->FunctionName != NULL) @@ -335,7 +341,7 @@ static inline VOID _UnsetAllHooks() { - PAPI_DESCRIPTION api; + _PAPI_DESCRIPTION api; ULONG index; for (index = 0; index <= MaxExternalDependency; index++) _____ Deleted: trunk/reactos/subsys/win32k/tests/stubs.tst _____ Added: trunk/reactos/subsys/win32k/tests/stubs.xml --- trunk/reactos/subsys/win32k/tests/stubs.xml 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/subsys/win32k/tests/stubs.xml 2005-06-18 06:17:10 UTC (rev 16022) @@ -0,0 +1,154 @@ +<component name="ntdll.dll"> + <symbol>DbgPrint</symbol> + <symbol>RtlAssert@16</symbol> + <symbol>ZwAllocateVirtualMemory@24</symbol> + <symbol>RtlImageDirectoryEntryToData@16</symbol> + <symbol>RtlInitAnsiString@8</symbol> + <symbol>RtlInitUnicodeString@8</symbol> + <symbol>NtClose@4</symbol> + <symbol>ZwOpenFile@24</symbol> + <symbol>ZwClose@4</symbol> + <symbol>RtlNtStatusToDosError@4</symbol> + <symbol>NtW32Call@20</symbol> + <symbol>ZwOpenKey@12</symbol> + <symbol>ZwQueryValueKey@24</symbol> + <symbol>RtlUnicodeStringToInteger@12</symbol> + <symbol>RtlQueryAtomInAtomTable@24</symbol> + <symbol>RtlDeleteAtomFromAtomTable@8</symbol> + <symbol>RtlCopyUnicodeString@8</symbol> + <symbol>ZwRequestWaitReplyPort@12</symbol> + <symbol>ZwDuplicateObject@28</symbol> + <symbol>ZwSetSystemInformation@12</symbol> + <symbol>RtlLookupAtomInAtomTable@12</symbol> + <symbol>RtlAddAtomToAtomTable@12</symbol> + <symbol>RtlFreeUnicodeString@4</symbol> + <symbol>ZwConnectPort@32</symbol> + <symbol>ZwOpenProcess@16</symbol> + <symbol>RtlCreateUnicodeString@8</symbol> + <symbol>RtlQueryRegistryValues@20</symbol> + <symbol>RtlGetVersion@4</symbol> + <symbol>NtOpenFile@24</symbol> + <symbol>NtReadFile@36</symbol> + <symbol>NtWaitForSingleObject@12</symbol> + <symbol>NtDeviceIoControlFile@40</symbol> + <symbol>NtAlertThread@4</symbol> + <symbol>ZwQueryDefaultLocale@8</symbol> + <symbol>ZwFreeVirtualMemory@16</symbol> + <symbol>RtlFindClearBitsAndSet@12</symbol> + <symbol>ZwReadFile@36</symbol> + <symbol>RtlAnsiStringToUnicodeString@12</symbol> + <symbol>RtlCompareUnicodeString@12</symbol> + <symbol>ZwCreateDirectoryObject@12</symbol> + <symbol>RtlCreateAtomTable@8</symbol> + <symbol>RtlDestroyAtomTable@4</symbol> + <symbol>ZwOpenDirectoryObject@12</symbol> + <symbol>ZwQueryDirectoryObject@28</symbol> + <symbol>RtlAppendUnicodeToString@8</symbol> + <symbol>ZwCreateEvent@20</symbol> + <symbol>RtlAreBitsSet@12</symbol> + <symbol>RtlClearBits@12</symbol> + <symbol>RtlInitializeBitMap@12</symbol> + <symbol>RtlClearAllBits@4</symbol> + <symbol>RtlAppendUnicodeStringToString@8</symbol> + <symbol>ZwSetValueKey@24</symbol> + <symbol>ZwQueryDirectoryFile@44</symbol> + <symbol>RtlUnwind@16</symbol> + <symbol>NtQueryInformationFile@20</symbol> +</component> +<component name="ntoskrnl.exe"> + <symbol>ExAllocatePool@8</symbol> + <symbol>ExFreePool@4</symbol> + <symbol>ExAllocatePoolWithTag@12</symbol> + <symbol>IoBuildDeviceIoControlRequest@36</symbol> + <symbol>@IofCallDriver@8</symbol> + <symbol>KeWaitForSingleObject@20</symbol> + <symbol>@ExAcquireFastMutex@4</symbol> + <symbol>PsGetWin32Process@0</symbol> + <symbol>@ExReleaseFastMutex@4</symbol> + <symbol>@ExTryToAcquireFastMutex@4</symbol> + <symbol>KeInitializeEvent@12</symbol> + <symbol>ExEventObjectType</symbol> + <symbol>ObReferenceObjectByHandle@24</symbol> + <symbol>KeSetEvent@12</symbol> + <symbol>@ObfDereferenceObject@4</symbol> + <symbol>KeRestoreFloatingPointState@4</symbol> + <symbol>KeSaveFloatingPointState@4</symbol> + <symbol>MmSecureVirtualMemory@12</symbol> + <symbol>MmUnsecureVirtualMemory@4</symbol> + <symbol>IoGetCurrentProcess@0</symbol> + <symbol>KeQueryPerformanceCounter@4</symbol> + <symbol>ExInitializeResourceLite@4</symbol> + <symbol>ExAcquireResourceExclusiveLite@8</symbol> + <symbol>KeGetCurrentThread@0</symbol> + <symbol>PsGetCurrentProcessId@0</symbol> + <symbol>@InterlockedDecrement@4</symbol> + <symbol>@InterlockedExchange@8</symbol> + <symbol>KeBugCheck@4</symbol> + <symbol>ExDesktopObjectType</symbol> + <symbol>PsEstablishWin32Callouts@24</symbol> + <symbol>MmUnmapViewInSystemSpace@4</symbol> + <symbol>MmCreateSection@32</symbol> + <symbol>MmMapViewInSystemSpace@12</symbol> + <symbol>MmCopyToCaller@12</symbol> + <symbol>PsGetWin32Thread@0</symbol> + <symbol>KeDetachProcess@0</symbol> + <symbol>ExInitializePagedLookasideList@28</symbol> + <symbol>@InterlockedPushEntrySList@8</symbol> + <symbol>ExInterlockedInsertTailList@12</symbol> + <symbol>KeReleaseSpinLock@8</symbol> + <symbol>ObOpenObjectByName@28</symbol> + <symbol>ObOpenObjectByPointer@28</symbol> + <symbol>KeAcquireSpinLock@8</symbol> + <symbol>ExGetPreviousMode@0</symbol> + <symbol>PsGetCurrentThreadId@0</symbol> + <symbol>@ExReleaseResourceLite@4</symbol> + <symbol>ExIsResourceAcquiredExclusiveLite@</symbol> + <symbol>@InterlockedIncrement@4</symbol> + <symbol>@InterlockedCompareExchange@12</symbol> + <symbol>KeAddSystemServiceTable@20</symbol> + <symbol>IoFileObjectType</symbol> + <symbol>ObReferenceObjectByPointer@16</symbol> + <symbol>MmUnmapViewOfSection@8</symbol> + <symbol>MmCopyFromCaller@12</symbol> + <symbol>KiKernelApcDeliveryCheck@0</symbol> + <symbol>ExIsResourceAcquiredExclusiveLite@4</symbol> + <symbol>MmMapViewOfSection@40</symbol> + <symbol>KeAttachProcess@4</symbol> + <symbol>@InterlockedPopEntrySList@4</symbol> + <symbol>ExWindowStationObjectType</symbol> + <symbol>ObInsertObject@24</symbol> + <symbol>KeInitializeSpinLock@4</symbol> + <symbol>PsThreadType</symbol> + <symbol>PsCreateSystemThread@28</symbol> + <symbol>KeQueryTickCount@4</symbol> + <symbol>PsLookupThreadByThreadId@8</symbol> + <symbol>KeInitializeMutex@8</symbol> + <symbol>KeWaitForMutexObject@20</symbol> + <symbol>KeReleaseMutex@8</symbol> + <symbol>KeDelayExecutionThread@12</symbol> + <symbol>PsGetProcessId@4</symbol> + <symbol>ObCreateObject@36</symbol> + <symbol>KeClearEvent@4</symbol> + <symbol>PsLookupProcessByProcessId@8</symbol> + <symbol>PsProcessType</symbol> + <symbol>KeWaitForMultipleObjects@32</symbol> + <symbol>KeQuerySystemTime@4</symbol> + <symbol>ObReferenceObjectByName@32</symbol> + <symbol>HalQueryDisplayOwnership@0</symbol> + <symbol>IoDeviceObjectType</symbol> +</component> +<component name="freetype.dll"> + <symbol>FT_Init_FreeType</symbol> + <symbol>FT_New_Memory_Face</symbol> + <symbol>FT_Done_Face</symbol> + <symbol>FT_MulFix</symbol> + <symbol>FT_Get_Sfnt_Table</symbol> + <symbol>FT_Get_First_Char</symbol> + <symbol>FT_Set_Pixel_Sizes</symbol> + <symbol>FT_Get_Char_Index</symbol> + <symbol>FT_Load_Glyph</symbol> + <symbol>FT_Get_Kerning</symbol> + <symbol>FT_Render_Glyph</symbol> + <symbol>FT_Set_Charmap</symbol> + <symbol>FT_Load_Sfnt_Table</symbol> +</component> Property changes on: trunk/reactos/subsys/win32k/tests/stubs.xml ___________________________________________________________________ Name: svn:eol-style + native _____ Added: trunk/reactos/subsys/win32k/tests/win32k.xml --- trunk/reactos/subsys/win32k/tests/win32k.xml 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/subsys/win32k/tests/win32k.xml 2005-06-18 06:17:10 UTC (rev 16022) @@ -0,0 +1,25 @@ +<module name="win32k_test" type="test"> + <include base="rtshared">.</include> + <include base="win32k">.</include> + <include base="win32k">include</include> + <define name="UNICODE" /> + <define name="__USE_W32API" /> + <define name="_WIN32_WINNT">0x0501</define> + <define name="WINVER">0x600</define> + <define name="_DISABLE_TIDENTS" /> + <define name="_SEH_NO_NATIVE_NLG" /> + <define name="_WIN32K_" /> + <library>rtshared</library> + <library>regtests</library> + <library>win32k_base</library> + <library>pseh</library> + <library>rosrtl</library> + <library>msvcrt</library> + <linkerflag>-lgcc</linkerflag> + <linkerflag>-nostartfiles</linkerflag> + <linkerflag>-nostdlib</linkerflag> + <directory name="tests"> + </directory> + <file>setup.c</file> + <xi:include href="stubs.xml" /> +</module> Property changes on: trunk/reactos/subsys/win32k/tests/win32k.xml ___________________________________________________________________ Name: svn:eol-style + native _____ Modified: trunk/reactos/subsys/win32k/win32k.xml --- trunk/reactos/subsys/win32k/win32k.xml 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/subsys/win32k/win32k.xml 2005-06-18 06:17:10 UTC (rev 16022) @@ -1,5 +1,4 @@ -<module name="win32k" type="kernelmodedriver" installbase="system32" installname="win32k.sys" warnings="true"> - <importlibrary definition="win32k.def" /> +<module name="win32k_base" type="objectlibrary" warnings="true"> <include base="win32k">.</include> <include base="win32k">include</include> <include base="ntoskrnl">include</include> @@ -8,12 +7,8 @@ <define name="__USE_W32API" /> <define name="_WIN32_WINNT">0x0501</define> <define name="WINVER">0x600</define> + <define name="_SEH_NO_NATIVE_NLG" /> <define name="_WIN32K_" /> - <library>pseh</library> - <library>rosrtl</library> - <library>ntoskrnl</library> - <library>hal</library> - <library>freetype</library> <pch>w32k.h</pch> <directory name="dib"> <file>dib1bpp.c</file> @@ -132,5 +127,17 @@ <file>stubs.c</file> <file>xpstubs.c</file> </directory> +</module> +<module name="win32k" type="kernelmodedriver" installbase="system32" installname="win32k.sys" warnings="true"> + <importlibrary definition="win32k.def" /> + <library>win32k_base</library> + <library>pseh</library> + <library>rosrtl</library> + <library>ntoskrnl</library> + <library>hal</library> + <library>freetype</library> <file>win32k.rc</file> </module> +<directory name="tests"> + <xi:include href="tests/win32k.xml" /> +</directory> _____ Modified: trunk/reactos/tools/rbuild/rbuild.h --- trunk/reactos/tools/rbuild/rbuild.h 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/tools/rbuild/rbuild.h 2005-06-18 06:17:10 UTC (rev 16022) @@ -494,6 +494,7 @@ int* stubIndex ); void WriteStubsFile ( Module& module ); std::string GetStartupFilename ( Module& module ); + bool IsUnknownCharacter ( char ch ); std::string GetTestDispatcherName ( std::string filename ); bool IsTestFile ( std::string& filename ) const; void GetSourceFilenames ( string_list& list, _____ Modified: trunk/reactos/tools/rbuild/testsupportcode.cpp --- trunk/reactos/tools/rbuild/testsupportcode.cpp 2005-06-17 22:59:39 UTC (rev 16021) +++ trunk/reactos/tools/rbuild/testsupportcode.cpp 2005-06-18 06:17:10 UTC (rev 16022) @@ -93,7 +93,7 @@ s = s + sprintf ( s, "#include <windows.h>\n" ); s = s + sprintf ( s, "#include \"regtests.h\"\n" ); s = s + sprintf ( s, "\n" ); - s = s + sprintf ( s, "API_DESCRIPTION ExternalDependencies[] =\n" ); + s = s + sprintf ( s, "_API_DESCRIPTION ExternalDependencies[] =\n" ); s = s + sprintf ( s, "{\n" ); int symbolCount = 0; @@ -121,19 +121,35 @@ return NormalizeFilename ( Environment::GetIntermediatePath () + SSEP + module.GetBasePath () + SSEP + "_stubs.S" ); } +string +GetImportSymbol ( const StubbedSymbol& symbol ) +{ + if (symbol.symbol[0] == '@') + return "__imp_" + symbol.symbol; + else + return "__imp__" + symbol.symbol; +} + char* TestSupportCode::WriteStubbedSymbolToStubsFile ( char* buffer, const StubbedComponent& component, - const StubbedSymbol& symbol, + const StubbedSymbol& symbol, int stubIndex ) { + string importSymbol = GetImportSymbol( symbol ); buffer = buffer + sprintf ( buffer, ".globl _%s\n", symbol.symbol.c_str () ); buffer = buffer + sprintf ( buffer, + ".globl %s\n", + importSymbol.c_str () ); + buffer = buffer + sprintf ( buffer, "_%s:\n", symbol.symbol.c_str () ); buffer = buffer + sprintf ( buffer, + "%s:\n", + importSymbol.c_str () ); + buffer = buffer + sprintf ( buffer, " pushl $%d\n", stubIndex ); buffer = buffer + sprintf ( buffer, @@ -196,6 +212,18 @@ return NormalizeFilename ( Environment::GetIntermediatePath () + SSEP + module.GetBasePath () + SSEP + "_startup.c" ); } +bool +TestSupportCode::IsUnknownCharacter ( char ch ) +{ + if ( ch >= 'a' && ch <= 'z' ) + return false; + if ( ch >= 'A' && ch <= 'Z' ) + return false; + if ( ch >= '0' && ch <= '9' ) + return false; + return true; +} + string TestSupportCode::GetTestDispatcherName ( string filename ) { @@ -204,7 +232,10 @@ filenamePart[0] = toupper ( filenamePart[0] ); for ( size_t i = 1; i < filenamePart.length (); i++ ) { - filenamePart[i] = tolower ( filenamePart[i] ); + if ( IsUnknownCharacter ( filenamePart[i] ) ) + filenamePart[i] = '_'; + else + filenamePart[i] = tolower ( filenamePart[i] ); } return filenamePart + "Test"; } @@ -333,7 +364,7 @@ s = s + sprintf ( s, " LPSTR lpszCmdParam,\n" ); s = s + sprintf ( s, " int nCmdShow)\n" ); s = s + sprintf ( s, "{\n" ); - s = s + sprintf ( s, " _SetPriorityClass(GetCurrentProcess(), IDLE_PRIORITY_CLASS);\n" ); + s = s + sprintf ( s, " _SetPriorityClass(_GetCurrentProcess(), IDLE_PRIORITY_CLASS);\n" ); s = s + sprintf ( s, " InitializeTests();\n" ); s = s + sprintf ( s, " RegisterTests();\n" ); s = s + sprintf ( s, " SetupOnce();\n" );
19 years, 6 months
1
0
0
0
[navaraf] 16021: Fix "make test".
by navaraf@svn.reactos.com
Fix "make test". Modified: trunk/reactos/lib/kernel32/tests/kernel32.xml _____ Modified: trunk/reactos/lib/kernel32/tests/kernel32.xml --- trunk/reactos/lib/kernel32/tests/kernel32.xml 2005-06-17 22:05:16 UTC (rev 16020) +++ trunk/reactos/lib/kernel32/tests/kernel32.xml 2005-06-17 22:59:39 UTC (rev 16021) @@ -1,5 +1,6 @@ <module name="kernel32_test" type="test"> <include base="rtshared">.</include> + <define name="__USE_W32API" /> <define name="_DISABLE_TIDENTS" /> <define name="_SEH_NO_NATIVE_NLG" /> <define name="WINVER">0x0500</define>
19 years, 6 months
1
0
0
0
[ion] 16020: Add KIPCR which will be needed soon and add one more internal function
by ion@svn.reactos.com
Add KIPCR which will be needed soon and add one more internal function Modified: trunk/reactos/ntoskrnl/include/internal/i386/ps.h Modified: trunk/reactos/ntoskrnl/include/internal/mm.h _____ Modified: trunk/reactos/ntoskrnl/include/internal/i386/ps.h --- trunk/reactos/ntoskrnl/include/internal/i386/ps.h 2005-06-17 21:35:33 UTC (rev 16019) +++ trunk/reactos/ntoskrnl/include/internal/i386/ps.h 2005-06-17 22:05:16 UTC (rev 16020) @@ -19,6 +19,10 @@ #ifndef __NTOSKRNL_INCLUDE_INTERNAL_I386_PS_H #define __NTOSKRNL_INCLUDE_INTERNAL_I386_PS_H +#ifdef __USE_W32API +#include <ddk/ntpoapi.h> +#endif + /* * Defines for accessing KPCR and KTHREAD structure members */ @@ -253,6 +257,37 @@ #pragma pack(pop) #endif /* __USE_W32API */ +/* + * This is the complete, internal KPCR structure + */ +typedef struct _KIPCR { + KPCR_TIB Tib; /* 00 */ + struct _KPCR *Self; /* 1C */ + struct _KPRCB *Prcb; /* 20 */ + KIRQL Irql; /* 24 */ + ULONG IRR; /* 28 */ + ULONG IrrActive; /* 2C */ + ULONG IDR; /* 30 */ + PVOID KdVersionBlock; /* 34 */ + PUSHORT IDT; /* 38 */ + PUSHORT GDT; /* 3C */ + struct _KTSS *TSS; /* 40 */ + USHORT MajorVersion; /* 44 */ + USHORT MinorVersion; /* 46 */ + KAFFINITY SetMember; /* 48 */ + ULONG StallScaleFactor; /* 4C */ + UCHAR SparedUnused; /* 50 */ + UCHAR Number; /* 51 */ + UCHAR Reserved; /* 52 */ + UCHAR L2CacheAssociativity; /* 53 */ + ULONG VdmAlert; /* 54 */ + ULONG KernelReserved[14]; /* 58 */ + ULONG L2CacheSize; /* 90 */ + ULONG HalReserved[16]; /* 94 */ + ULONG InterruptMode; /* D4 */ + UCHAR KernelReserved2[0x48]; /* D8 */ + KPRCB PrcbData; /* 120 */ +} KIPCR, *PKIPCR; #ifndef __USE_W32API _____ Modified: trunk/reactos/ntoskrnl/include/internal/mm.h --- trunk/reactos/ntoskrnl/include/internal/mm.h 2005-06-17 21:35:33 UTC (rev 16019) +++ trunk/reactos/ntoskrnl/include/internal/mm.h 2005-06-17 22:05:16 UTC (rev 16020) @@ -856,6 +856,16 @@ NTSTATUS MmTrimUserMemory(ULONG Target, ULONG Priority, PULONG NrFreedPages); +/* cont.c ********************************************************************/ + +PVOID STDCALL +MmAllocateContiguousAlignedMemory(IN ULONG NumberOfBytes, + IN PHYSICAL_ADDRESS LowestAcceptableAddress, + IN PHYSICAL_ADDRESS HighestAcceptableAddress, + IN PHYSICAL_ADDRESS BoundaryAddressMultiple OPTIONAL, + IN MEMORY_CACHING_TYPE CacheType OPTIONAL, + IN ULONG Alignment); + /* region.c ************************************************************/ NTSTATUS MmAlterRegion(PMADDRESS_SPACE AddressSpace, PVOID BaseAddress,
19 years, 6 months
1
0
0
0
← Newer
1
...
31
32
33
34
35
36
37
...
65
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
Results per page:
10
25
50
100
200