4 * This file contains the Nt* API functions of NTDLL.DLL.
5 * In the original ntdll.dll they all seem to just call int 0x2e (down to the NTOSKRNL)
7 * Copyright 1996-1998 Marcus Meissner
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; either
12 * version 2.1 of the License, or (at your option) any later version.
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
29 #define NONAMELESSUNION
31 #define WIN32_NO_STATUS
32 #include "wine/debug.h"
35 #include "ntdll_misc.h"
36 #include "wine/server.h"
39 WINE_DEFAULT_DEBUG_CHANNEL(ntdll
);
49 /***********************************************************************
50 * RtlIsProcessorFeaturePresent [NTDLL.@]
52 BOOLEAN WINAPI
RtlIsProcessorFeaturePresent( UINT feature
)
54 return feature
< PROCESSOR_FEATURE_MAX
&& user_shared_data
->ProcessorFeatures
[feature
];
57 /******************************************************************************
58 * RtlGetNativeSystemInformation [NTDLL.@]
60 NTSTATUS WINAPI
/* DECLSPEC_HOTPATCH */ RtlGetNativeSystemInformation(
61 IN SYSTEM_INFORMATION_CLASS SystemInformationClass
,
62 OUT PVOID SystemInformation
,
64 OUT PULONG ResultLength
)
66 FIXME( "semi-stub, SystemInformationClass %#x, SystemInformation %p, Length %#x, ResultLength %p.\n",
67 SystemInformationClass
, SystemInformation
, Length
, ResultLength
);
69 /* RtlGetNativeSystemInformation function is the same as NtQuerySystemInformation on some Win7
70 * versions but there are differences for earlier and newer versions, at least:
71 * - HighestUserAddress field for SystemBasicInformation;
72 * - Some information classes are not supported by RtlGetNativeSystemInformation. */
73 return NtQuerySystemInformation( SystemInformationClass
, SystemInformation
, Length
, ResultLength
);
76 /******************************************************************************
77 * VerSetConditionMask (NTDLL.@)
79 ULONGLONG WINAPI
VerSetConditionMask( ULONGLONG dwlConditionMask
, DWORD dwTypeBitMask
,
82 if(dwTypeBitMask
== 0)
83 return dwlConditionMask
;
84 dwConditionMask
&= 0x07;
85 if(dwConditionMask
== 0)
86 return dwlConditionMask
;
88 if(dwTypeBitMask
& VER_PRODUCT_TYPE
)
89 dwlConditionMask
|= dwConditionMask
<< 7*3;
90 else if (dwTypeBitMask
& VER_SUITENAME
)
91 dwlConditionMask
|= dwConditionMask
<< 6*3;
92 else if (dwTypeBitMask
& VER_SERVICEPACKMAJOR
)
93 dwlConditionMask
|= dwConditionMask
<< 5*3;
94 else if (dwTypeBitMask
& VER_SERVICEPACKMINOR
)
95 dwlConditionMask
|= dwConditionMask
<< 4*3;
96 else if (dwTypeBitMask
& VER_PLATFORMID
)
97 dwlConditionMask
|= dwConditionMask
<< 3*3;
98 else if (dwTypeBitMask
& VER_BUILDNUMBER
)
99 dwlConditionMask
|= dwConditionMask
<< 2*3;
100 else if (dwTypeBitMask
& VER_MAJORVERSION
)
101 dwlConditionMask
|= dwConditionMask
<< 1*3;
102 else if (dwTypeBitMask
& VER_MINORVERSION
)
103 dwlConditionMask
|= dwConditionMask
<< 0*3;
104 return dwlConditionMask
;