mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 19:37:10 +00:00
[NTOSKRNL]
- Disable displaying string by bootvid after successful kernel phase 1 initialization, so there won't be graphical glitches at the top of screen if system has screen debugging enabled - Make screen black right after phase 1 initialization finish instead of waiting 5 seconds. It removes black rectangle which appeared for me in explorer. - Initialize some global variables in inbv.c (it was done by compiler before) svn path=/trunk/; revision=52244
This commit is contained in:
parent
6fc52906e5
commit
b0571d1c2e
3 changed files with 54 additions and 19 deletions
|
@ -1313,7 +1313,7 @@ Phase1InitializationDiscard(IN PVOID Context)
|
|||
size_t Remaining;
|
||||
PRTL_USER_PROCESS_INFORMATION ProcessInfo;
|
||||
KEY_VALUE_PARTIAL_INFORMATION KeyPartialInfo;
|
||||
UNICODE_STRING KeyName, DebugString;
|
||||
UNICODE_STRING KeyName;
|
||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||
HANDLE KeyHandle, OptionHandle;
|
||||
PRTL_USER_PROCESS_PARAMETERS ProcessParameters = NULL;
|
||||
|
@ -1925,18 +1925,19 @@ Phase1InitializationDiscard(IN PVOID Context)
|
|||
/* Update progress bar */
|
||||
InbvUpdateProgressBar(100);
|
||||
|
||||
/* Allow strings to be displayed */
|
||||
InbvEnableDisplayString(TRUE);
|
||||
/* Disallow strings to be displayed */
|
||||
InbvEnableDisplayString(FALSE);
|
||||
|
||||
/* Wait 5 seconds for it to initialize */
|
||||
/* Clean the screen */
|
||||
if (InbvBootDriverInstalled) FinalizeBootLogo();
|
||||
|
||||
/* Wait 5 seconds for initial process to initialize */
|
||||
Timeout.QuadPart = Int32x32To64(5, -10000000);
|
||||
Status = ZwWaitForSingleObject(ProcessInfo->ProcessHandle, FALSE, &Timeout);
|
||||
if (InbvBootDriverInstalled) FinalizeBootLogo();
|
||||
if (Status == STATUS_SUCCESS)
|
||||
{
|
||||
/* Failed, display error */
|
||||
RtlInitUnicodeString(&DebugString, L"INIT: Session Manager terminated.");
|
||||
ZwDisplayString(&DebugString);
|
||||
DPRINT1("INIT: Session Manager terminated.\n");
|
||||
|
||||
/* Bugcheck the system if SMSS couldn't initialize */
|
||||
KeBugCheck(SESSION5_INITIALIZATION_FAILED);
|
||||
|
|
|
@ -10,16 +10,16 @@
|
|||
KSPIN_LOCK BootDriverLock;
|
||||
KIRQL InbvOldIrql;
|
||||
INBV_DISPLAY_STATE InbvDisplayState;
|
||||
BOOLEAN InbvBootDriverInstalled;
|
||||
BOOLEAN InbvDisplayDebugStrings;
|
||||
BOOLEAN InbvBootDriverInstalled = FALSE;
|
||||
BOOLEAN InbvDisplayDebugStrings = FALSE;
|
||||
INBV_DISPLAY_STRING_FILTER InbvDisplayFilter;
|
||||
ULONG ProgressBarLeft, ProgressBarTop;
|
||||
BOOLEAN ShowProgressBar;
|
||||
BOOLEAN ShowProgressBar = FALSE;
|
||||
INBV_PROGRESS_STATE InbvProgressState;
|
||||
INBV_RESET_DISPLAY_PARAMETERS InbvResetDisplayParameters;
|
||||
ULONG ResourceCount;
|
||||
PUCHAR ResourceList[64];
|
||||
BOOLEAN SysThreadCreated;
|
||||
BOOLEAN SysThreadCreated = FALSE;
|
||||
ROT_BAR_TYPE RotBarSelection;
|
||||
ULONG PltRotBarStatus;
|
||||
BT_PROGRESS_INDICATOR InbvProgressIndicator = {0, 25, 0};
|
||||
|
|
|
@ -480,10 +480,18 @@ IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
KeSetTimerEx(&IopTimer, ExpireTime, 1000, &IopTimerDpc);
|
||||
|
||||
/* Create Object Types */
|
||||
if (!IopCreateObjectTypes()) return FALSE;
|
||||
if (!IopCreateObjectTypes())
|
||||
{
|
||||
DPRINT1("IopCreateObjectTypes failed!\n");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Create Object Directories */
|
||||
if (!IopCreateRootDirectories()) return FALSE;
|
||||
if (!IopCreateRootDirectories())
|
||||
{
|
||||
DPRINT1("IopCreateRootDirectories failed!\n");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Initialize PnP manager */
|
||||
IopInitializePlugPlayServices();
|
||||
|
@ -511,10 +519,19 @@ IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
IopLoaderBlock = NULL;
|
||||
|
||||
/* Create ARC names for boot devices */
|
||||
if (!NT_SUCCESS(IopCreateArcNames(LoaderBlock))) return FALSE;
|
||||
Status = IopCreateArcNames(LoaderBlock);
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("IopCreateArcNames failed: %lx\n", Status);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Mark the system boot partition */
|
||||
if (!IopMarkBootPartition(LoaderBlock)) return FALSE;
|
||||
if (!IopMarkBootPartition(LoaderBlock))
|
||||
{
|
||||
DPRINT1("IopMarkBootPartition failed!\n");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Initialize PnP root relations */
|
||||
IopEnumerateDevice(IopRootDeviceNode->PhysicalDeviceObject);
|
||||
|
@ -539,7 +556,11 @@ IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
|
||||
/* Convert SystemRoot from ARC to NT path */
|
||||
Status = IopReassignSystemRoot(LoaderBlock, &NtBootPath);
|
||||
if (!NT_SUCCESS(Status)) return FALSE;
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("IopReassignSystemRoot failed: %lx\n", Status);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Set the ANSI_STRING for the root path */
|
||||
RootString.MaximumLength = NtSystemRoot.MaximumLength / sizeof(WCHAR);
|
||||
|
@ -550,7 +571,11 @@ IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
|
||||
/* Convert the path into the ANSI_STRING */
|
||||
Status = RtlUnicodeStringToAnsiString(&RootString, &NtSystemRoot, FALSE);
|
||||
if (!NT_SUCCESS(Status)) return FALSE;
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("RtlUnicodeStringToAnsiString failed: %lx\n", Status);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Assign drive letters */
|
||||
IoAssignDriveLetters(LoaderBlock,
|
||||
|
@ -560,10 +585,19 @@ IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
|||
|
||||
/* Update system root */
|
||||
Status = RtlAnsiStringToUnicodeString(&NtSystemRoot, &RootString, FALSE);
|
||||
if (!NT_SUCCESS(Status)) return FALSE;
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("RtlAnsiStringToUnicodeString failed: %lx\n", Status);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Load the System DLL and its Entrypoints */
|
||||
if (!NT_SUCCESS(PsLocateSystemDll())) return FALSE;
|
||||
Status = PsLocateSystemDll();
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("PsLocateSystemDll failed: %lx\n", Status);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Return success */
|
||||
return TRUE;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue