mirror of
https://github.com/reactos/reactos.git
synced 2025-04-29 18:48:53 +00:00
[HALX86][HALARM] Minor formatting to HalInitSystem
Add CODE_SEG("INIT"), SAL2 annotations, remove extra-parenthesis...
This commit is contained in:
parent
1890ad20f8
commit
b0dd4ba09c
2 changed files with 26 additions and 21 deletions
|
@ -16,20 +16,21 @@
|
||||||
|
|
||||||
/* PRIVATE FUNCTIONS **********************************************************/
|
/* PRIVATE FUNCTIONS **********************************************************/
|
||||||
|
|
||||||
|
static
|
||||||
|
CODE_SEG("INIT")
|
||||||
VOID
|
VOID
|
||||||
NTAPI
|
HalpGetParameters(
|
||||||
HalpGetParameters(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
_In_ PLOADER_PARAMETER_BLOCK LoaderBlock)
|
||||||
{
|
{
|
||||||
PCHAR CommandLine;
|
|
||||||
|
|
||||||
/* Make sure we have a loader block and command line */
|
/* Make sure we have a loader block and command line */
|
||||||
if ((LoaderBlock) && (LoaderBlock->LoadOptions))
|
if (LoaderBlock && LoaderBlock->LoadOptions)
|
||||||
{
|
{
|
||||||
/* Read the command line */
|
/* Read the command line */
|
||||||
CommandLine = LoaderBlock->LoadOptions;
|
PCSTR CommandLine = LoaderBlock->LoadOptions;
|
||||||
|
|
||||||
/* Check for initial breakpoint */
|
/* Check for initial breakpoint */
|
||||||
if (strstr(CommandLine, "BREAK")) DbgBreakPoint();
|
if (strstr(CommandLine, "BREAK"))
|
||||||
|
DbgBreakPoint();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -38,15 +39,17 @@ HalpGetParameters(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
||||||
/*
|
/*
|
||||||
* @implemented
|
* @implemented
|
||||||
*/
|
*/
|
||||||
|
CODE_SEG("INIT")
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
NTAPI
|
NTAPI
|
||||||
HalInitSystem(IN ULONG BootPhase,
|
HalInitSystem(
|
||||||
IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
_In_ ULONG BootPhase,
|
||||||
|
_In_ PLOADER_PARAMETER_BLOCK LoaderBlock)
|
||||||
{
|
{
|
||||||
PKPRCB Prcb = KeGetCurrentPrcb();
|
PKPRCB Prcb = KeGetCurrentPrcb();
|
||||||
|
|
||||||
/* Check the boot phase */
|
/* Check the boot phase */
|
||||||
if (!BootPhase)
|
if (BootPhase == 0)
|
||||||
{
|
{
|
||||||
/* Get command-line parameters */
|
/* Get command-line parameters */
|
||||||
HalpGetParameters(LoaderBlock);
|
HalpGetParameters(LoaderBlock);
|
||||||
|
|
|
@ -18,24 +18,25 @@ BOOLEAN HalpPciLockSettings;
|
||||||
|
|
||||||
/* PRIVATE FUNCTIONS *********************************************************/
|
/* PRIVATE FUNCTIONS *********************************************************/
|
||||||
|
|
||||||
|
static
|
||||||
CODE_SEG("INIT")
|
CODE_SEG("INIT")
|
||||||
VOID
|
VOID
|
||||||
NTAPI
|
HalpGetParameters(
|
||||||
HalpGetParameters(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
_In_ PLOADER_PARAMETER_BLOCK LoaderBlock)
|
||||||
{
|
{
|
||||||
PCHAR CommandLine;
|
|
||||||
|
|
||||||
/* Make sure we have a loader block and command line */
|
/* Make sure we have a loader block and command line */
|
||||||
if ((LoaderBlock) && (LoaderBlock->LoadOptions))
|
if (LoaderBlock && LoaderBlock->LoadOptions)
|
||||||
{
|
{
|
||||||
/* Read the command line */
|
/* Read the command line */
|
||||||
CommandLine = LoaderBlock->LoadOptions;
|
PCSTR CommandLine = LoaderBlock->LoadOptions;
|
||||||
|
|
||||||
/* Check if PCI is locked */
|
/* Check if PCI is locked */
|
||||||
if (strstr(CommandLine, "PCILOCK")) HalpPciLockSettings = TRUE;
|
if (strstr(CommandLine, "PCILOCK"))
|
||||||
|
HalpPciLockSettings = TRUE;
|
||||||
|
|
||||||
/* Check for initial breakpoint */
|
/* Check for initial breakpoint */
|
||||||
if (strstr(CommandLine, "BREAK")) DbgBreakPoint();
|
if (strstr(CommandLine, "BREAK"))
|
||||||
|
DbgBreakPoint();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -70,8 +71,9 @@ HalInitializeProcessor(
|
||||||
CODE_SEG("INIT")
|
CODE_SEG("INIT")
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
NTAPI
|
NTAPI
|
||||||
HalInitSystem(IN ULONG BootPhase,
|
HalInitSystem(
|
||||||
IN PLOADER_PARAMETER_BLOCK LoaderBlock)
|
_In_ ULONG BootPhase,
|
||||||
|
_In_ PLOADER_PARAMETER_BLOCK LoaderBlock)
|
||||||
{
|
{
|
||||||
PKPRCB Prcb = KeGetCurrentPrcb();
|
PKPRCB Prcb = KeGetCurrentPrcb();
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
@ -79,7 +81,7 @@ HalInitSystem(IN ULONG BootPhase,
|
||||||
/* Check the boot phase */
|
/* Check the boot phase */
|
||||||
if (BootPhase == 0)
|
if (BootPhase == 0)
|
||||||
{
|
{
|
||||||
/* Phase 0... save bus type */
|
/* Save bus type */
|
||||||
HalpBusType = LoaderBlock->u.I386.MachineType & 0xFF;
|
HalpBusType = LoaderBlock->u.I386.MachineType & 0xFF;
|
||||||
|
|
||||||
/* Get command-line parameters */
|
/* Get command-line parameters */
|
||||||
|
|
Loading…
Reference in a new issue