ScsiDebugPrint function (srb.h)

The ScsiDebugPrint routine prints debug information with a level of verbosity based on global values set in the kernel debugger or set in the registry and initialized when the system boots.

Note

The SCSI port driver and SCSI miniport driver models may be altered or unavailable in the future. Use the Storport driver and Storport miniport driver models instead.

Syntax

SCSIPORT_API VOID ScsiDebugPrint(
  ULONG  DebugPrintLevel,
  PCCHAR DebugMessage,
  ...    
);

Parameters

DebugPrintLevel

Contains a value between 0 and 3 that specifies the level of verbosity, where a value of 3 signifies the highest level of verbosity and a value of 0 signifies the lowest level. ScsiDebugPrint will print the message pointed to by DebugMessage, together with other debugging information. See Remarks.

DebugMessage

Pointer to the debug string to print.

...

Variadic arguments to be printed with the string that DebugMessage points to.

Return value

None

Remarks

ScsiDebugPrint calls DbgPrintEx, passing the DebugMessage pointer and a debug level value mapped from DebugPrintLevel as follows.

DebugPrintLevel value Value Passed to DbgPrintEx
0 DPFLTR_WARNING_LEVEL
1 DPFLTR_TRACE_LEVEL
2 DPFLTR_TRACE_LEVEL
3 DPFLTR_INFO_LEVEL

To view the message pointed to by DebugMessage from the kernel debugger, use the component filter mask Kd_ScsiMiniPort_Mask. For more information about debugging masks, see DbgPrintEx.

ScsiDebugPrint only functions in checked builds; it compiles to nothing in free builds.

Requirements

Requirement Value
Target Platform Desktop
Header srb.h (include Miniport.h, Scsi.h, Minitape.h)
Library Scsiport.lib

See also

DbgPrintEx