mirror of
https://github.com/reactos/reactos.git
synced 2025-02-25 09:50:02 +00:00
Fix some ntoskrnl things, like using Rtl instead of RosRtl, and undefining ROUND macros
svn path=/trunk/; revision=16077
This commit is contained in:
parent
e960d42247
commit
10c1c40139
10 changed files with 20 additions and 28 deletions
|
@ -16,8 +16,6 @@
|
||||||
|
|
||||||
/* GLOBALS *******************************************************************/
|
/* GLOBALS *******************************************************************/
|
||||||
|
|
||||||
#define ROUND_DOWN(N, S) ((N) - ((N) % (S)))
|
|
||||||
|
|
||||||
static PFN_TYPE CcZeroPage = 0;
|
static PFN_TYPE CcZeroPage = 0;
|
||||||
|
|
||||||
#define MAX_ZERO_LENGTH (256 * 1024)
|
#define MAX_ZERO_LENGTH (256 * 1024)
|
||||||
|
|
|
@ -16,8 +16,6 @@
|
||||||
|
|
||||||
/* GLOBALS *******************************************************************/
|
/* GLOBALS *******************************************************************/
|
||||||
|
|
||||||
#define ROUND_DOWN(N, S) ((N) - ((N) % (S)))
|
|
||||||
|
|
||||||
extern NPAGED_LOOKASIDE_LIST iBcbLookasideList;
|
extern NPAGED_LOOKASIDE_LIST iBcbLookasideList;
|
||||||
|
|
||||||
/* FUNCTIONS *****************************************************************/
|
/* FUNCTIONS *****************************************************************/
|
||||||
|
|
|
@ -20,8 +20,6 @@
|
||||||
|
|
||||||
/* LOCAL MACROS *************************************************************/
|
/* LOCAL MACROS *************************************************************/
|
||||||
|
|
||||||
#define ROUND_DOWN(N, S) ((N) - ((N) % (S)))
|
|
||||||
|
|
||||||
#define ABS_VALUE(V) (((V) < 0) ? -(V) : (V))
|
#define ABS_VALUE(V) (((V) < 0) ? -(V) : (V))
|
||||||
|
|
||||||
BOOLEAN CmiDoVerify = FALSE;
|
BOOLEAN CmiDoVerify = FALSE;
|
||||||
|
|
|
@ -650,7 +650,7 @@ CmiCreateCurrentControlSetLink(VOID)
|
||||||
|
|
||||||
DPRINT("Link target '%S'\n", TargetNameBuffer);
|
DPRINT("Link target '%S'\n", TargetNameBuffer);
|
||||||
|
|
||||||
RtlRosInitUnicodeStringFromLiteral(&LinkName,
|
RtlInitUnicodeString(&LinkName,
|
||||||
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&LinkName,
|
&LinkName,
|
||||||
|
@ -670,7 +670,7 @@ CmiCreateCurrentControlSetLink(VOID)
|
||||||
return(Status);
|
return(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlRosInitUnicodeStringFromLiteral(&LinkValue,
|
RtlInitUnicodeString(&LinkValue,
|
||||||
L"SymbolicLinkValue");
|
L"SymbolicLinkValue");
|
||||||
Status = ZwSetValueKey(KeyHandle,
|
Status = ZwSetValueKey(KeyHandle,
|
||||||
&LinkValue,
|
&LinkValue,
|
||||||
|
@ -925,7 +925,7 @@ CmiInitControlSetLink (VOID)
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
/* Create 'ControlSet001' key */
|
/* Create 'ControlSet001' key */
|
||||||
RtlRosInitUnicodeStringFromLiteral (&ControlSetKeyName,
|
RtlInitUnicodeString(&ControlSetKeyName,
|
||||||
L"\\Registry\\Machine\\SYSTEM\\ControlSet001");
|
L"\\Registry\\Machine\\SYSTEM\\ControlSet001");
|
||||||
InitializeObjectAttributes (&ObjectAttributes,
|
InitializeObjectAttributes (&ObjectAttributes,
|
||||||
&ControlSetKeyName,
|
&ControlSetKeyName,
|
||||||
|
@ -947,7 +947,7 @@ CmiInitControlSetLink (VOID)
|
||||||
ZwClose (KeyHandle);
|
ZwClose (KeyHandle);
|
||||||
|
|
||||||
/* Link 'CurrentControlSet' to 'ControlSet001' key */
|
/* Link 'CurrentControlSet' to 'ControlSet001' key */
|
||||||
RtlRosInitUnicodeStringFromLiteral (&ControlSetLinkName,
|
RtlInitUnicodeString (&ControlSetLinkName,
|
||||||
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
||||||
InitializeObjectAttributes (&ObjectAttributes,
|
InitializeObjectAttributes (&ObjectAttributes,
|
||||||
&ControlSetLinkName,
|
&ControlSetLinkName,
|
||||||
|
@ -967,7 +967,7 @@ CmiInitControlSetLink (VOID)
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlRosInitUnicodeStringFromLiteral (&ControlSetValueName,
|
RtlInitUnicodeString (&ControlSetValueName,
|
||||||
L"SymbolicLinkValue");
|
L"SymbolicLinkValue");
|
||||||
Status = ZwSetValueKey (KeyHandle,
|
Status = ZwSetValueKey (KeyHandle,
|
||||||
&ControlSetValueName,
|
&ControlSetValueName,
|
||||||
|
@ -1008,7 +1008,7 @@ CmiInitHives(BOOLEAN SetupBoot)
|
||||||
|
|
||||||
if (SetupBoot == TRUE)
|
if (SetupBoot == TRUE)
|
||||||
{
|
{
|
||||||
RtlRosInitUnicodeStringFromLiteral(&KeyName,
|
RtlInitUnicodeString(&KeyName,
|
||||||
L"\\Registry\\Machine\\HARDWARE");
|
L"\\Registry\\Machine\\HARDWARE");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
|
@ -1024,7 +1024,7 @@ CmiInitHives(BOOLEAN SetupBoot)
|
||||||
return(Status);
|
return(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlRosInitUnicodeStringFromLiteral(&ValueName,
|
RtlInitUnicodeString(&ValueName,
|
||||||
L"InstallPath");
|
L"InstallPath");
|
||||||
|
|
||||||
BufferSize = sizeof(KEY_VALUE_PARTIAL_INFORMATION) + 4096;
|
BufferSize = sizeof(KEY_VALUE_PARTIAL_INFORMATION) + 4096;
|
||||||
|
|
|
@ -674,7 +674,7 @@ CmiGetLinkTarget(PREGISTRY_HIVE RegistryHive,
|
||||||
PKEY_CELL KeyCell,
|
PKEY_CELL KeyCell,
|
||||||
PUNICODE_STRING TargetPath)
|
PUNICODE_STRING TargetPath)
|
||||||
{
|
{
|
||||||
UNICODE_STRING LinkName = ROS_STRING_INITIALIZER(L"SymbolicLinkValue");
|
UNICODE_STRING LinkName = RTL_CONSTANT_STRING(L"SymbolicLinkValue");
|
||||||
PVALUE_CELL ValueCell;
|
PVALUE_CELL ValueCell;
|
||||||
PDATA_CELL DataCell;
|
PDATA_CELL DataCell;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
|
@ -65,7 +65,7 @@ ExpInitializeCallbacks(VOID)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Initialize the Object */
|
/* Initialize the Object */
|
||||||
RtlRosInitUnicodeStringFromLiteral(&DirName, L"\\Callback" );
|
RtlInitUnicodeString(&DirName, L"\\Callback" );
|
||||||
InitializeObjectAttributes(
|
InitializeObjectAttributes(
|
||||||
&ObjectAttributes,
|
&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
|
|
|
@ -222,19 +222,6 @@ struct _KEXCEPTION_FRAME;
|
||||||
#define IPI_REQUEST_DPC 2
|
#define IPI_REQUEST_DPC 2
|
||||||
#define IPI_REQUEST_FREEZE 3
|
#define IPI_REQUEST_FREEZE 3
|
||||||
|
|
||||||
#ifndef __USE_W32API
|
|
||||||
typedef enum _KTHREAD_STATE {
|
|
||||||
Initialized,
|
|
||||||
Ready,
|
|
||||||
Running,
|
|
||||||
Standby,
|
|
||||||
Terminated,
|
|
||||||
Waiting,
|
|
||||||
Transition,
|
|
||||||
DeferredReady,
|
|
||||||
} THREAD_STATE, *PTHREAD_STATE;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* MACROS *************************************************************************/
|
/* MACROS *************************************************************************/
|
||||||
|
|
||||||
#define KeEnterCriticalRegion(X) \
|
#define KeEnterCriticalRegion(X) \
|
||||||
|
|
|
@ -55,6 +55,13 @@ BOOLEAN CmImportSystemHive(PCHAR ChunkBase, ULONG ChunkSize);
|
||||||
BOOLEAN CmImportHardwareHive(PCHAR ChunkBase, ULONG ChunkSize);
|
BOOLEAN CmImportHardwareHive(PCHAR ChunkBase, ULONG ChunkSize);
|
||||||
VOID KdInitSystem(ULONG Reserved, PLOADER_PARAMETER_BLOCK LoaderBlock);
|
VOID KdInitSystem(ULONG Reserved, PLOADER_PARAMETER_BLOCK LoaderBlock);
|
||||||
|
|
||||||
|
BOOLEAN
|
||||||
|
FASTCALL
|
||||||
|
RtlpCreateUnicodeString(
|
||||||
|
IN OUT PUNICODE_STRING UniDest,
|
||||||
|
IN PCWSTR Source,
|
||||||
|
IN POOL_TYPE PoolType);
|
||||||
|
|
||||||
#endif /* __ASM__ */
|
#endif /* __ASM__ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -74,4 +74,7 @@
|
||||||
#include <napi/teb.h>
|
#include <napi/teb.h>
|
||||||
#include <napi/win32.h>
|
#include <napi/win32.h>
|
||||||
|
|
||||||
|
|
||||||
|
#define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) + ((D)<<24))
|
||||||
|
|
||||||
#endif /* INCLUDE_NTOSKRNL_H */
|
#endif /* INCLUDE_NTOSKRNL_H */
|
||||||
|
|
|
@ -62,6 +62,7 @@ KeAcquireInterruptSpinLock(
|
||||||
{
|
{
|
||||||
KIRQL oldIrql;
|
KIRQL oldIrql;
|
||||||
|
|
||||||
|
//KeRaiseIrql(Interrupt->SynchronizeIrql, &oldIrql);
|
||||||
KeRaiseIrql(Interrupt->SynchLevel, &oldIrql);
|
KeRaiseIrql(Interrupt->SynchLevel, &oldIrql);
|
||||||
KiAcquireSpinLock(Interrupt->ActualLock);
|
KiAcquireSpinLock(Interrupt->ActualLock);
|
||||||
return oldIrql;
|
return oldIrql;
|
||||||
|
|
Loading…
Reference in a new issue