mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
Compilation fixes
svn path=/trunk/; revision=1225
This commit is contained in:
parent
d351d182ef
commit
f801003a51
13 changed files with 46 additions and 129 deletions
|
@ -1,4 +1,4 @@
|
|||
/* $Id: halddk.h,v 1.3 2000/07/01 18:20:41 ekohl Exp $
|
||||
/* $Id: halddk.h,v 1.4 2000/07/04 11:11:03 dwelch Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -456,13 +456,6 @@ HalGetInterruptVector (
|
|||
PKAFFINITY Affinity
|
||||
);
|
||||
|
||||
BOOLEAN
|
||||
STDCALL
|
||||
HalInitSystem (
|
||||
ULONG BootPhase,
|
||||
PLOADER_PARAMETER_BLOCK LoaderBlock
|
||||
);
|
||||
|
||||
VOID
|
||||
STDCALL
|
||||
HalInitializeProcessor (
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
|
||||
/* KERNEL FUNCTIONS ********************************************************/
|
||||
|
||||
#define KeFlushIoBuffers(Mdl, ReadOperation, DmaOperation)
|
||||
|
||||
VOID STDCALL KeAttachProcess (struct _EPROCESS* Process);
|
||||
|
||||
VOID KeDrainApcQueue(VOID);
|
||||
|
@ -60,8 +62,6 @@ VOID STDCALL KeDetachProcess (VOID);
|
|||
|
||||
VOID STDCALL KeEnterCriticalRegion (VOID);
|
||||
|
||||
VOID KeFlushIoBuffers(PMDL Mdl, BOOLEAN ReadOperation, BOOLEAN DmaOperation);
|
||||
|
||||
KIRQL STDCALL KeGetCurrentIrql (VOID);
|
||||
|
||||
ULONG KeGetCurrentProcessorNumber(VOID);
|
||||
|
@ -406,7 +406,6 @@ NTSTATUS KeI386ReleaseGdtSelectors(OUT PULONG SelArray,
|
|||
NTSTATUS KeI386AllocateGdtSelectors(OUT PULONG SelArray,
|
||||
IN ULONG NumOfSelectors);
|
||||
|
||||
<<<<<<< kefuncs.h
|
||||
/*
|
||||
* FUNCTION: Raises a user mode exception
|
||||
* ARGUMENTS:
|
||||
|
|
|
@ -42,7 +42,7 @@ typedef struct _LOADER_PARAMETER_BLOCK
|
|||
|
||||
#ifdef __NTOSKRNL__
|
||||
extern CHAR EXPORTED KeNumberProcessors;
|
||||
extern LOADER_PARAMETER_BLOCK EXPORTED KeLoaderBlock;
|
||||
extern LOADER_PARAMETER_BLOCK KeLoaderBlock;
|
||||
#else
|
||||
extern CHAR IMPORTED KeNumberProcessors;
|
||||
extern LOADER_PARAMETER_BLOCK IMPORTED KeLoaderBlock;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: psfuncs.h,v 1.9 2000/07/04 08:52:34 dwelch Exp $
|
||||
/* $Id: psfuncs.h,v 1.10 2000/07/04 11:11:03 dwelch Exp $
|
||||
*/
|
||||
#ifndef _INCLUDE_DDK_PSFUNCS_H
|
||||
#define _INCLUDE_DDK_PSFUNCS_H
|
||||
|
@ -10,12 +10,8 @@ PACCESS_TOKEN PsReferenceEffectiveToken(struct _ETHREAD* Thread,
|
|||
|
||||
NTSTATUS PsOpenTokenOfProcess(HANDLE ProcessHandle,
|
||||
PACCESS_TOKEN* Token);
|
||||
NTSTATUS
|
||||
STDCALL
|
||||
PsAssignImpersonationToken (
|
||||
PETHREAD Thread,
|
||||
HANDLE TokenHandle
|
||||
);
|
||||
NTSTATUS STDCALL PsAssignImpersonationToken (struct _ETHREAD* Thread,
|
||||
HANDLE TokenHandle);
|
||||
|
||||
HANDLE STDCALL PsGetCurrentProcessId(VOID);
|
||||
HANDLE STDCALL PsGetCurrentThreadId(VOID);
|
||||
|
@ -51,7 +47,7 @@ ULONG PsSuspendThread(struct _ETHREAD* Thread,
|
|||
ULONG PsResumeThread(struct _ETHREAD* Thread,
|
||||
PNTSTATUS WaitStatus);
|
||||
struct _ETHREAD* PsGetCurrentThread(VOID);
|
||||
struct _EPROCESS* PsGetCurrentProcess(VOID);
|
||||
struct _EPROCESS* STDCALL PsGetCurrentProcess(VOID);
|
||||
PACCESS_TOKEN STDCALL PsReferenceImpersonationToken(struct _ETHREAD* Thread,
|
||||
PULONG Unknown1,
|
||||
PULONG Unknown2,
|
||||
|
|
|
@ -702,45 +702,6 @@
|
|||
#define STATUS_CONFLICTING_ADDRESS (0xC1000005)
|
||||
#define STATUS_NO_MEDIA_IN_DRIVE (0xC1000006)
|
||||
|
||||
#ifndef __ASM__
|
||||
enum
|
||||
{
|
||||
RPC_NT_INVALID_STRING_BINDING=0xC0020001,
|
||||
RPC_NT_WRONG_KIND_OF_BINDING,
|
||||
RPC_NT_INVALID_BINDING,
|
||||
RPC_NT_PROTSEQ_NOT_SUPPORTED,
|
||||
RPC_NT_INVALID_RPC_PROTSEQ,
|
||||
RPC_NT_INVALID_STRING_UUID,
|
||||
RPC_NT_INVALID_ENDPOINT_FORMAT,
|
||||
RPC_NT_INVALID_NET_ADDR,
|
||||
RPC_NT_NO_ENDPOINT_FOUND,
|
||||
RPC_NT_INVALID_TIMEOUT,
|
||||
RPC_NT_OBJECT_NOT_FOUND,
|
||||
RPC_NT_ALREADY_REGISTERED,
|
||||
RPC_NT_TYPE_ALREADY_REGISTERED,
|
||||
RPC_NT_ALREADY_LISTENING,
|
||||
RPC_NT_NO_PROTSEQS_REGISTERED,
|
||||
RPC_NT_NOT_LISTENING,
|
||||
RPC_NT_UNKNOWN_MGR_TYPE,
|
||||
RPC_NT_UNKNOWN_IF,
|
||||
RPC_NT_NO_BINDINGS,
|
||||
RPC_NT_NO_PROTSEQS,
|
||||
RPC_NT_CANT_CREATE_ENDPOINT,
|
||||
RPC_NT_OUT_OF_RESOURCES,
|
||||
RPC_NT_SERVER_UNAVAILABLE,
|
||||
RPC_NT_SERVER_TOO_BUSY,
|
||||
RPC_NT_INVALID_NETWORK_OPTIONS,
|
||||
RPC_NT_NO_CALL_ACTIVE,
|
||||
RPC_NT_CALL_FAILED,
|
||||
RPC_NT_CALL_FAILED_DNE,
|
||||
RPC_NT_PROTOCOL_ERROR,
|
||||
|
||||
|
||||
RPC_NT_SS_IN_NULL_CONTEXT=0xC0030004,
|
||||
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif /* __INCLUDE_DDK_STATUS_H */
|
||||
|
||||
|
||||
|
|
|
@ -7,4 +7,7 @@
|
|||
#error "Unknown processor"
|
||||
#endif
|
||||
|
||||
BOOLEAN STDCALL HalInitSystem (ULONG BootPhase,
|
||||
PLOADER_PARAMETER_BLOCK LoaderBlock);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -238,7 +238,7 @@ VOID MmDereserveSwapPages(ULONG Nr);
|
|||
SWAPENTRY MmAllocSwapPage(VOID);
|
||||
VOID MmFreeSwapPage(SWAPENTRY Entry);
|
||||
|
||||
VOID MmInit1(boot_param* bp, ULONG LastKernelAddress);
|
||||
VOID MmInit1(PLOADER_PARAMETER_BLOCK bp, ULONG LastKernelAddress);
|
||||
VOID MmInit2(VOID);
|
||||
VOID MmInit3(VOID);
|
||||
NTSTATUS MmInitPagerThread(VOID);
|
||||
|
|
|
@ -19,23 +19,15 @@
|
|||
|
||||
/* FUNCTIONS ****************************************************************/
|
||||
|
||||
VOID
|
||||
STDCALL
|
||||
KeClearEvent (
|
||||
PKEVENT Event
|
||||
)
|
||||
VOID STDCALL KeClearEvent (PKEVENT Event)
|
||||
{
|
||||
DPRINT("KeClearEvent(Event %x)\n", Event);
|
||||
Event->Header.SignalState=FALSE;
|
||||
}
|
||||
|
||||
VOID
|
||||
STDCALL
|
||||
KeInitializeEvent (
|
||||
PKEVENT Event,
|
||||
EVENT_TYPE Type,
|
||||
BOOLEAN State
|
||||
)
|
||||
VOID STDCALL KeInitializeEvent (PKEVENT Event,
|
||||
EVENT_TYPE Type,
|
||||
BOOLEAN State)
|
||||
{
|
||||
ULONG IType;
|
||||
|
||||
|
@ -59,31 +51,19 @@ KeInitializeEvent (
|
|||
InitializeListHead(&(Event->Header.WaitListHead));
|
||||
}
|
||||
|
||||
LONG
|
||||
STDCALL
|
||||
KeReadStateEvent (
|
||||
PKEVENT Event
|
||||
)
|
||||
LONG STDCALL KeReadStateEvent (PKEVENT Event)
|
||||
{
|
||||
return(Event->Header.SignalState);
|
||||
}
|
||||
|
||||
LONG
|
||||
STDCALL
|
||||
KeResetEvent (
|
||||
PKEVENT Event
|
||||
)
|
||||
LONG STDCALL KeResetEvent (PKEVENT Event)
|
||||
{
|
||||
return(InterlockedExchange(&(Event->Header.SignalState),0));
|
||||
}
|
||||
|
||||
LONG
|
||||
STDCALL
|
||||
KeSetEvent (
|
||||
PKEVENT Event,
|
||||
KPRIORITY Increment,
|
||||
BOOLEAN Wait
|
||||
)
|
||||
LONG STDCALL KeSetEvent (PKEVENT Event,
|
||||
KPRIORITY Increment,
|
||||
BOOLEAN Wait)
|
||||
{
|
||||
int ret;
|
||||
|
||||
|
@ -95,13 +75,9 @@ KeSetEvent (
|
|||
return(ret);
|
||||
}
|
||||
|
||||
NTSTATUS
|
||||
STDCALL
|
||||
KePulseEvent (
|
||||
PKEVENT Event,
|
||||
KPRIORITY Increment,
|
||||
BOOLEAN Wait
|
||||
)
|
||||
LONG STDCALL KePulseEvent (PKEVENT Event,
|
||||
KPRIORITY Increment,
|
||||
BOOLEAN Wait)
|
||||
{
|
||||
int ret;
|
||||
|
||||
|
@ -111,7 +87,7 @@ KePulseEvent (
|
|||
KeDispatcherObjectWake((DISPATCHER_HEADER *)Event);
|
||||
InterlockedExchange(&(Event->Header.SignalState),0);
|
||||
KeReleaseDispatcherDatabaseLock(Wait);
|
||||
return((NTSTATUS)ret);
|
||||
return(ret);
|
||||
}
|
||||
|
||||
/* EOF */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: main.c,v 1.51 2000/07/04 08:52:39 dwelch Exp $
|
||||
/* $Id: main.c,v 1.52 2000/07/04 11:11:03 dwelch Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -21,6 +21,7 @@
|
|||
#include <internal/ldr.h>
|
||||
#include <internal/ex.h>
|
||||
#include <internal/ps.h>
|
||||
#include <internal/hal.h>
|
||||
|
||||
#include <internal/mmhal.h>
|
||||
#include <internal/i386/segment.h>
|
||||
|
@ -33,7 +34,7 @@
|
|||
ULONG EXPORTED NtBuildNumber = KERNEL_VERSION_BUILD;
|
||||
ULONG EXPORTED NtGlobalFlag = 0;
|
||||
CHAR EXPORTED KeNumberProcessors = 1;
|
||||
LOADER_PARAMETER_BLOCK EXPORTED KeLoaderBlock;
|
||||
LOADER_PARAMETER_BLOCK KeLoaderBlock;
|
||||
|
||||
/* FUNCTIONS ****************************************************************/
|
||||
|
||||
|
@ -68,17 +69,14 @@ void _main (PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
/*
|
||||
* Copy the parameters to a local buffer because lowmem will go away
|
||||
*/
|
||||
memcpy (&KeLoaderBlock,
|
||||
LoaderBlock,
|
||||
sizeof(LOADER_PARAMETER_BLOCK));
|
||||
memcpy (&KeLoaderBlock, LoaderBlock, sizeof(LOADER_PARAMETER_BLOCK));
|
||||
|
||||
/*
|
||||
* FIXME: Preliminary hack!!!!
|
||||
* Initializes the kernel parameter line.
|
||||
* This should be done by the boot loader.
|
||||
*/
|
||||
strcpy (KeLoaderBlock.kernel_parameters,
|
||||
"/DEBUGPORT=SCREEN");
|
||||
strcpy (KeLoaderBlock.kernel_parameters, "/DEBUGPORT=SCREEN");
|
||||
|
||||
/*
|
||||
* Initialization phase 0
|
||||
|
@ -88,7 +86,7 @@ void _main (PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
HalDisplayString("Starting ReactOS "KERNEL_VERSION_STR" (Build "KERNEL_VERSION_BUILD_STR")\n");
|
||||
|
||||
last_kernel_address = KERNEL_BASE;
|
||||
for (i=0; i<=KeLoaderBlock.nr_files; i++)
|
||||
for (i=0; i <= KeLoaderBlock.nr_files; i++)
|
||||
{
|
||||
last_kernel_address = last_kernel_address +
|
||||
PAGE_ROUND_UP(KeLoaderBlock.module_length[i]);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: mminit.c,v 1.1 2000/07/04 08:52:42 dwelch Exp $
|
||||
/* $Id: mminit.c,v 1.2 2000/07/04 11:11:04 dwelch Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -69,7 +69,7 @@ VOID MiShutdownMemoryManager(VOID)
|
|||
{
|
||||
}
|
||||
|
||||
VOID MmInitVirtualMemory(boot_param* bp, ULONG LastKernelAddress)
|
||||
VOID MmInitVirtualMemory(PLOADER_PARAMETER_BLOCK bp, ULONG LastKernelAddress)
|
||||
/*
|
||||
* FUNCTION: Intialize the memory areas list
|
||||
* ARGUMENTS:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: process.c,v 1.48 2000/07/04 08:52:47 dwelch Exp $
|
||||
/* $Id: process.c,v 1.49 2000/07/04 11:11:04 dwelch Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -289,11 +289,7 @@ HANDLE STDCALL PsGetCurrentProcessId(VOID)
|
|||
/*
|
||||
* FUNCTION: Returns a pointer to the current process
|
||||
*/
|
||||
PEPROCESS
|
||||
STDCALL
|
||||
IoGetCurrentProcess (
|
||||
VOID
|
||||
)
|
||||
PEPROCESS STDCALL PsGetCurrentProcess(VOID)
|
||||
{
|
||||
if (PsGetCurrentThread() == NULL ||
|
||||
PsGetCurrentThread()->ThreadsProcess == NULL)
|
||||
|
@ -306,6 +302,11 @@ IoGetCurrentProcess (
|
|||
}
|
||||
}
|
||||
|
||||
PEPROCESS STDCALL IoGetCurrentProcess(VOID)
|
||||
{
|
||||
return(PsGetCurrentProcess());
|
||||
}
|
||||
|
||||
NTSTATUS STDCALL NtCreateProcess (OUT PHANDLE ProcessHandle,
|
||||
IN ACCESS_MASK DesiredAccess,
|
||||
IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: thread.c,v 1.50 2000/07/01 22:37:28 ekohl Exp $
|
||||
/* $Id: thread.c,v 1.51 2000/07/04 11:11:04 dwelch Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -106,29 +106,20 @@ VOID PsUnfreezeProcessThreads(PEPROCESS Process)
|
|||
KeReleaseSpinLock(&PiThreadListLock, oldIrql);
|
||||
}
|
||||
|
||||
PKTHREAD
|
||||
STDCALL
|
||||
KeGetCurrentThread (
|
||||
VOID
|
||||
)
|
||||
PKTHREAD STDCALL KeGetCurrentThread(VOID)
|
||||
{
|
||||
return(&(CurrentThread->Tcb));
|
||||
}
|
||||
|
||||
/*
|
||||
PETHREAD PsGetCurrentThread(VOID)
|
||||
{
|
||||
return(CurrentThread);
|
||||
}
|
||||
*/
|
||||
|
||||
HANDLE
|
||||
STDCALL
|
||||
PsGetCurrentThreadId (
|
||||
VOID
|
||||
)
|
||||
|
||||
HANDLE STDCALL PsGetCurrentThreadId(VOID)
|
||||
{
|
||||
return(CurrentThread->Cid.UniqueThread);
|
||||
return(PsGetCurrentThread()->Cid.UniqueThread);
|
||||
}
|
||||
|
||||
static VOID PsInsertIntoThreadList(KPRIORITY Priority, PETHREAD Thread)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: process.c,v 1.9 2000/05/26 05:40:20 phreak Exp $
|
||||
/* $Id: process.c,v 1.10 2000/07/04 11:11:06 dwelch Exp $
|
||||
*
|
||||
* reactos/subsys/csrss/api/process.c
|
||||
*
|
||||
|
@ -122,7 +122,6 @@ NTSTATUS CsrCreateProcess (PCSRSS_PROCESS_DATA ProcessData,
|
|||
Reply->Header.MessageSize = sizeof(CSRSS_API_REPLY);
|
||||
|
||||
NewProcessData = CsrGetProcessData(Request->Data.CreateProcessRequest.NewProcessId);
|
||||
DbgPrint( "CreateProcess\n" );
|
||||
if (NewProcessData == NULL)
|
||||
{
|
||||
Reply->Status = STATUS_NO_MEMORY;
|
||||
|
|
Loading…
Reference in a new issue