ReactOS 0.4.16-dev-2610-ge2c92c0
bootmgr.c File Reference
#include <freeldr.h>
#include <debug.h>
Include dependency graph for bootmgr.c:

Go to the source code of this file.

Classes

struct  _OS_LOADING_METHOD
 

Typedefs

typedef VOID(* EDIT_OS_ENTRY_PROC) (_Inout_ OperatingSystemItem *OperatingSystem)
 
typedef VOID(* OS_MENU_PROC) (_Inout_ OperatingSystemItem *OperatingSystem)
 
typedef struct _OS_LOADING_METHOD OS_LOADING_METHOD
 
typedef struct _OS_LOADING_METHODPOS_LOADING_METHOD
 

Functions

 DBG_DEFAULT_CHANNEL (WARNING)
 
static VOID EditCustomBootReactOSSetup (_Inout_ OperatingSystemItem *OperatingSystem)
 
static VOID EditCustomBootNTOS (_Inout_ OperatingSystemItem *OperatingSystem)
 
static const OS_LOADING_METHODGetOSLoadingMethod (_In_ ULONG_PTR SectionId)
 
static PCHARBuildArgvForOsLoader (_In_ PCSTR LoadIdentifier, _In_ ULONG_PTR SectionId, _Out_ PULONG pArgc)
 This function converts the list of Key=Value options in the given operating system section into an ARC-compatible argument vector, providing in addition the extra mandatory Software Loading Environment Variables, following the ARC specification.
 
VOID LoadOperatingSystem (_In_ OperatingSystemItem *OperatingSystem)
 
BOOLEAN MainBootMenuKeyPressFilter (IN ULONG KeyPress, IN ULONG SelectedMenuItem, IN PVOID Context OPTIONAL)
 
VOID RunLoader (VOID)
 

Variables

static const OS_LOADING_METHOD OSLoadingMethods []
 

Typedef Documentation

◆ EDIT_OS_ENTRY_PROC

typedef VOID(* EDIT_OS_ENTRY_PROC) (_Inout_ OperatingSystemItem *OperatingSystem)

Definition at line 29 of file bootmgr.c.

◆ OS_LOADING_METHOD

◆ OS_MENU_PROC

typedef VOID(* OS_MENU_PROC) (_Inout_ OperatingSystemItem *OperatingSystem)

Definition at line 33 of file bootmgr.c.

◆ POS_LOADING_METHOD

Function Documentation

◆ BuildArgvForOsLoader()

static PCHAR * BuildArgvForOsLoader ( _In_ PCSTR  LoadIdentifier,
_In_ ULONG_PTR  SectionId,
_Out_ PULONG  pArgc 
)
static

This function converts the list of Key=Value options in the given operating system section into an ARC-compatible argument vector, providing in addition the extra mandatory Software Loading Environment Variables, following the ARC specification.

Definition at line 178 of file bootmgr.c.

182{
183 SIZE_T Size;
184 ULONG Count;
185 ULONG i;
186 ULONG Argc;
187 PCHAR* Argv;
188 PCHAR* Args;
189 PCHAR SettingName, SettingValue;
190 PCCHAR BootPath = FrLdrGetBootPath();
191
192 *pArgc = 0;
193
194 ASSERT(SectionId != 0);
195
196 /* Normalize LoadIdentifier to make subsequent tests simpler */
197 if (LoadIdentifier && !*LoadIdentifier)
198 LoadIdentifier = NULL;
199
200 /* Count the number of operating systems in the section */
201 Count = IniGetNumSectionItems(SectionId);
202
203 /*
204 * The argument vector contains the program name, the SystemPartition,
205 * the LoadIdentifier (optional), and the items in the OS section.
206 * For POSIX compliance, a terminating NULL pointer (not counted in Argc)
207 * is appended, such that Argv[Argc] == NULL.
208 */
209 Argc = 2 + (LoadIdentifier ? 1 : 0) + Count;
210
211 /* Calculate the total size needed for the string buffer of the argument vector */
212 Size = 0;
213 /* i == 0: Program name */
214 // TODO: Provide one in the future...
215 /* i == 1: SystemPartition : from where FreeLdr has been started */
216 Size += (strlen("SystemPartition=") + strlen(BootPath) + 1) * sizeof(CHAR);
217 /* i == 2: LoadIdentifier : ASCII string that may be used
218 * to associate an identifier with a set of load parameters */
219 if (LoadIdentifier)
220 {
221 Size += (strlen("LoadIdentifier=") + strlen(LoadIdentifier) + 1) * sizeof(CHAR);
222 }
223 /* The section items */
224 for (i = 0; i < Count; ++i)
225 {
226 Size += IniGetSectionSettingNameSize(SectionId, i); // Counts also the NULL-terminator, that we transform into the '=' sign separator.
227 Size += IniGetSectionSettingValueSize(SectionId, i); // Counts also the NULL-terminator.
228 }
229 Size += sizeof(ANSI_NULL); // Final NULL-terminator.
230
231 /* Allocate memory to hold the argument vector: pointers and string buffer */
232 Argv = FrLdrHeapAlloc((Argc + 1) * sizeof(PCHAR) + Size, TAG_STRING);
233 if (!Argv)
234 return NULL;
235
236 /* Initialize the argument vector: loop through the section and copy the Key=Value options */
237 SettingName = (PCHAR)((ULONG_PTR)Argv + ((Argc + 1) * sizeof(PCHAR)));
238 Args = Argv;
239 /* i == 0: Program name */
240 *Args++ = NULL; // TODO: Provide one in the future...
241 /* i == 1: SystemPartition */
242 {
243 strcpy(SettingName, "SystemPartition=");
244 strcat(SettingName, BootPath);
245
246 *Args++ = SettingName;
247 SettingName += (strlen(SettingName) + 1);
248 }
249 /* i == 2: LoadIdentifier */
250 if (LoadIdentifier)
251 {
252 strcpy(SettingName, "LoadIdentifier=");
253 strcat(SettingName, LoadIdentifier);
254
255 *Args++ = SettingName;
256 SettingName += (strlen(SettingName) + 1);
257 }
258 /* The section items */
259 for (i = 0; i < Count; ++i)
260 {
261 Size = IniGetSectionSettingNameSize(SectionId, i);
262 SettingValue = SettingName + Size;
263 IniReadSettingByNumber(SectionId, i,
264 SettingName, Size,
265 SettingValue, IniGetSectionSettingValueSize(SectionId, i));
266 SettingName[Size - 1] = '=';
267
268 *Args++ = SettingName;
269 SettingName += (strlen(SettingName) + 1);
270 }
271 /* Terminating NULL pointer */
272 *Args = NULL;
273
274#if DBG
275 /* Dump the argument vector for debugging */
276 for (i = 0; i < Argc; ++i)
277 {
278 TRACE("Argv[%lu]: '%s'\n", i, Argv[i]);
279 }
280#endif
281
282 *pArgc = Argc;
283 return Argv;
284}
char ** Args
Definition: acdebug.h:353
PVOID FrLdrHeapAlloc(SIZE_T MemorySize, ULONG Tag)
Definition: heap.c:533
#define NULL
Definition: types.h:112
_ACRTIMP size_t __cdecl strlen(const char *)
Definition: string.c:1592
PCCHAR FrLdrGetBootPath(VOID)
Definition: freeldr.c:197
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
ULONG IniGetSectionSettingValueSize(ULONG_PTR SectionId, ULONG SettingIndex)
Definition: inifile.c:108
ULONG IniGetNumSectionItems(ULONG_PTR SectionId)
Definition: inifile.c:60
ULONG IniGetSectionSettingNameSize(ULONG_PTR SectionId, ULONG SettingIndex)
Definition: inifile.c:95
BOOLEAN IniReadSettingByNumber(ULONG_PTR SectionId, ULONG SettingNumber, PCHAR SettingName, ULONG NameSize, PCHAR SettingValue, ULONG ValueSize)
Definition: inifile.c:121
#define PCHAR
Definition: match.c:90
#define ASSERT(a)
Definition: mode.c:44
int Count
Definition: noreturn.cpp:7
#define ANSI_NULL
#define TAG_STRING
Definition: oslist.h:22
char CHAR
Definition: pedump.c:57
strcat
Definition: string.h:92
strcpy
Definition: string.h:131
#define TRACE(s)
Definition: solgame.cpp:4
ULONG_PTR SIZE_T
Definition: typedefs.h:80
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
char * PCHAR
Definition: typedefs.h:51
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
Definition: wdfdevice.h:4539

Referenced by LoadOperatingSystem().

◆ DBG_DEFAULT_CHANNEL()

DBG_DEFAULT_CHANNEL ( WARNING  )

◆ EditCustomBootNTOS()

static VOID EditCustomBootNTOS ( _Inout_ OperatingSystemItem OperatingSystem)
static

Definition at line 45 of file bootmgr.c.

47{
48 EditCustomBootReactOS(OperatingSystem, FALSE);
49}
VOID EditCustomBootReactOS(IN OUT OperatingSystemItem *OperatingSystem, IN BOOLEAN IsSetup)
Definition: custom.c:485
#define FALSE
Definition: types.h:117

◆ EditCustomBootReactOSSetup()

static VOID EditCustomBootReactOSSetup ( _Inout_ OperatingSystemItem OperatingSystem)
static

Definition at line 38 of file bootmgr.c.

40{
41 EditCustomBootReactOS(OperatingSystem, TRUE);
42}
#define TRUE
Definition: types.h:120

◆ GetOSLoadingMethod()

static const OS_LOADING_METHOD * GetOSLoadingMethod ( _In_ ULONG_PTR  SectionId)
static

Definition at line 112 of file bootmgr.c.

114{
115 ULONG i;
116 CHAR BootType[80];
117
118 /* The operating system section has been opened by InitOperatingSystemList() */
119 ASSERT(SectionId != 0);
120
121 /* Try to read the boot type. We must have the value (it
122 * has been possibly added by InitOperatingSystemList()) */
123 *BootType = ANSI_NULL;
124 IniReadSettingByName(SectionId, "BootType", BootType, sizeof(BootType));
125 ASSERT(*BootType);
126
128#ifdef HAS_DEPRECATED_OPTIONS
129 if ((_stricmp(BootType, "Drive") == 0) ||
130 (_stricmp(BootType, "Partition") == 0))
131 {
132 /* Display the deprecation warning message */
134 "The '%s' configuration you are booting into is no longer\n"
135 "supported and will be removed in future FreeLoader versions.\n"
136 "\n"
137 "Please edit FREELDR.INI to replace all occurrences of\n"
138 "\n"
139 " %*s to:\n"
140 " BootType=%s ------> BootType=BootSector",
141 BootType,
142 strlen(BootType), "", // Indentation
143 BootType);
144
145 /* Type fixup */
146 strcpy(BootType, "BootSector");
147 if (!IniModifySettingValue(SectionId, "BootType", BootType))
148 {
149 ERR("Could not fixup the BootType entry for OS '%s', ignoring.\n",
150 ((PINI_SECTION)SectionId)->SectionName);
151 }
152 }
153#endif // HAS_DEPRECATED_OPTIONS
155
156 /* Find the suitable OS loading method */
157 for (i = 0; ; ++i)
158 {
160 {
161 UiMessageBox("Unknown boot entry type '%s'", BootType);
162 return NULL;
163 }
164 if (_stricmp(BootType, OSLoadingMethods[i].BootType) == 0)
165 return &OSLoadingMethods[i];
166 }
168}
#define RTL_NUMBER_OF(x)
Definition: RtlRegistry.c:12
#define ERR(fmt,...)
Definition: precomp.h:57
VOID UiMessageBox(_In_ PCSTR Format,...)
Definition: ui.c:359
static const OS_LOADING_METHOD OSLoadingMethods[]
Definition: bootmgr.c:60
#define _stricmp
Definition: cat.c:22
VOID WarnDeprecated(_In_ PCSTR MsgFmt,...)
BOOLEAN IniModifySettingValue(ULONG_PTR SectionId, PCSTR SettingName, PCSTR SettingValue)
Definition: inifile.c:301
BOOLEAN IniReadSettingByName(ULONG_PTR SectionId, PCSTR SettingName, PCHAR Buffer, ULONG BufferSize)
Definition: inifile.c:154
#define UNREACHABLE

Referenced by LoadOperatingSystem(), and MainBootMenuKeyPressFilter().

◆ LoadOperatingSystem()

VOID LoadOperatingSystem ( _In_ OperatingSystemItem OperatingSystem)

Definition at line 287 of file bootmgr.c.

289{
290 ULONG_PTR SectionId = OperatingSystem->SectionId;
291 const OS_LOADING_METHOD* OSLoadingMethod;
292 ULONG Argc;
293 PCHAR* Argv;
294
295 /* Find the suitable OS loader to start */
296 OSLoadingMethod = GetOSLoadingMethod(SectionId);
297 if (!OSLoadingMethod)
298 return;
299 ASSERT(OSLoadingMethod->OsLoader);
300
301 /* Build the ARC-compatible argument vector */
302 Argv = BuildArgvForOsLoader(OperatingSystem->LoadIdentifier, SectionId, &Argc);
303 if (!Argv)
304 return; // Unexpected failure.
305
306#ifdef _M_IX86
307#ifndef UEFIBOOT
308 /* Install the drive mapper according to this section drive mappings */
309 DriveMapMapDrivesInSection(SectionId);
310#endif
311#endif
312
313 /* Start the OS loader */
314 OSLoadingMethod->OsLoader(Argc, Argv, NULL);
316}
VOID FrLdrHeapFree(PVOID MemoryPointer, ULONG Tag)
Definition: heap.c:539
static PCHAR * BuildArgvForOsLoader(_In_ PCSTR LoadIdentifier, _In_ ULONG_PTR SectionId, _Out_ PULONG pArgc)
This function converts the list of Key=Value options in the given operating system section into an AR...
Definition: bootmgr.c:178
static const OS_LOADING_METHOD * GetOSLoadingMethod(_In_ ULONG_PTR SectionId)
Definition: bootmgr.c:112
ARC_ENTRY_POINT OsLoader
Definition: bootmgr.c:56

Referenced by RunLoader().

◆ MainBootMenuKeyPressFilter()

BOOLEAN MainBootMenuKeyPressFilter ( IN ULONG  KeyPress,
IN ULONG  SelectedMenuItem,
IN PVOID Context  OPTIONAL 
)

Definition at line 335 of file bootmgr.c.

339{
340 OperatingSystemItem* OperatingSystem =
341 &((OperatingSystemItem*)Context)[SelectedMenuItem];
342
343 /* Any key-press cancels the global timeout */
344 GetBootMgrInfo()->TimeOut = -1;
345
346 switch (KeyPress)
347 {
348#if 0
349 /* Help */
350 case KEY_F1:
351 DoHelp();
352 return TRUE;
353#endif
354
355 /* FreeLdr Setup menu */
356 case KEY_F2:
357 FreeLdrSetupMenu(OperatingSystem);
358 return TRUE;
359
360 /* Boot entry-specific advanced boot menu */
361 case KEY_F5:
362 case KEY_F8:
363 {
364 /* Find the suitable OS menu procedure and display it */
365 const OS_LOADING_METHOD* OSLoadingMethod =
366 GetOSLoadingMethod(OperatingSystem->SectionId);
367 if (OSLoadingMethod && OSLoadingMethod->OsMenu)
368 OSLoadingMethod->OsMenu(OperatingSystem);
369 DisplayBootTimeOptions(OperatingSystem); // TODO: Do this also elsewhere
370 return TRUE;
371 }
372
373#ifdef HAS_OPTION_MENU_EDIT_CMDLINE
374 /* Boot entry editor */
375 case KEY_F10:
376 EditOperatingSystemEntry(OperatingSystem);
377 return TRUE;
378#endif
379
380 default:
381 /* We didn't handle the key */
382 return FALSE;
383 }
384}
VOID FreeLdrSetupMenu(_In_opt_ OperatingSystemItem *OperatingSystem)
Definition: options.c:53
VOID DisplayBootTimeOptions(_In_ OperatingSystemItem *OperatingSystem)
Definition: options.c:115
PBOOTMGRINFO GetBootMgrInfo(VOID)
Definition: settings.c:214
#define KEY_F1
Definition: keycodes.h:51
#define KEY_F5
Definition: keycodes.h:55
#define KEY_F8
Definition: keycodes.h:58
#define KEY_F10
Definition: keycodes.h:60
#define KEY_F2
Definition: keycodes.h:52
_In_ PVOID Context
Definition: storport.h:2269
LONG TimeOut
Definition: settings.h:15
ULONG_PTR SectionId
Definition: oslist.h:26

Referenced by RunLoader().

◆ RunLoader()

VOID RunLoader ( VOID  )

Definition at line 386 of file bootmgr.c.

387{
388 OperatingSystemItem* OperatingSystemList;
389 PCSTR* OperatingSystemDisplayNames;
390 ULONG OperatingSystemCount;
391 ULONG SelectedOperatingSystem;
392 ULONG i;
393
394#ifdef _M_IX86
395#ifndef UEFIBOOT
396 /* Load additional SCSI driver (if any) */
398 UiMessageBoxCritical("Unable to load additional boot device drivers.");
399#endif
400#endif
401
402 /* Open FREELDR.INI and load the global FreeLoader settings */
403 if (!IniFileInitialize())
404 UiMessageBoxCritical("Error initializing .ini file.");
406#if 0
407 if (FALSE)
408 UiMessageBoxCritical("Could not load global FreeLoader settings.");
409#endif
410
411 /* Debugger main initialization */
413
414 /* UI main initialization. If it fails, fall back to default UI. */
415 if (!UiInitialize(TRUE))
416 UiMessageBoxCritical("Unable to initialize UI.");
417
418 /* If no FREELDR.INI, skip everything else and fall back to the FreeLdr setup menu */
420 goto Fallback;
421
422 /* Find all the message box settings and run them */
424
425 /* Retrieve the list of boot entries */
426 OperatingSystemList = InitOperatingSystemList(&OperatingSystemCount,
427 &SelectedOperatingSystem);
428 if (!OperatingSystemList)
429 {
430 UiMessageBox("There are no operating systems listed in freeldr.ini.");
431 goto Fallback;
432 }
433 ASSERT(OperatingSystemCount != 0);
434
435 /* Create list of display names */
436 OperatingSystemDisplayNames = FrLdrTempAlloc(sizeof(PCSTR) * OperatingSystemCount, 'mNSO');
437 if (!OperatingSystemDisplayNames)
438 goto Fallback;
439
440 for (i = 0; i < OperatingSystemCount; i++)
441 {
442 OperatingSystemDisplayNames[i] = OperatingSystemList[i].LoadIdentifier;
443 }
444
445 for (;;)
446 {
447 /* Redraw the backdrop, but don't overwrite boot options */
449 DisplayBootTimeOptions(&OperatingSystemList[SelectedOperatingSystem]);
450
451 /* Show the operating system list menu */
452 if (!UiDisplayMenu("Please select the operating system to start:",
453 /* The string is 80 characters long; don't make it longer! */
454 "Press F8 for troubleshooting and advanced startup options."
455 " F2: FreeLdr SETUP",
456 OperatingSystemDisplayNames,
457 OperatingSystemCount,
458 SelectedOperatingSystem,
459 GetBootMgrInfo()->TimeOut,
460 &SelectedOperatingSystem,
461 FALSE,
463 OperatingSystemList))
464 {
465 UiMessageBox("Press ENTER to reboot.");
466 goto Reboot;
467 }
468
469 /* Load the chosen operating system */
470 LoadOperatingSystem(&OperatingSystemList[SelectedOperatingSystem]);
471
472 GetBootMgrInfo()->TimeOut = -1;
473
474 /* If we get there, the OS loader failed. As it may have
475 * messed up the display, re-initialize the UI. */
476#ifndef _M_ARM
477 UiUnInitialize("");
478#endif
480 }
481
483 /* Fall back to the FreeLdr setup menu */
485 UiMessageBox("The system will now reboot.");
486
487Reboot:
488 UiUnInitialize("Rebooting...");
489 IniCleanup();
490 return;
491}
xD9 x84 xD8 xAD xD9 x80 xF0 x90 xAC x9A xE0 xA7 xA6 xE0 xA7 xAA xF0 x91 x84 xA4 xF0 x91 x84 x89 xF0 x91 x84 x9B xF0 x90 x8A xAB xF0 x90 x8B x89 xE2 xB2 x9E xE2 xB2 x9F xD0 xBE xD0 x9E xF0 x90 x90 x84 xF0 x90 x90 xAC xE1 x83 x98 xE1 x83 x94 xE1 x83 x90 xE1 xB2 xBF xE2 xB0 x95 xE2 xB1 x85 xCE xBF xCE x9F xE0 xA8 xA0 xE0 xA8 xB0 xE0 xA9 xA6 Kayah xEA xA4 x8D xEA xA4 x80 Khmer xE1 xA7 xA1 xE1 xA7 xAA xE0 xBB x90 Latin Subscript Fallback
Definition: afscript.h:223
void LoadSettings(void)
Definition: settings.c:53
ULONG LoadBootDeviceDriver(VOID)
Definition: scsiport.c:1656
#define DebugInit(DebugString)
Definition: debug.h:120
PVOID FrLdrTempAlloc(_In_ SIZE_T Size, _In_ ULONG Tag)
Definition: heap.c:545
VOID UiShowMessageBoxesInSection(IN ULONG_PTR SectionId)
Definition: ui.c:524
VOID UiDrawBackdrop(ULONG DrawHeight)
Definition: ui.c:233
VOID UiMessageBoxCritical(_In_ PCSTR MessageText)
Definition: ui.c:372
ULONG UiGetScreenHeight(VOID)
Definition: ui.c:655
VOID UiUnInitialize(PCSTR BootText)
Definition: ui.c:224
BOOLEAN UiDisplayMenu(IN PCSTR MenuHeader, IN PCSTR MenuFooter OPTIONAL, IN PCSTR MenuItemList[], IN ULONG MenuItemCount, IN ULONG DefaultMenuItem, IN LONG MenuTimeOut, OUT PULONG SelectedMenuItem, IN BOOLEAN CanEscape, IN UiMenuKeyPressFilterCallback KeyPressFilter OPTIONAL, IN PVOID Context OPTIONAL)
Definition: ui.c:605
BOOLEAN UiInitialize(BOOLEAN ShowUi)
Definition: ui.c:92
static CCHAR DebugString[256]
Definition: settings.c:16
VOID LoadOperatingSystem(_In_ OperatingSystemItem *OperatingSystem)
Definition: bootmgr.c:287
BOOLEAN MainBootMenuKeyPressFilter(IN ULONG KeyPress, IN ULONG SelectedMenuItem, IN PVOID Context OPTIONAL)
Definition: bootmgr.c:335
#define IsListEmpty(ListHead)
Definition: env_spec_w32.h:954
BOOLEAN IniFileInitialize(VOID)
Definition: ini_init.c:25
PLIST_ENTRY IniGetFileSectionListHead(VOID)
Definition: inifile.c:25
VOID IniCleanup(VOID)
Definition: inifile.c:243
OperatingSystemItem * InitOperatingSystemList(_Out_ PULONG OperatingSystemCount, _Out_ PULONG DefaultOperatingSystem)
Definition: oslist.c:46
@ ESUCCESS
Definition: arc.h:32
const char * PCSTR
Definition: typedefs.h:52
DECLSPEC_NORETURN VOID __cdecl Reboot(VOID)
Definition: uefildr.c:99

Referenced by ExecuteLoaderCleanly().

Variable Documentation

◆ OSLoadingMethods

const OS_LOADING_METHOD OSLoadingMethods[]
static
Initial value:
=
{
}
static VOID EditCustomBootNTOS(_Inout_ OperatingSystemItem *OperatingSystem)
Definition: bootmgr.c:45
static VOID EditCustomBootReactOSSetup(_Inout_ OperatingSystemItem *OperatingSystem)
Definition: bootmgr.c:38
ARC_STATUS LoadReactOSSetup(IN ULONG Argc, IN PCHAR Argv[], IN PCHAR Envp[])
Definition: setupldr.c:492
ARC_STATUS LoadAndBootWindows(IN ULONG Argc, IN PCHAR Argv[], IN PCHAR Envp[])
Definition: winldr.c:1179
VOID MenuNTOptions(_Inout_ OperatingSystemItem *OperatingSystem)
Definition: advopts.c:106

Definition at line 60 of file bootmgr.c.

Referenced by GetOSLoadingMethod().