alcyone/BOOT/ENVIRON/INC/bootlib.h
Kaimakan71 76b01cfb00 [BOOT:LIB] Add conditional debug printing
Added DebugPrint() and DebugPrintf() macros, which are aliases of
ConsolePrint() and ConsolePrintf() if _DEBUG is defined. Otherwise, they
do not generate any code.
2024-08-26 10:44:31 -04:00

76 lines
1.1 KiB
C

/*++
Copyright (c) 2024, Quinn Stephens.
Provided under the BSD 3-Clause license.
Module Name:
bootlib.h
Abstract:
Boot library definitions.
--*/
#ifndef _BOOTLIB_H
#define _BOOTLIB_H
#include <nt.h>
#include "bootmgr.h"
typedef struct {
ULONG Flags;
} BOOT_LIBRARY_PARAMETERS, *PBOOT_LIBRARY_PARAMETERS;
VOID
ConsolePrint (
IN PWSTR String
);
VOID
ConsolePrintf (
IN PWSTR Format,
...
);
//
// Enable/disable debug printing.
//
#ifdef _DEBUG
#define DebugPrint(String) ConsolePrint(String)
#define DebugPrintf(Format, ...) ConsolePrintf(Format, __VA_ARGS__)
#else
#define DebugPrint(String)
#define DebugPrintf(Format, ...)
#endif
ULONG
BlGetBootOptionSize (
IN PBOOT_APPLICATION_OPTION Option
);
ULONG
BlGetBootOptionListSize (
IN PBOOT_APPLICATION_OPTION Options
);
NTSTATUS
BlpFwInitialize (
IN ULONG Stage,
IN PBOOT_FIRMWARE_DATA FirmwareData
);
NTSTATUS
BlInitializeLibrary (
IN PBOOT_INPUT_PARAMETERS InputParameters,
IN PBOOT_LIBRARY_PARAMETERS LibraryParameters
);
NTSTATUS
BlDestroyLibrary (
VOID
);
#endif