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

Go to the source code of this file.

Functions

 DBG_DEFAULT_CHANNEL (WARNING)
 
VOID __cdecl BootMain (IN PCCH CmdLine)
 
int __cdecl wctomb (char *mbchar, wchar_t wchar)
 
int __cdecl mbtowc (wchar_t *wchar, const char *mbchar, size_t count)
 
int __cdecl iswctype (wint_t wc, wctype_t wctypeFlags)
 
double pow (double x, double y)
 
double log (double x)
 
double log10 (double x)
 

Variables

CCHAR FrLdrBootPath [MAX_PATH] = ""
 

Function Documentation

◆ BootMain()

VOID __cdecl BootMain ( IN PCCH  CmdLine)

Definition at line 33 of file freeldr.c.

34{
35 /* Load the default settings from the command-line */
37
38 /* Debugger pre-initialization */
40
42
43 TRACE("BootMain() called.\n");
44
45#ifndef UEFIBOOT
46 /* Check if the CPU is new enough */
47 FrLdrCheckCpuCompatibility(); // FIXME: Should be done inside MachInit!
48#endif
49
50 /* UI pre-initialization */
51 if (!UiInitialize(FALSE))
52 {
53 UiMessageBoxCritical("Unable to initialize UI.");
54 goto Quit;
55 }
56
57 /* Initialize memory manager */
59 {
60 UiMessageBoxCritical("Unable to initialize memory manager.");
61 goto Quit;
62 }
63
64 /* Initialize I/O subsystem */
65 FsInit();
66
67 RunLoader();
68
69Quit:
70 /* If we reach this point, something went wrong before, therefore reboot */
71 Reboot();
72}
void LoadSettings(void)
Definition: settings.c:53
@ Reboot
Definition: bl.h:891
#define DebugInit(DebugString)
Definition: debug.h:120
VOID FsInit(VOID)
Definition: fs.c:646
BOOLEAN MmInitializeMemoryManager(VOID)
Definition: meminit.c:315
BOOTMGRINFO BootMgrInfo
Definition: settings.c:18
VOID UiMessageBoxCritical(_In_ PCSTR MessageText)
Definition: ui.c:372
BOOLEAN UiInitialize(BOOLEAN ShowUi)
Definition: ui.c:92
#define FALSE
Definition: types.h:117
static const WCHAR CmdLine[]
Definition: install.c:48
VOID RunLoader(VOID)
Definition: bootmgr.c:356
VOID FrLdrCheckCpuCompatibility(VOID)
Definition: macharm.c:65
VOID MachInit(IN PCCH CommandLine)
Definition: macharm.c:182
#define TRACE(s)
Definition: solgame.cpp:4
PCSTR DebugString
Definition: settings.h:12

Referenced by ArmInit(), and RealEntryPoint().

◆ DBG_DEFAULT_CHANNEL()

DBG_DEFAULT_CHANNEL ( WARNING  )

◆ iswctype()

int __cdecl iswctype ( wint_t  wc,
wctype_t  wctypeFlags 
)

Definition at line 90 of file freeldr.c.

91{
92 return _isctype((char)wc, wctypeFlags);
93}
_Check_return_ _CRTIMP int __cdecl _isctype(_In_ int _C, _In_ int _Type)

Referenced by _wcstoi64_l(), _wcstoui64_l(), _wtoi64_l(), _wtol(), iswalnum(), iswalpha(), iswblank(), iswcntrl(), iswdigit(), iswgraph(), iswlower(), iswprint(), iswpunct(), iswspace(), iswupper(), iswxdigit(), rangematch(), towlower(), towupper(), wcstol(), and wcstoul().

◆ log()

double log ( double  x)

Definition at line 109 of file freeldr.c.

110{
111 __debugbreak();
112 return 0.0;
113}
void __cdecl __debugbreak(void)
Definition: intrin_ppc.h:698

◆ log10()

◆ mbtowc()

int __cdecl mbtowc ( wchar_t wchar,
const char mbchar,
size_t  count 
)

Definition at line 83 of file freeldr.c.

84{
85 *wchar = (wchar_t)*mbchar;
86 return 1;
87}
#define wchar_t
Definition: wchar.h:102

◆ pow()

◆ wctomb()

int __cdecl wctomb ( char mbchar,
wchar_t  wchar 
)

Definition at line 77 of file freeldr.c.

78{
79 *mbchar = (char)wchar;
80 return 1;
81}
unsigned char
Definition: typeof.h:29

Variable Documentation

◆ FrLdrBootPath