[NTOS:KD] Add some annotations.

This commit is contained in:
Hermès Bélusca-Maïto 2023-01-09 12:31:03 +01:00
parent cee893be99
commit a8b09eddc4
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0
5 changed files with 30 additions and 30 deletions

View file

@ -40,10 +40,9 @@ typedef enum _KD_CONTINUE_TYPE
typedef
VOID
(NTAPI*PKDP_INIT_ROUTINE)(
struct _KD_DISPATCH_TABLE *DispatchTable,
ULONG BootPhase
);
(NTAPI *PKDP_INIT_ROUTINE)(
_In_ struct _KD_DISPATCH_TABLE *DispatchTable,
_In_ ULONG BootPhase);
typedef
VOID
@ -63,30 +62,27 @@ KdpScreenRelease(VOID);
VOID
NTAPI
KdpScreenInit(
struct _KD_DISPATCH_TABLE *DispatchTable,
ULONG BootPhase
);
_In_ struct _KD_DISPATCH_TABLE *DispatchTable,
_In_ ULONG BootPhase);
VOID
NTAPI
KdpSerialInit(
struct _KD_DISPATCH_TABLE *DispatchTable,
ULONG BootPhase
);
_In_ struct _KD_DISPATCH_TABLE *DispatchTable,
_In_ ULONG BootPhase);
VOID
NTAPI
KdpDebugLogInit(
struct _KD_DISPATCH_TABLE *DispatchTable,
ULONG BootPhase
);
_In_ struct _KD_DISPATCH_TABLE *DispatchTable,
_In_ ULONG BootPhase);
#ifdef KDBG
VOID
NTAPI
KdpKdbgInit(
struct _KD_DISPATCH_TABLE *DispatchTable,
ULONG BootPhase);
_In_ struct _KD_DISPATCH_TABLE *DispatchTable,
_In_ ULONG BootPhase);
#endif

View file

@ -212,8 +212,9 @@ KdpPrintToLogFile(PCHAR String,
VOID
NTAPI
KdpDebugLogInit(PKD_DISPATCH_TABLE DispatchTable,
ULONG BootPhase)
KdpDebugLogInit(
_In_ PKD_DISPATCH_TABLE DispatchTable,
_In_ ULONG BootPhase)
{
NTSTATUS Status;
UNICODE_STRING FileName;
@ -340,8 +341,9 @@ KdpSerialPrint(PCHAR String,
VOID
NTAPI
KdpSerialInit(PKD_DISPATCH_TABLE DispatchTable,
ULONG BootPhase)
KdpSerialInit(
_In_ PKD_DISPATCH_TABLE DispatchTable,
_In_ ULONG BootPhase)
{
if (!KdpDebugMode.Serial) return;
@ -504,8 +506,9 @@ KdpScreenPrint(PCHAR String,
VOID
NTAPI
KdpScreenInit(PKD_DISPATCH_TABLE DispatchTable,
ULONG BootPhase)
KdpScreenInit(
_In_ PKD_DISPATCH_TABLE DispatchTable,
_In_ ULONG BootPhase)
{
if (!KdpDebugMode.Screen) return;
@ -550,8 +553,8 @@ KdbInitialize(PKD_DISPATCH_TABLE DispatchTable, ULONG BootPhase);
VOID
NTAPI
KdpKdbgInit(
PKD_DISPATCH_TABLE DispatchTable,
ULONG BootPhase)
_In_ PKD_DISPATCH_TABLE DispatchTable,
_In_ ULONG BootPhase)
{
/* Forward the call */
KdbInitialize(DispatchTable, BootPhase);

View file

@ -21,7 +21,8 @@ extern ANSI_STRING KdpLogFileName;
static PCHAR
NTAPI
KdpGetDebugMode(PCHAR Currentp2)
KdpGetDebugMode(
_In_ PCHAR Currentp2)
{
PCHAR p1, p2 = Currentp2;
ULONG Value;
@ -83,7 +84,7 @@ KdpGetDebugMode(PCHAR Currentp2)
NTSTATUS
NTAPI
KdDebuggerInitialize0(
IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
_In_opt_ PLOADER_PARAMETER_BLOCK LoaderBlock)
{
ULONG i;
PCHAR CommandLine, Port = NULL;
@ -138,7 +139,7 @@ KdDebuggerInitialize0(
NTSTATUS
NTAPI
KdDebuggerInitialize1(
IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
_In_opt_ PLOADER_PARAMETER_BLOCK LoaderBlock)
{
PLIST_ENTRY CurrentEntry;
PKD_DISPATCH_TABLE CurrentTable;

View file

@ -348,8 +348,8 @@ KdbDebugPrint(
VOID
NTAPI
KdbInitialize(
PKD_DISPATCH_TABLE DispatchTable,
ULONG BootPhase)
_In_ PKD_DISPATCH_TABLE DispatchTable,
_In_ ULONG BootPhase)
{
PCHAR p1, p2;
SHORT Found = FALSE;

View file

@ -9,13 +9,13 @@ typedef ULONG KDSTATUS;
NTSTATUS
NTAPI
KdDebuggerInitialize0(
IN PLOADER_PARAMETER_BLOCK LoaderBlock
_In_opt_ PLOADER_PARAMETER_BLOCK LoaderBlock
);
NTSTATUS
NTAPI
KdDebuggerInitialize1(
IN PLOADER_PARAMETER_BLOCK LoaderBlock
_In_opt_ PLOADER_PARAMETER_BLOCK LoaderBlock
);
KDSTATUS