KeBugCheck

VOID
KeBugCheck(

IN ULONG BugCheckCode
);

KeBugCheck brings down the system in a controlled manner when the caller discovers an unrecoverable inconsistency that would corrupt the system if the caller continued to run.

Parameters

BugCheckCode

Specifies a value that indicates the reason for the bug check.

Comments

A bug check is a system-detected error that causes an immediate, controlled shutdown of the system. Various kernel-mode components perform runtime consistency checking. When such a component discovers an unrecoverable inconsistency, it causes a bug check to be generated.

If possible, all kernel-mode components log an error and continue to run, rather than calling KeBugCheck, unless the system itself could become corrupted by the inconsistency discovered. Most system components call KeBugCheckEx, which provides more information about the cause of such an inconsistency than KeBugCheck.

Callers of KeBugCheck can be running at any IRQL.

See Also

IoAllocateErrorLogEntry, IoWriteErrorLogEntry, KeBugCheckEx, KeRegisterBugCheckCallback