Author: sginsberg
Date: Sat Aug 30 15:29:57 2008
New Revision: 35817
URL:
http://svn.reactos.org/svn/reactos?rev=35817&view=rev
Log:
- Add APIs new to Windows 2003/SP1 (including XP SP1)
- Add missing NtGetCurrentProcessorNumber to ntdll
- Update headers with missing structures
Modified:
trunk/reactos/dll/ntdll/def/ntdll_arm.def
trunk/reactos/dll/ntdll/def/ntdll_i386.def
trunk/reactos/dll/win32/advapi32/advapi32.def
trunk/reactos/dll/win32/advapi32/token/token.c
trunk/reactos/dll/win32/kernel32/kernel32.def
trunk/reactos/dll/win32/kernel32/misc/stubs.c
trunk/reactos/dll/win32/kernel32/misc/sysinfo.c
trunk/reactos/dll/win32/psapi/psapi.c
trunk/reactos/dll/win32/psapi/psapi.def
trunk/reactos/include/psdk/winnt.h
Modified: trunk/reactos/dll/ntdll/def/ntdll_arm.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/def/ntdll_arm.de…
==============================================================================
--- trunk/reactos/dll/ntdll/def/ntdll_arm.def [iso-8859-1] (original)
+++ trunk/reactos/dll/ntdll/def/ntdll_arm.def [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -291,6 +291,7 @@
NtWriteRequestData
NtWriteVirtualMemory
NtYieldExecution
+NtGetCurrentProcessorNumber
;PfxFindPrefix
;PfxInitialize
;PfxInsertPrefix
Modified: trunk/reactos/dll/ntdll/def/ntdll_i386.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/def/ntdll_i386.d…
==============================================================================
--- trunk/reactos/dll/ntdll/def/ntdll_i386.def [iso-8859-1] (original)
+++ trunk/reactos/dll/ntdll/def/ntdll_i386.def [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -291,6 +291,7 @@
NtWriteRequestData@24
NtWriteVirtualMemory@20
NtYieldExecution@0
+NtGetCurrentProcessorNumber@0
;PfxFindPrefix
;PfxInitialize
;PfxInsertPrefix
Modified: trunk/reactos/dll/win32/advapi32/advapi32.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/advapi3…
==============================================================================
--- trunk/reactos/dll/win32/advapi32/advapi32.def [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/advapi32/advapi32.def [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -107,6 +107,7 @@
;CreateProcessAsUserSecure
CreateProcessAsUserW@44
;CreateProcessWithLogonW
+CreateProcessWithTokenW@36
CreateRestrictedToken@36
CreateServiceA@52
CreateServiceW@52
Modified: trunk/reactos/dll/win32/advapi32/token/token.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/token/t…
==============================================================================
--- trunk/reactos/dll/win32/advapi32/token/token.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/advapi32/token/token.c [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -670,4 +670,18 @@
return PSiteSid;
}
-
+BOOL
+WINAPI
+CreateProcessWithTokenW(IN HANDLE hToken,
+ IN DWORD dwLogonFlags,
+ IN LPCWSTR lpApplicationName OPTIONAL,
+ IN OUT LPWSTR lpCommandLine OPTIONAL,
+ IN DWORD dwCreationFlags,
+ IN LPVOID lpEnvironment OPTIONAL,
+ IN LPCWSTR lpCurrentDirectory OPTIONAL,
+ IN LPSTARTUPINFOW lpStartupInfo,
+ OUT LPPROCESS_INFORMATION lpProcessInfo)
+{
+ UNIMPLEMENTED;
+ return FALSE;
+}
Modified: trunk/reactos/dll/win32/kernel32/kernel32.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/kernel3…
==============================================================================
--- trunk/reactos/dll/win32/kernel32/kernel32.def [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/kernel32/kernel32.def [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -97,6 +97,7 @@
ConvertDefaultLocale@4
ConvertFiberToThread@0
ConvertThreadToFiber@4
+ConvertThreadToFiberEx@8
CopyFileA@12
CopyFileExA@24
CopyFileExW@24
@@ -210,6 +211,7 @@
EnumResourceTypesW@12
EnumSystemCodePagesA@8
EnumSystemCodePagesW@8
+EnumSystemFirmwareTables@12
EnumSystemGeoID@12
EnumSystemLanguageGroupsA@12
EnumSystemLanguageGroupsW@12
@@ -272,10 +274,10 @@
FindResourceW@12
FindVolumeClose@4
FindVolumeMountPointClose@4
-;FlsAlloc@4 ;new for 2003
-;FlsFree@4 ;new for 2003
-;FlsGetValue@4 ;new for 2003
-;FlsSetValue@8 ;new for 2003
+FlsAlloc@4
+FlsFree@4
+FlsGetValue@4
+FlsSetValue@8
FlushConsoleInputBuffer@4
FlushFileBuffers@4
FlushInstructionCache@12
@@ -366,6 +368,7 @@
GetCurrentDirectoryW@8
GetCurrentProcess@0
GetCurrentProcessId@0
+GetCurrentProcessorNumber@0
GetCurrentThread@0
GetCurrentThreadId@0
GetDateFormatA@24
@@ -423,6 +426,7 @@
GetLogicalDriveStringsA@8
GetLogicalDriveStringsW@8
GetLogicalDrives@0
+GetLogicalProcessorInformation@8
GetLongPathNameA@12
GetLongPathNameW@12
GetMailslotInfo@20
@@ -438,6 +442,7 @@
GetNativeSystemInfo@4
GetNextVDMCommand@4
GetNlsSectionName@24
+GetNumaAvailableMemoryNode@8
GetNumaHighestNodeNumber@4
GetNumaNodeProcessorMask@8
;GetNumaProcessorMap
@@ -473,6 +478,7 @@
GetProcessTimes@20
GetProcessVersion@4
GetProcessWorkingSetSize@12
+GetProcessWorkingSetSizeEx@16
GetProfileIntA@12
GetProfileIntW@12
GetProfileSectionA@12
@@ -494,6 +500,8 @@
GetSystemDefaultUILanguage@0
GetSystemDirectoryA@8
GetSystemDirectoryW@8
+GetSystemFileCacheSize@12
+GetSystemFirmwareTable@16
GetSystemInfo@4
GetSystemPowerStatus@4
GetSystemRegistryQuota@8
@@ -763,6 +771,7 @@
;RemoveLocalAlternateComputerNameA
;RemoveLocalAlternateComputerNameW
RemoveVectoredExceptionHandler(a)4=NTDLL.RtlRemoveVectoredExceptionHandler
+ReOpenFile@16
ReplaceFile=ReplaceFileW@24
ReplaceFileA@24
ReplaceFileW@24
@@ -874,7 +883,9 @@
SetProcessPriorityBoost@8
SetProcessShutdownParameters@8
SetProcessWorkingSetSize@12
+SetProcessWorkingSetSizeEx@16
SetStdHandle@8
+SetSystemFileCacheSize@12
SetSystemPowerState@8
SetSystemTime@4
SetSystemTimeAdjustment@8
@@ -888,6 +899,7 @@
SetThreadLocale@4
SetThreadPriority@8
SetThreadPriorityBoost@8
+SetThreadStackGuarantee@4
SetThreadUILanguage@4
SetTimerQueueTimer@24
SetTimeZoneInformation@4
Modified: trunk/reactos/dll/win32/kernel32/misc/stubs.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/misc/st…
==============================================================================
--- trunk/reactos/dll/win32/kernel32/misc/stubs.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/kernel32/misc/stubs.c [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -1402,3 +1402,104 @@
STUB;
return FALSE;
}
+
+UINT
+WINAPI
+EnumSystemFirmwareTables(IN DWORD FirmwareTableProviderSignature,
+ OUT PVOID pFirmwareTableBuffer,
+ IN DWORD BufferSize)
+{
+ STUB;
+ return 0;
+}
+
+BOOL
+WINAPI
+GetSystemFileCacheSize(OUT PSIZE_T lpMinimumFileCacheSize,
+ OUT PSIZE_T lpMaximumFileCacheSize,
+ OUT PDWORD lpFlags)
+{
+ STUB;
+ return FALSE;
+}
+
+UINT
+WINAPI
+GetSystemFirmwareTable(IN DWORD FirmwareTableProviderSignature,
+ IN DWORD FirmwareTableID,
+ OUT PVOID pFirmwareTableBuffer,
+ IN DWORD BufferSize)
+{
+ STUB;
+ return 0;
+}
+
+BOOL
+WINAPI
+SetSystemFileCacheSize(IN SIZE_T MinimumFileCacheSize,
+ IN SIZE_T MaximumFileCacheSize,
+ IN DWORD Flags)
+{
+ STUB;
+ return FALSE;
+}
+
+BOOL
+WINAPI
+SetThreadStackGuarantee(IN OUT PULONG StackSizeInBytes)
+{
+ STUB;
+ return FALSE;
+}
+
+HANDLE
+WINAPI
+ReOpenFile(IN HANDLE hOriginalFile,
+ IN DWORD dwDesiredAccess,
+ IN DWORD dwShareMode,
+ IN DWORD dwFlags)
+{
+ STUB;
+ return INVALID_HANDLE_VALUE;
+}
+
+BOOL
+WINAPI
+SetProcessWorkingSetSizeEx(IN HANDLE hProcess,
+ IN SIZE_T dwMinimumWorkingSetSize,
+ IN SIZE_T dwMaximumWorkingSetSize,
+ IN DWORD Flags)
+{
+ STUB;
+ return FALSE;
+}
+
+
+BOOL
+WINAPI
+GetProcessWorkingSetSizeEx(IN HANDLE hProcess,
+ OUT PSIZE_T lpMinimumWorkingSetSize,
+ OUT PSIZE_T lpMaximumWorkingSetSize,
+ OUT PDWORD Flags)
+{
+ STUB;
+ return FALSE;
+}
+
+BOOL
+WINAPI
+GetLogicalProcessorInformation(OUT PSYSTEM_LOGICAL_PROCESSOR_INFORMATION Buffer,
+ IN OUT PDWORD ReturnLength)
+{
+ STUB;
+ return FALSE;
+}
+
+BOOL
+WINAPI
+GetNumaAvailableMemoryNode(IN UCHAR Node,
+ OUT PULONGLONG AvailableBytes)
+{
+ STUB;
+ return FALSE;
+}
Modified: trunk/reactos/dll/win32/kernel32/misc/sysinfo.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/misc/sy…
==============================================================================
--- trunk/reactos/dll/win32/kernel32/misc/sysinfo.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/kernel32/misc/sysinfo.c [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -233,4 +233,12 @@
GetSystemInfo(lpSystemInfo);
}
+DWORD
+WINAPI
+GetCurrentProcessorNumber(VOID)
+{
+ /* Forward to kernel */
+ return NtGetCurrentProcessorNumber();
+}
+
/* EOF */
Modified: trunk/reactos/dll/win32/psapi/psapi.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/psapi/psapi.c?re…
==============================================================================
--- trunk/reactos/dll/win32/psapi/psapi.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/psapi/psapi.c [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -1398,4 +1398,17 @@
return TRUE;
}
+/*
+ * @unimplemented
+ */
+BOOL
+WINAPI
+QueryWorkingSetEx(IN HANDLE hProcess,
+ IN OUT PVOID pv,
+ IN DWORD cb)
+{
+ UNIMPLEMENTED;
+ return FALSE;
+}
+
/* EOF */
Modified: trunk/reactos/dll/win32/psapi/psapi.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/psapi/psapi.def?…
==============================================================================
--- trunk/reactos/dll/win32/psapi/psapi.def [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/psapi/psapi.def [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -32,3 +32,4 @@
GetWsChanges@12 @22
InitializeProcessForWsWatch@4 @23
QueryWorkingSet@12 @24
+QueryWorkingSetEx@12 @25
Modified: trunk/reactos/include/psdk/winnt.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/winnt.h?rev=3…
==============================================================================
--- trunk/reactos/include/psdk/winnt.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/winnt.h [iso-8859-1] Sat Aug 30 15:29:57 2008
@@ -4400,6 +4400,45 @@
ULONGLONG WINAPI VerSetConditionMask(ULONGLONG,DWORD,BYTE);
#endif
+typedef enum _PROCESSOR_CACHE_TYPE {
+ CacheUnified,
+ CacheInstruction,
+ CacheData,
+ CacheTrace
+} PROCESSOR_CACHE_TYPE;
+
+typedef enum _LOGICAL_PROCESSOR_RELATIONSHIP {
+ RelationProcessorCore,
+ RelationNumaNode,
+ RelationCache,
+ RelationProcessorPackage
+} LOGICAL_PROCESSOR_RELATIONSHIP;
+
+#define CACHE_FULLY_ASSOCIATIVE 0xFF
+
+typedef struct _CACHE_DESCRIPTOR {
+ BYTE Level;
+ BYTE Associativity;
+ WORD LineSize;
+ DWORD Size;
+ PROCESSOR_CACHE_TYPE Type;
+} CACHE_DESCRIPTOR, *PCACHE_DESCRIPTOR;
+
+typedef struct _SYSTEM_LOGICAL_PROCESSOR_INFORMATION {
+ ULONG_PTR ProcessorMask;
+ LOGICAL_PROCESSOR_RELATIONSHIP Relationship;
+ union {
+ struct {
+ BYTE Flags;
+ } ProcessorCore;
+ struct {
+ DWORD NodeNumber;
+ } NumaNode;
+ CACHE_DESCRIPTOR Cache;
+ ULONGLONG Reserved[2];
+ };
+} SYSTEM_LOGICAL_PROCESSOR_INFORMATION, *PSYSTEM_LOGICAL_PROCESSOR_INFORMATION;
+
NTSYSAPI
SIZE_T
STDCALL