Fixed prototype for MmSetAddressRangeModified().
[reactos.git] / ntoskrnl / ps / psmgr.c
1 /* $Id$
2  *
3  * COPYRIGHT:               See COPYING in the top level directory
4  * PROJECT:                 ReactOS kernel
5  * FILE:                    ntoskrnl/ps/psmgr.c
6  * PURPOSE:                 Process management
7  * PROGRAMMER:              David Welch (welch@mcmail.com)
8  */
9
10 /* INCLUDES **************************************************************/
11
12 #include <ddk/ntddk.h>
13 #include <internal/ke.h>
14 #include <internal/ps.h>
15 #include <reactos/version.h>
16
17 #define NDEBUG
18 #include <internal/debug.h>
19
20 /* FUNCTIONS ***************************************************************/
21
22 #ifndef LIBCAPTIVE
23 VOID PiShutdownProcessManager(VOID)
24 {
25    DPRINT("PiShutdownMemoryManager()\n");
26    
27    PiKillMostProcesses();
28 }
29
30 VOID PiInitProcessManager(VOID)
31 {
32    PsInitProcessManagment();
33    PsInitThreadManagment();
34    PsInitIdleThread();
35    PiInitApcManagement();
36    PsInitialiseSuspendImplementation();
37    PsInitialiseW32Call();
38 }
39 #endif /* LIBCAPTIVE */
40
41
42 /**********************************************************************
43  * NAME                                                 EXPORTED
44  *      PsGetVersion
45  *
46  * DESCRIPTION
47  *      Retrieves the current OS version.
48  *
49  * ARGUMENTS
50  *      MajorVersion    Pointer to a variable that will be set to the
51  *                      major version of the OS. Can be NULL.
52  *
53  *      MinorVersion    Pointer to a variable that will be set to the
54  *                      minor version of the OS. Can be NULL.
55  *
56  *      BuildNumber     Pointer to a variable that will be set to the
57  *                      build number of the OS. Can be NULL.
58  *
59  *      CSDVersion      Pointer to a variable that will be set to the
60  *                      CSD string of the OS. Can be NULL.
61  *
62  * RETURN VALUE
63  *      TRUE    OS is a checked build.
64  *      FALSE   OS is a free build.
65  *
66  * NOTES
67  *      The DDK docs say something about a 'CmCSDVersionString'.
68  *      How do we determine in the build is checked or free??
69  *
70  * @unimplemented
71  */
72
73 BOOLEAN
74 STDCALL
75 PsGetVersion (
76         PULONG          MajorVersion    OPTIONAL,
77         PULONG          MinorVersion    OPTIONAL,
78         PULONG          BuildNumber     OPTIONAL,
79         PUNICODE_STRING CSDVersion      OPTIONAL
80         )
81 {
82         if (MajorVersion)
83                 *MajorVersion = KERNEL_VERSION_MAJOR;
84
85         if (MinorVersion)
86                 *MinorVersion = KERNEL_VERSION_MINOR;
87
88 #ifndef LIBCAPTIVE
89         if (BuildNumber)
90                 *BuildNumber = NtBuildNumber;
91 #endif /* LIBCAPTIVE */
92
93         if (CSDVersion)
94         {
95                 CSDVersion->Length = 0;
96                 CSDVersion->MaximumLength = 0;
97                 CSDVersion->Buffer = NULL;
98 #if 0
99                 CSDVersion->Length = CmCSDVersionString.Length;
100                 CSDVersion->MaximumLength = CmCSDVersionString.Maximum;
101                 CSDVersion->Buffer = CmCSDVersionString.Buffer;
102 #endif
103         }
104
105         /* FIXME: How do we determine if build is checked or free? */
106         return FALSE;
107 }
108
109 /* EOF */