mirror of
https://github.com/reactos/reactos.git
synced 2024-08-22 11:22:59 +00:00
[ROSLOAD]: Implement most of OslMain, which will try to initialize BootLib in Virtual Protected Mode (mostly unimplemented).
[BOOTLIB]: Fix GCC build. Bootmgr now correctly switches execution into rosload, which must now be implemented. svn path=/trunk/; revision=73693
This commit is contained in:
parent
7800da4db6
commit
d48996392c
|
@ -33,7 +33,22 @@ OslMain (
|
||||||
_In_ PBOOT_APPLICATION_PARAMETER_BLOCK BootParameters
|
_In_ PBOOT_APPLICATION_PARAMETER_BLOCK BootParameters
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
EfiPrintf(L"ReactOS UEFI OS Loader Initializing...\r\n");
|
BL_LIBRARY_PARAMETERS LibraryParameters;
|
||||||
return STATUS_NOT_IMPLEMENTED;
|
NTSTATUS Status;
|
||||||
|
|
||||||
|
/* Setup the boot library parameters for this application */
|
||||||
|
BlSetupDefaultParameters(&LibraryParameters);
|
||||||
|
LibraryParameters.TranslationType = BlVirtual;
|
||||||
|
LibraryParameters.LibraryFlags = BL_LIBRARY_FLAG_INITIALIZATION_COMPLETED;
|
||||||
|
LibraryParameters.MinimumAllocationCount = 1024;
|
||||||
|
LibraryParameters.MinimumHeapSize = 2 * 1024 * 1024;
|
||||||
|
LibraryParameters.HeapAllocationAttributes = 0x20000;
|
||||||
|
LibraryParameters.FontBaseDirectory = L"\\Reactos\\Boot\\Fonts";
|
||||||
|
LibraryParameters.DescriptorCount = 512;
|
||||||
|
Status = BlInitializeLibrary(BootParameters, &LibraryParameters);
|
||||||
|
|
||||||
|
//EfiPrintf(L"ReactOS UEFI OS Loader Initializing...\r\n");
|
||||||
|
EfiConOut->OutputString(EfiConOut, L"ReactOS UEFI OS Loader Initializing...\r\n");
|
||||||
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1758,7 +1758,7 @@ BlpFwInitialize (
|
||||||
/* FIXME: Not supported */
|
/* FIXME: Not supported */
|
||||||
Status = STATUS_NOT_SUPPORTED;
|
Status = STATUS_NOT_SUPPORTED;
|
||||||
}
|
}
|
||||||
else if (FirmwareData->Version >= 2)
|
else if (FirmwareData->Version >= BL_FIRMWARE_DESCRIPTOR_VERSION)
|
||||||
{
|
{
|
||||||
/* Version 2 -- save the data */
|
/* Version 2 -- save the data */
|
||||||
EfiFirmwareData = *FirmwareData;
|
EfiFirmwareData = *FirmwareData;
|
||||||
|
|
|
@ -22,7 +22,7 @@ KDESCRIPTOR IdtRegister;
|
||||||
KDESCRIPTOR BootAppGdtRegister;
|
KDESCRIPTOR BootAppGdtRegister;
|
||||||
KDESCRIPTOR BootAppIdtRegister;
|
KDESCRIPTOR BootAppIdtRegister;
|
||||||
PVOID BootApp32EntryRoutine;
|
PVOID BootApp32EntryRoutine;
|
||||||
PVOID BootApp32Parameters;
|
PBOOT_APPLICATION_PARAMETER_BLOCK BootApp32Parameters;
|
||||||
PVOID BootApp32Stack;
|
PVOID BootApp32Stack;
|
||||||
|
|
||||||
/* FUNCTIONS *****************************************************************/
|
/* FUNCTIONS *****************************************************************/
|
||||||
|
@ -1710,7 +1710,7 @@ ImgpInitializeBootApplicationParameters (
|
||||||
ParameterBlock->Signature[1] = BOOT_APPLICATION_SIGNATURE_2;
|
ParameterBlock->Signature[1] = BOOT_APPLICATION_SIGNATURE_2;
|
||||||
ParameterBlock->MemoryTranslationType = MmTranslationType;
|
ParameterBlock->MemoryTranslationType = MmTranslationType;
|
||||||
ParameterBlock->ImageType = IMAGE_FILE_MACHINE_I386;
|
ParameterBlock->ImageType = IMAGE_FILE_MACHINE_I386;
|
||||||
ParameterBlock->ImageBase = (ULONGLONG)ImageBase;
|
ParameterBlock->ImageBase = (ULONG_PTR)ImageBase;
|
||||||
ParameterBlock->ImageSize = NtHeaders->OptionalHeader.SizeOfImage;
|
ParameterBlock->ImageSize = NtHeaders->OptionalHeader.SizeOfImage;
|
||||||
|
|
||||||
/* Get the offset to the memory data */
|
/* Get the offset to the memory data */
|
||||||
|
@ -1870,9 +1870,6 @@ ImgArchEfiStartBootApplication (
|
||||||
/* Disable the kernel debugger */
|
/* Disable the kernel debugger */
|
||||||
BlBdStop();
|
BlBdStop();
|
||||||
#endif
|
#endif
|
||||||
/* Not yet implemented. This is the last step! */
|
|
||||||
EfiPrintf(L"EFI APPLICATION START!!!\r\n");
|
|
||||||
|
|
||||||
/* Make it so */
|
/* Make it so */
|
||||||
Archx86TransferTo32BitApplicationAsm();
|
Archx86TransferTo32BitApplicationAsm();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue